Boundary Value Analysis (BVA) is a type of functional (black box) testing which is used to catch the errors around the boundary and test cases are designed to check the range values.
It is based on testing boundaries between partitions and range checking.
It is an input value or out put value which is on the edge of equivalence partitioning or smallest increment or decrements on either side of lower and upper limit (range value) to identify errors (error my arise due to logic or comparison).
It is complements an equivalence class partitioning.
To cover boundary test cases, boundary value analysis combine all valid boundaries (Minimum and Maximum boundary values) and invalid boundaries(Less than and Greater than boundary values) for validation.
It is used to test numeric (integer, floating) as well as string value
It is used to find out the errors around the boundaries rather than center of input system
Formula to find valid and invalid partition values in boundary values analysis is n, n+1 and n-1, where n is boundary or limit (upper and lower)
Consider, to set strong password for a system string length should be in between 6 to 12 characters. Valid and invalid boundaries for boundary value analysis are
Range or limit is 6-12
Lower boundary is 6
Upper boundary is 12
n = 6-12
n+1= 7 and 13 (lower and upper)
n-1 = 5 and 11 (lower and upper)
|Valid Boundary||Invalid Boundary|
|6-12, 7,11||5, 13|
In boundary values analysis will have five test of values out of five, three from valid (Within boundary, less than and grater than boundary ) and two from invalid boundaries ( less than and grater than boundary)