Must Learn!

Big Data


What is State Transition Testing?

State Transition testing is defined as the testing technique in which changes in input conditions causes state changes in the Application Under Test(AUT).


State Transition Testing Technique is helpful where you need to test different system transitions.

This is further explained using an example in the video given below

Please be patient. The Video will load in some time. If you still face issue viewing video click here



For example, we have a flight reservation login screen, consider you have to enter correct agent name and password in the login screen to access the flight reservation application at first attempt.

What is State Transition Testing? State Transition Diagram

It gave you the access to the application with correct password and login name, but what if you entered the wrong password.

How system decides how many login attempts should be allowed to users for the login screen with the wrong password before it finally closes the application.

For our flight reservation application, we allowed 3 attempts, and if users enter the wrong password at 4th attempt, the system closes the application automatically.

So, testing for scenario 1 with the correct password and the 4th scenario with an incorrect password is compulsory, for that we use state transition testing.

What is State Transition Testing? State Transition Diagram

You can use State Table to determine invalid system transitions.

In a state Table, all the valid states are listed on the left side of the table, and the events that cause them on the top.

Each cell represents the state system will move to when the corresponding event occurs.

For example, while in S1 state you enter a correct password you are taken to state S6 (Access Granted). Suppose if you have entered the wrong password at first attempt you will be taken to state S3 or 2nd Try.

Likewise, you can determine all other states.

Two invalid states are highlighted using this method which basically means, what happens when you are already logged into the application, and you open another instance of flight reservation and enter valid or invalid passwords for the same agent.

System response for such a scenario need to be tested.