IDE & Navigation
Properties & Tools
Sequence Mode is the test case generation algorithm used to generate test cases and test sequences from the model. TestOptimal supports several algorithms ranging from random walk to optimal sequencer and custom test case generation.
There are two ways to select the Sequence Mode for model execution.
TestOptimal supports 7 test sequencers to generate test sequences or test cases from the model. All of them can be used for both Online MBT Testing and Offline MBT Testing.
Depending on your testing objective, some sequencers may produce better or more desirable test cases from your model than others. You should experiment with these sequencers for each model to determine which sequencer meets your needs better.
OptimalSequencer generates the optimal test sequence that covers all of the transitions (links and buttons) in the model. OptimalSequencer implements modified algorithm for Chinese Postman Problem to generate test sequence from the model (graph). The optimal here has several meanings:
If used with Marked mode, it will generate test sequence to cover the marked states and transitions.
RandomSequencer also known as Markovian Chain generates test sequence by walking the model randomly. The transitions are selected for traversal based on the assigned weight. The higher the weight is, the more often it will be traversed.
This sequencer is very effective for online testing (test automation). It continuously generates test sequence until a stop condition is met. This is typically used for load and stress testing and finding defects caused by long running system like memory leak or deadlock situation.
GreedySequencer is similar to RandomWalk except that it prefers un-traversed transitions over already traversed transitions, as the result it can achieve better coverage of the model more quickly. However it can also be used to generate test sequence continuously.
PathFinder generates the test sequence using Genetic Algorithm (GA) to achieve more extensive coverage of different variations. The test paths generated by PathFinder generally provides better coverage than Basis Path algorithm.
PriorityPath generates the test sequence consisting of many short paths (test cases) to cover the transitions with higher weight (higher risk) first. If used with Marked mode, it will generate test sequence to cover the marked states or transitions, again higher weight transitions will be covered first.
The default transition weight is 5. It is recommended that high priority transitions be assigned a value at least 10 for small models and much larger value for larger models.
You may increase the sensitivity of the sequencer (how aggressive high priority transitions are chosen first) by increasing the gap of the weight values between high priority transition and the rest of the transitions.
MCaseOptimal generates the shortest test sequence to cover all of the transitions in MCases. The test steps defined in each MCase need not be consecutive or in any order, the system will find the optimal way to fill the gap with transitions from the model.
MarkedOnlyOptimal generates the shortest test sequence to cover the states and transtions that are marked. The states and transitions marked may not be adjacent. However, the generated test sequence will most likely not follow the order the states and transitions are marked. Use this sequencer to generate custom test cases. Note marked states will have all of its incoming and outgoing transitions covered.
MarkedOnlySerial is similar to MarkedOnlyOptimal except that the sequencer will attempt to preserve the order the state and transitions are marked. Another difference is that it will only cover each marked state once and repeat if necessary, but will not try to cover all of the incoming and outgoing transitions like MarkedOnlyOptimal sequencer.
Different sequencer produces test sequence or test cases achieving different effects on test coverage. You should evaluate them and determine which sequencer is a better choice for each model and test objective. Keep in mind that you may change the sequencer anytime.
For example if your goal is to ensure all links and buttons are tested, OptimalSequencer may be the best sequencer for the model as it produces the least number of test steps to cover the entire model which means that you will finish the test execution in least amount of time.
If you are looking for testing different variations and paths of the model, then PathFinder, RandomSeqencer or GreedySequencer may suit your needs better.