TestOptimal Tutorials

Execute Model

Execute Model

This tutorial will cover:

  • Select sequencer
  • Set Stop Condition
  • Execute model
  • Review Test Cases

Execute Model

First, open a model, e.g. Demo_TestGenToFile

Execute Model - Select Sequencer

Sequencer is the core of MBT tool:

  • Generates Test Cases from Model
  • Determines the Test Coverage
  • Produces Test Cases of certain Usage Pattern

press down arrow for feature details

Execute Model - Select Sequencer

Sequencer and Coverage:

  • Random/Greedy:
    • Random Usage Pattern
    • Test Case Variations
    • Full Model Coverage
    • Continuous Execution or Stop Criteria

press down arrow for feature details

Execute Model - Select Sequencer

Sequencer and Coverage:

  • Optimal:
    • Least # of Test Cases
    • Full Model Coverage
    • Longer Test Cases
  • PathFinder:
    • Full Model Coverage
    • Test Case Variations
    • Mixture of Long and Short Test Cases

press down arrow for feature details

Execute Model - Select Sequencer

Sequencer and Coverage:

  • MCase Optimal/Serial:
    • Requirement Coverage
    • Partial Model Coverage
    • Specific Test Case/Use Case
    • High Priority Paths
    • Scneario-based Testing
    • Ad-Hoc Test Cases
  • PriorityPath:
    • High Priority Paths
    • Risk-based Testing

press down arrow for feature details

Execute Model - Select Sequencer

Select Sequencer through MBT Dialog:
click on menu Model / MBT Setting or

Execute Model - Set Stop Conditions

Edit Stop Conditions in MBT Setting -
click on menu Model / MBT Setting or

Stop Conditions are OR'ed, i.e. satisfying any of condition will cause model execution to stop

press down arrow for feature details

Execute Model - Set Stop Conditions

Stop Conditions:

  • Coverage % - used to achieve full or partial model coverage, testing model during development
  • Count / Path Count - stop after specified # of transitions or paths (test cases) are executed, achieve partial model coverage, testing model during development
  • Time - control testing during, useful for loading testing and catching memory leak or timed dependent defects.
  • Exceptions - run until the specified # of defects are found.
  • Stop at Final State Only - used to set AUT back to the expected state when testing ends

press down arrow for feature details

Execute Model - Run / Play / Debug

You can execute model in different modes:

  • Run - execute model (normal mode)
  • Play/Animate - execute model and
    highlight state/transition in realtime
  • Debug - - execute model and pause
    at initial node, allow stepping through
    states, transitions and MScript

press down arrow for feature details

Execute Model - Run / Play / Debug

Monitor Tab - Monitoring Execution Progress:

  • Automatic Updates on Execution Progress
  • Estimated Completion Time
  • Thread Execution - if running multiple threads (virtual users)

press down arrow for feature details

Execute Model - Run / Play / Debug

Play / Animate - Animate Model Execution
by highlighting state/transition as model executes:

press down arrow for feature details

Execute Model - Run / Play / Debug

Debug Model Execution - Click on or menu "Run / Debug"

  • Step In/MScript - stepping through MScript
  • Step Over - step over state/transition
    skipping MScripts
  • Step To - continue to the specified MScript
    line# or skip over # of MScript lines

press down arrow for feature details

Execute Model - Run / Play / Debug

Stop Model Execution:

  • When any of Stop Conditions is Satisified
  • Click on Stop button
  • Click on menu "Run / Stop"

Execute Model - Review Test Cases

During or After Model Execution:

  • Review Test Cases Generated (details next)
  • Check Test Coverage
  • Check Requirement Coverage - if requirements entered
  • Check Failures - if automation enabled

press down arrow for feature details

Execute Model - Review Test Cases

SeqTrace Tab - displays test cases in one long sequence:

press down arrow for feature details

Execute Model - Review Test Cases

Traversal Graph - displays test cases in graph:

press down arrow for feature details

Execute Model - Review Test Cases

Traversal Graph - displays test cases in Message Sequence Chart(MSC):

THE END

Visit other tutorials Here

© TestOptimal LLC.