Usage of state transition testing in scenario
What is state transition testing?
State transition testing is a black box testing technique. Here system can be in a finite number of different states, and with transitions from one state to another. We get a different output for the same input, depending on what has happened prior.
You can derive test cases to test every transition drawn in state transition diagram. Test conditions can be derived from the state transition diagram in various ways. Each state or transition can be noted as a test condition. We can use state transition table to derive all possible combinations of valid and invalid transitions.
Transition need not change to a different state it can stay in the same state. Invalid input would display an error message as the action, but the transition would be back to the same state the system was in before.
How can we use state transition testing in scenario?
Scenario testing is done to ensure end to end functionality of software or all business process flow is working fine. We can use state transition testing to test how the different state of an object impact the other objects in a particular scenario. Will that scenario work as expected? Whether the transition happening in the right way, if the event that needs to be generated after the specified state is as designed, what if the event scheduled in the other way than expected, will the system handles that scenario with proper user message.
Advantages of using State transition testing in scenario:
Implementation of state transition testing technique in our test execution can improve quality of our product by finding more defects and can get more test coverage done. Test cases derived out of this can also be used as the document during knowledge sharing. Since state transition diagram makes the functionality represented pictorially, it would be more useful for the colleagues during ramping up of new topics.