How many testcases can be written for the calculator

How many testcases can be written for the calculator having 0-9 buttons,the options are add,multiplication.the question is suppose in add 22+22=44 this is we knew but how the application knows its 44,how can we check the functionality???

Showing Answers 1 - 6 of 6 Answers

Sam

  • Feb 15th, 2015
 

before you go to functionality tests, you should do weather all "0-9" button are working or not? Total 10 test cases. Then to test buttons "+" "-", "/" "*" "=" "%" etc.......
Use of Calculator: Add, Sub, Multiply, Division (just take these main functionalities)
Test Case for Add: enter "2" then press + button then enter "12". Expected result 14. check it and compare it.
Test case for Sub: enter "12" then press - button then enter "2". Expected result 10. check it and compare it.

  Was this answer useful?  Yes

dolly

  • Feb 16th, 2015
 

You can also check for max decimal values accepted for any of the operations and most importantly whether 1/0 throws an error. Also max no once multiplied (does it gives exponential or not). And many more negative scenarios too can be tested. Multiple Calcs can open & close without affecting others..

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions