written 5.8 years ago by |
Equivalence partitioning is a software technique that involves identifying a small set of representative input values that produce as much different output condition as possible. It is use to reduce test cases. This reduces the number of permutation & combination of input, output values used for testing, thereby increasing the coverage and reducing the effort involved in testing.
The set of input values that generate one single expected output is called a partition. When the behavior of the software is the same for a set of values, then the set is termed as equivalence class or partition.
Example:
1.An insurance company that has the following premium rates based on the age group. A life insurance company has base premium of \$ 0.50 for all ages. Based on the age group, an additional monthly premium has to pay that is as listed in the table below. For example , a person aged 34 has to pay a premium=\$0.50 +\$ 1.65=$2.15
2.Based on the equivalence portioning technique, the equivalence partitions that are based on marks are given below:
Marks | result |
---|---|
Under 40 | fail |
40-100 | pass |
Equivalence partitioning:
Above | 40 marks in subject | (valid input) |
---|---|---|
Between | 40 and 100 marks | (valid input) |
Below | 40 marks | (invalid input) |
Below | Negative marks | (invalid input) |