Homework 2 Test Case Creation.docx

# When entering testcase 3 i decided to make the price

• Test Prep
• 10

This preview shows pages 6–10. Sign up to view the full content.

When entering Testcase #3, I decided to make the price a negative and then keep the sales tax in the positive. My thoughts were comparing this to a return in the store. So the expected output would also be negative. As it turns out, I was correct. Entering a negative price (-\$23.49) and a positive sales tax (10.88%) would still give a negative output by adding the two prices together.

This preview has intentionally blurred sections. Sign up to view the full version.

Homework 2 Test Case Creation Testcase #4
Homework 2 Test Case Creation For testcase #4 I wanted to see what would happen if I entered a large number with commas and just a percent sign. My thoughts for the expected output was that I would get an error because no numerical value was entered into the sales tax, just a % sign. I was very very wrong. I was not expecting for the commas to turn the large value into a small value and for the % sign to equal 0. Lesson learned….on to Testcase #5, large numerical input without commas.

This preview has intentionally blurred sections. Sign up to view the full version.

Homework 2 Test Case Creation Testcase #5
Homework 2 Test Case Creation For testcase #5, I left the commas out, entered a large numerical value for the price and then entered the word “undefined” for the sales tax. What I expected on the outcome was an Error: Undefined. However, what I got in the output for the sales tax was just the word undefined. I did get the large price (due to leaving the commas out) but am not sure where the “36” came from in the end of the price when I entered it as “21”. Still a bit confused on this one.
This is the end of the preview. Sign up to access the rest of the document.
• Fall '09
• \$50, \$52.50, \$23.49, \$65.80

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern