sltest.testsequence.findStep
Find test sequence steps
Description
returns
a cell array steps
= sltest.testsequence.findStep(Name,Value
)steps
listing Test Sequence steps
that match properties specified by Name,Value
pairs.
Examples
Find a test step in a Test Sequence block
This example finds a test step in a Test Sequence block.
1. Load the model.
Model = 'sltestRollRefTestExample';
load_system(Model)
2. Find test sequence steps that contain the case-insensitive string apeng
.
steps = sltest.testsequence.findStep('sltestRollRefTestExample/Test Sequence',... 'Name','[Aa][Pp][Ee]ng','RegExp','on')
steps = 1x10 cell
{'AttitudeLevels.APEngage_LowRoll'} {'AttitudeLevels.APEngage_LowRoll.SetLowPhi'} {'AttitudeLevels.APEngage_LowRoll.EngageAP_Low'} {'AttitudeLevels.APEngage_MedRoll'} {'AttitudeLevels.APEngage_MedRoll.SetMedPhi'} {'AttitudeLevels.APEngage_MedRoll.EngageAP_Med'} {'AttitudeLevels.APEngage_HighRoll'} {'AttitudeLevels.APEngage_HighRoll.SetHighPhi'} {'AttitudeLevels.APEngage_HighRoll.EngageAP_High'} {'AttitudeLevels.APEngagement_End'}
steps(3)
ans = 1x1 cell array
{'AttitudeLevels.APEngage_LowRoll.EngageAP_Low'}
3. Close the model.
close_system(Model,0)
Input Arguments
Name-Value Arguments
Specify optional pairs of arguments as
Name1=Value1,...,NameN=ValueN
, where Name
is
the argument name and Value
is the corresponding value.
Name-value arguments must appear after other arguments, but the order of the
pairs does not matter.
Before R2021a, use commas to separate each name and value, and enclose
Name
in quotes.
Example: 'Name','[Aa][Pp][Ee]ng','RegExp','on'
Name
— Step name
character vector
The name of the test steps to search
Example: 'Name','Engage'
Example: 'Name','[Aa][Pp][Ee]ng'
CaseSensitive
— Specify case-sensitive search
'on'
| 'off'
Specifies case
Example: 'CaseSensitive','on'
RegExp
— Specify regular expression search
'on'
| 'off'
Specify whether to search the step names using Name
as
a regular expression
Example: 'RegExp','on'
Output Arguments
steps
— Test sequence steps
cell array
Cell array of test steps matching search criteria
Example: 1×10 cell array
Version History
Introduced in R2017a
Abrir ejemplo
Tiene una versión modificada de este ejemplo. ¿Desea abrir este ejemplo con sus modificaciones?
Comando de MATLAB
Ha hecho clic en un enlace que corresponde a este comando de MATLAB:
Ejecute el comando introduciéndolo en la ventana de comandos de MATLAB. Los navegadores web no admiten comandos de MATLAB.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)