write test cases forthe function f=a+b ?

Answer Posted / shailaja

For the addition of two numbers we have to test the
following things...
1)Valid criteria
2)Invalid Criteria
3)Blank
Tc1:Valid data
1)Enter valid data for a &b check f value
Tc2:Blank
1)Enter value for a and keep b as blank and test the
functionality
2)Enter value for b and check the functionality
3)Both are blanks check the functionality


1)a+ve value,B negative value(Vice versa)
2)A some value b is 0(vice versa)
3)Decimal values for both the fields
4)one decimal and one normal digit
5)Check for alphanumeric values
6)Enter space before,middle,end entering the value
andcheck the additon
7)special characters
.so many things are ther to consider the things ...

If anybody asks u to write testcases first ask them to give
clear requirements so that depends upon that we can write
the test cases..
here in this case we dont know the type of variables a&b
if we know the type of variables we can write as per that ..

please let me know that if write anything wrong....

Is This Answer Correct ?    17 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write down ten test cases for below scenario: Increase the day by 1 and date format should be mm/dd/yyyy Conditions are : date should not be greater then 31 and date<1 month should not be greater then 12 and month<1 year should not be greater then 10000 and year<1 Thanks in advance

1871


Can anyone list out major scenarios for an application managing drug composition?

1613


Test cases on send/ receive button of Microsoft outlook.

4221


What is internationalization testing (i18n testing)?

816


i have source and target having same data structure 500 fields and one lacks records. how to validate data. write 5 scenarios.

4976






Being an Manual tester, what will be the role or activity in test plan ?

1710


how mapp the defect id in quality center?

1777


what is Test management fundamental?

1875


Which is the best book to ref. for design the test cases/scenario in manual testing,which gives detailed idea with all the strategies ?

6154


i heard that mainframe testing is diff from other environments & has lot of keyboard input????pl clarify my doubt & let me know in what way its diff??

1711


whats the reason to display the password(not in encrypted form) in the script in load runner but not in QTP?

1544


Describe Testing Decomposition?

798


can anyone tell me the scenarios for online banking transaction ?

1752


What is the difference between IE, Opera & Mozilla Firefox in web Testing and which brower will think that is much better?

1665


What r all the security problems u r facing & the measures taken to solve.

1923