You are on page 1of 4

Test case design techniques

1. Boundary Value Analysis


- Definition:
Boundary Value Analysis is a method of testing all values in the boundary regions of
input and output data, instead off all value of data.
- When to use Boundary Value Analysis:
Boundary Value Analysis is used when the input data is single data fields like textboxes,
and the input value is limited between [x,y], testcase will include maximum, minimum,
inside or outside boundaries and a typical value.
- How to use Boundary Value Analysis:
If an input condition is a large number of values between [min,max], test cases should
be designed with:
+ Min value
+ Values above min
+ Values below min
+ Max value
+ Value above max
+ Value below max
If the system performs well with these values, it will perfectly well for all values between
the two boundary values.
For example:
The number of products in cart is only allowed to enter from 1 to 10
The testcase is designed with boundary values: 0,1,2 and 9,10,11
So, we will have 6 testcase as follow:
a. Product quantity = 1 => Valid
b. Product quantity = 2 => Valid
c. Product quantity = 9 => Valid
d. Product quantity = 10 => Valid
e. Product quantity = 0 => Invalid
f. Product quantity = 11 => Invalid

2. Equivalence Partitioning
- Definition:
Equivalence partitioning is a technique for dividing input into similar groups. If
one value in the group works properly, all the values in that group also work properly,
and vice versa.
- When to use Equivalence Partitioning
Equivalence Partitioning is used when the input data is single data fields like textboxes,
allow a large number of values and can be divided into partitions of values.
- How to use Equivalence Partitioning
+ Step 1: Identifying equivalence classes, at least 2 types of classes as follow:
 A class of valid value
 A class of invalid value
+ Step 2: Defining test cases base on these classes
For example:
The number of products in cart is only allowed to enter from 1 to 15
There are 3 equivalence classes:

So, we will have 3 testcase as follow:


i. Product quantity = -3 => Invalid
ii. Product quantity = 9 => Valid
iii. Product quantity = 18 => Invalid
3. Decision Table-Based Testing
- Definition:
Decision Table-Based Testing is a software testing technique used to test system
behavior for different input combinations. In Decision Table-Based Testing technique,
different input and their corresponding system behavior are captured in a tabular form.
- When to use
Decision Table-Based Testing is used when testing the behavior of the system with many
data fields.
- How to use
+ Step 1: List the input in row
+ Step 2: Enter all the rules in the column (if there are n fields, number of rules = 2n)
For example:
Create decision table for sign in function with 2 fields: username and password
Rule 1 Rule 2 Rule 3 Rule 4
Input
Username F T F T
Password F F T T
Output
N N N Y
Note:
F: invalid input data
T: valid input data
Y: sign in successfully
N: sign in unsuccessfully
4. State Transition
- Definition:
State transition is a technique which changes the input conditions causing a left state
change in the output, or Application under Test (AUT).
- When to use
State transition technique is used when:
 Testing the application for a limited set of input values.
 Tester wants to check the sequence of events happening in the application.
- How to use
Tester can do this technique by entering different input conditions but still following a
pre-set sequence.
For example:
In sign in function, if user enters a valid password in any of the first 3 times, the
system processes the login successfully. If the user enters an invalid password on the
first or second times, the system will remind to re-enter the password. When the user
enters the wrong password for the third time, the system will not allow to re-enter the
password and proceed to lock the account.
So, there are some testcases base on these above events as follow:
a. Enter the wrong password for the first time => Notify to re-enter the password
b. Enter the wrong password for the second time => Notify to re-enter the
password
c. Enter the wrong password for the 3rd time => The system will notify you to lock
the account
d. Enter the wrong password the first time, correct the second time => Sign in
successful
e. Enter wrong password 2 times, correct 3 times => Sign in successful
5. Error Guessing
- Definition:
Error guessing is a technique that describes the common error of the system based on
the tester's intuition and experience.
- When to use
Error guessing can be used anytime while writing testcases.
- How to use
Tester guesses and lists error by:
 Using test experience
 Have relevant knowledge and understanding of the system
 Intuition
For example:
a. Predict the case of entering spaces in text fields
b. Distinguish lower and upper characters in searching
c. Clicking the button when the value has not been entered

You might also like