Friday, 7 December 2012

Software Quality Assurance

Black Box Testing

Black Box Testing
Testing software against a specification of its external behavior without knowledge of internal implementation details
•Types of Black Box Testing
Equivalence class partitioning
Boundary value analysis
Cause-effect graphing
Error guessing


Equivalence Partitioning
•Domain is so large that you can't test all possible values
•Equivalence partitioning is a black box testing method
•It divides the input domain of a program into classes of data from which test cases can be derived.
•Partition the input's domain into "equivalence classes“
•This method is typically used to reduce the total number of test cases to a finite set of testable test cases


Equivalence Partitioning
•First-level partitioning: Valid vs. Invalid values


Equivalence Partitioning

•Partition valid and invalid values into equivalence classes


Equivalence Partitioning

•Create a test case for at least one value from each equivalence class


Boundary Value Analysis

•Many systems have tendency to fail on boundary. So testing boundry values of application is important.
•Extends equivalence partitioning Test both sides of each boundary Test min, min-1, max, max+1


Boundaries of the inputs

The “basic” boundary value testing would include 5 situations:
1. - at minimum boundary
2. - immediately below minimum
3. - between minimum and maximum (nominal)
4. - immediately above maximum
5. - at maximum boundary
1 <= age <= 150
Min
Max


Boundary shift:

–This happens when the constant term of the inequality defining the boundary takes up a value different from the intended value
–In concrete terms, a shifted-boundary error occurs due to a change in the magnitude or the sign of the constant term of the inequality
–e.g. consider the boundary defined by p: x + 5y> 5
–If the programmer’s intention was to define a boundary represented by the p: x + 5y> 4
–Other boundary changes are possible too; e.g boundary tilt where some parameters in equation are changed slightly x + 55y>4


•When the input consists of a single variable, we can directly use the four values, “under”, “min”, “max”, and “over”, and an interior point for testing.
•For example, for an input sub-domain,
0 ≤x <21, define the boundary values?
-1, 0, 10,21, and 22 (if we are testing integers)
The interior point is arbitrarily selected at x=10,
and the “under” and “over” points are at the distance Є from the boundary,
in this case 1 under or 1 over.




1 comment:

  1. This is for students, who do not find such lecture notes on internet

    ReplyDelete