This method leads to a selection of test cases that exercise boundary values. It complements equivalence partitioning since it selects test cases at the edges of a class. Rather than focusing on input conditions solely, BVA derives test cases from the output domain also. BVA guidelines include:
1. For input ranges bounded by a and b, test cases should include
values a and b and just above and just below a and b respectively.
2. If an input condition specifies a number of values, test cases
should be developed to exercise the minimum and maximum numbers and
values just above and below these limits.
3. Apply guidelines 1 and 2 to the output.
4. If internal data structures have prescribed boundaries, a test
case should be designed to exercise the data structure at its boundary.
Defining the Tests
To determine the tests for this method, first identify valid and invalid
input and output conditions for a given function.
Then, identify the tests for situations at each boundary. For example, one test each for >, =, <, using the first value in the > range, the value that is equal to the boundary, and the first value in the < range.
Boundary conditions do not need to focus only on values or ranges, but can be identified for many other boundary situations as well, such as end of page, (i.e., identify tests for production of output that is one line less than the end of page, exactly to the end of page, and one line over the end of page). The tester needs to identify as many situations as possible, the list of Common Extreme Test Conditions may help with this process:
Common Extreme Test Conditions
zero or negative values,
zero or one transaction,
empty files,
missing files (file name not resolved or access denied),
multiple updates of one file,
full, empty, or missing tables,
widow headings (i.e., headings printed on pages with no details or
totals),
table entries missing,
subscripts out of bounds,
sequencing errors,
missing or incorrect parameters or message formats,
concurrent access of a file,
file space overflow.
For example, if you were to write code to simulate following condition
-
" Input should be greater than equal to 10 and less than 50"
Probably you will write something like
if (input >=10 AND input <50) then
do some
else
do some thing else.
So, according to this input values from 10 to 49 are valid, but if
you make mistake in specifying the conditions, following things can
happen
input >10 AND input <50 -------> Input value 10 in invalid
now.
input <=10 AND input <50 -------> Input value 9 is valid
now.
input >=10 AND input <=50 -----> Input value 50 is valid
now
input >=10 AND input >50 -----> Input value 49 is invalid
now