Equivalence partitioning
An online shop prices orders by quantity: 1 to 9 gets a 5% discount. Orders of fewer than 1 or more than 9 items are rejected.
Practice · Test design
Exam-style equivalence partitioning questions, generated fresh each time, with answers computed to the ISTQB Foundation Level v4.0 definitions (section 4.2.1). Every wrong answer tells you which mistake leads to it.
No answers yet
Equivalence partitioning
An online shop prices orders by quantity: 1 to 9 gets a 5% discount. Orders of fewer than 1 or more than 9 items are rejected.
Equivalence partitioning splits the possible values of an input into partitions the system is expected to treat the same way. Values it accepts form valid partitions; values it rejects form invalid ones, and they count as partitions too.
The coverage items are the partitions. 100% equivalence partitioning coverage means every partition, valid and invalid, has been exercised by at least one test, and coverage is the number of partitions exercised divided by the number identified.
Example 1
A car insurer quotes by the driver's age in whole years: 20 to 38 gets the standard premium. Drivers younger than 20 or older than 38 can't get a quote online.
Answer: 3. The accepted values form 1 valid partition. Values below 20 and values above 38 form two invalid partitions. That makes 3, and 100% EP coverage needs one test from each.
Try this one in the quiz: open example 1.
Example 2
An online shop prices orders by quantity: 5 to 10 gets full price and 11 to 12 gets a 5% discount. Orders of fewer than 5 or more than 12 items are rejected.
Answer: 4. The accepted values form 2 valid partitions, one per outcome. Values below 5 and values above 12 form two invalid partitions. That makes 4, and 100% EP coverage needs one test from each.
Try this one in the quiz: open example 2.
Example 3
A grading system takes a whole-number score, where 0 to 16 gets a pass. Scores below 0 or above 16 are rejected as invalid.
Answer: 3. The accepted values form 1 valid partition. Values below 0 and values above 16 form two invalid partitions. That makes 3, and 100% EP coverage needs one test from each.
Try this one in the quiz: open example 3.
These are not questions from any ISTQB exam, and this site has no connection with ISTQB or any exam provider. Older question banks often use definitions from before version 4.0, so if an answer here disagrees with one you’ve seen elsewhere, check which syllabus it was written for. How the questions are made explains how every answer is checked.
To see the technique applied, read the four black-box techniques on one real checkout. To work your own example through, use the boundary value generator.