It셲 important that all testers should be able to write test cases based on Equivalence partitioning and Boundary value analysis. Taking this into consideration ISTQB is having significant importance for this topic in ISTQB Foundation level Certificate exam. Good practice and logical thinking can make it very easy to solve these questions.

What is Equivalence partitioning?
Equivalence partitioning is a method for deriving test cases. In this method, equivalence classes (for input values) are identified such that each member of the class causes the same kind of processing and output to occur. The values at the extremes (start/end values or lower/upper end values) of such class are known as Boundary values. Analyzing the behavior of a system using such values is called
Boundary value analysis (BVA).

Here are few sample questions for practice from ISTQB exam papers on Equivalence partitioning and BVA. (Ordered: Simple to little complex)

Question 1
One of the fields on a form contains a text box which accepts numeric values in the range of 18 to 25. Identify the invalid Equivalence class.

a)    17
b)    19
c)    24
d)    21

The text box accepts numeric values in the range 18 to 25 (18 and 25 are also part of the class). So this class becomes our valid class. But the question is to identify invalid equivalence class. The classes will be as follows:
Class I: values < 18   => invalid class
Class II: 18 to 25       => valid class
Class III: values > 25 => invalid class

17 fall under invalid class. 19, 24 and 21 fall under valid class. So answer is 쁀

Question 2
In an Examination a candidate has to score minimum of 24 marks in order to clear the exam. The maximum that he can score is 40 marks.  Identify the Valid Equivalence values if the student clears the exam.

a)    22,23,26
b)    21,39,40
c)    29,30,31
d)    0,15,22

The classes will be as follows:
Class I: values < 24   => invalid class
Class II: 24 to 40       => valid class
Class III: values > 40 => invalid class

We have to indentify Valid Equivalence values. Valid Equivalence values will be there in Valid Equivalence class. All the values should be in Class II. So answer is 쁂

Question 3
One of the fields on a form contains a text box which accepts alpha numeric values. Identify the Valid Equivalence class
a)    BOOK
b)    Book
c)    Boo01k
d)    Book

Alpha numeric is combination of alphabets and numbers. Hence we have to choose an option which has both of these. A valid equivalence class will consist of both alphabets and numbers. Option 쁟 contains both alphabets and numbers. So answer is 쁂

Question 4
The Switch is switched off once the temperature falls below 18 and then it is turned on when the temperature is more than 21. When the temperature is more than 21. Identify the Equivalence values which belong to the same class.

a)    12,16,22
b)    24,27,17
c)    22,23,24
d)    14,15,19

We have to choose values from same class (it can be valid or invalid class). The classes will be as follows:

Class I: less than 18 (switch turned off)
Class II: 18 to 21
Class III: above 21 (switch turned on)

Only in Option 쁟 all values are from one class. Hence the answer is 쁂. (Please note that the question does not talk about valid or invalid classes. It is only about values in same class)

Question 5
A program validates a numeric field as follows: values less than 10 are rejected, values between 10 and 21 are accepted, values greater than or equal to 22 are rejected. Which of the following input values cover all of the equivalence partitions?

a. 10,11,21
b. 3,20,21
c. 3,10,22
d. 10,21,22

We have to select values which fall in all the equivalence class (valid and invalid both). The classes will be as follows:

Class I: values <= 9   => invalid class
Class II: 10 to 21       => valid class
Class III: values >= 22 => invalid class

All the values from option 쁟 fall under all different equivalence class. So answer is 쁂.