How many Test-Cases can be written for the calculator having 0-9 buttons, Add, Equalto buttons? The test cases should be focused only on add-functionality but mot GUI.What is those test-cases?
Test-Cases for the calculator
so here we have 12 buttons totalize 0,1,2,3,4,5,6,7,8,9,ADD,Equalto -12 buttons
here u can press at least 4 buttons at a time minimum for example 0+1= for zero u should press ‘zero’ labeled button for plus u should press ‘+’ labeled button for one u should press ‘one’ labeled button for equal to u should press ‘equal to’ labeled button 0+1=here + and = positions will not vary so first number position can be varied from 0 to 9 i.e. from permutation and combinations u can fill that space in 10 ways in the same way second number position can be varied from 0 to 9 i.e. from permutation and combinations u can fill that space in 10 ways
Total number of possibilities are =10×10=100
This is exhaustive testing methodology and this is not possible in all cases.
In mathematics we have one policy that the function satisfies the starting and ending values of a range then it can satisfy for entire range of values from starting to ending.
then we check the starting conditions i.e. one test case for ‘0+0=’ (expected values you know that’s ‘0′) then another test case for ‘9+9=’(expected values you know that’s ‘18′) only two test cases are enough to test the calculator functionality.