Read properties of test sequence transition


transitionInfo = sltest.testsequence.readTransition(blockPath,stepPath,index)
transitionInfo = sltest.testsequence.readTransition(blockPath,stepPath,index,Property)


transitionInfo = sltest.testsequence.readTransition(blockPath,stepPath,index) returns a struct transitionInfo of properties for the transition index, in the test step stepPath of the Test Sequence block blockPath.

transitionInfo = sltest.testsequence.readTransition(blockPath,stepPath,index,Property) returns the value transitionInfo of the Property for the transition.


collapse all

This example reads properties of a test step and a transition in a Test Sequence block.

1. Load the model.

Model = 'sltestRollRefTestExample';

2. Read the properties of the test step SetMedPhi, which is a sub-step of AttitudeLevels.APEngage_MedRoll.

stepInfo = sltest.testsequence.readStep([Model,'/Test Sequence'],...
stepInfo = 

  struct with fields:

               Name: 'AttitudeLevels.APEngage_MedRoll.SetMedPhi'
             Action: 'Phi = 11.5;↵APEng = false;'
         IsWhenStep: 0
      IsWhenSubStep: 0
        Description: ''
    TransitionCount: 1

3. Read the action of the same step.

stepAction = sltest.testsequence.readStep([Model,'/Test Sequence'],...
stepAction =

    'Phi = 11.5;
     APEng = false;'

4. Read the transition properties for the parent step.

xInfo = sltest.testsequence.readTransition([Model,'/Test Sequence'],...
xInfo = 

  struct with fields:

         Step: 'AttitudeLevels.APEngage_MedRoll'
        Index: 1
    Condition: 'duration(DD_PhiRef == 0,sec) >= DurationLimit'
     NextStep: 'AttitudeLevels.APEngage_HighRoll'

5. Close the model.


Input Arguments

collapse all

Path to a Test Sequence block, including the block name, specified as a character vector.

Example: 'FanSpeedTestHarness/Test Sequence'

Path of the step in the Test Sequence block, specified as a character vector. The path includes the step location in the Test Sequence hierarchy, using . to separate hierarchy levels.

Example: 'SystemHeatingTest.InitializeHeating'

Integer specifying the transition in the test step to be edited. Corresponds to the integer displayed in the Transition cell of the Test Sequence Editor.

Example: 3

Transition property, specified as a character vector. To find valid properties for a particular symbol, read properties of the symbol using sltest.testsequence.readTransition(blockPath,stepPath,index).

Example: 'Step'

Example: 'Index'

Example: 'Condition'

Example: 'NextStep'

Output Arguments

collapse all

Example: struct

Introduced in R2017a

Was this topic helpful?