This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.


Create test iteration


iterObj = sltestiteration



iterObj = sltestiteration returns a test iteration object, sltest.testmanager.TestIteration. You can use the function in the MATLAB® command window, or you can use it in the context of a scripted iteration under the Iterations section of a test case. For more information on creating test iterations, see Test Iterations.


collapse all

This example is a script that must be entered in the Scripted Iterations script text box under the Iterations section of a test case. Also, the system under test for this example is a model that contains Signal Builder groups.

%% Iterate Over All Signal Builder Groups
% Determine the number of possible iterations
numSteps = length(sltest_signalBuilderGroups);
% Create each iteration
for k = 1 : numSteps
    % Set up a new iteration object
    testItr = sltestiteration;
    % Set iteration settings
    % Add the iteration to run in this test case
    % You can pass in an optional iteration name

Output Arguments

collapse all

Test iteration, returned as a sltest.testmanager.TestIteration object.

Introduced in R2016a