Question: A program reads an integer number within the range [0, 200] and determines whether it is an even number or not. Design test cases for this program using BVC, robust and worst case testing methods.
0
ADD COMMENTlink
modified 7 weeks ago  • written 6 months ago by gravatar for Ankit Pandey Ankit Pandey70
0

Test cases using BVC

Since there is only one variable for finding number is even or not, the total test cases will be 4n + 1 = 5

$\therefore$ min value = 0

maximum value = 200

minimum + value = 1

maximum - value = 199

nominal value = 100

Using this test cases designs are as follows.

Test case id Integer value Expected o/p
1 0 even no.
2 200 even no.
3 1 odd no.
4 199 odd no.
5 100 even no.

* Test cases using robust testing :*

$\therefore$ there is only one variable, total no. of test cases will be

6n + 1 = 7

min value = 0

max value = 100

min - value = -1

min + value = 1

max + value = 201

max - value = 199

nominal value = 100

Using these values, test cases can be designed as follows:

Test case ID Integer value Expected o/p
1 0 even no.
2 200 even no.
3 -1 odd no.
4 1 odd no.
5 201 odd no.
6 199 odd no.
7 100 even no.

Test cases using worst case testing : Since there is only one variable, the total number of test cases will be $5^n = 5$ Therefore the number of test cases will be same as BVC.

ADD COMMENTlink
modified 7 weeks ago by gravatar for Ankit Pandey Ankit Pandey70 written 6 months ago by gravatar for RB RB ♦♦ 110
Please log in to add an answer.