Documentation

sltest.testmanager.ParameterSet class

Package: sltest.testmanager
Superclasses:

Add or modify parameter set

Description

Instances of sltest.testmanager.ParameterSet are sets of parameters in a test case that can override model parameters.

Construction

obj = sltest.testmanager.TestCase.addParameterSet creates a sltest.testmanager.ParameterSet object for a test case object.

Properties

expand all

Name of the parameter set, specified as a character vector.

File path of the parameter set if parameters were added from a file, returned as a character vector.

Indicates if the parameter set is enabled, 0 if it is not enabled, and 1 if it is enabled.

Methods

addParameterOverrideAdd parameter override to set
getParameterOverridesGet parameter overrides
removeRemove parameter set

Examples

expand all

% Create the test file, test suite, and test case structure
tf = sltest.testmanager.TestFile('API Test File');
ts = createTestSuite(tf,'API Test Suite');
tc = createTestCase(ts,'baseline','Baseline API Test Case');

% Assign the system under test to the test case
setProperty(tc,'Model','sldemo_absbrake');

% Test a new model parameter by overriding it in the test case
% parameter set
ps = addParameterSet(tc,'Name','API Parameter Set');
po = addParameterOverride(ps,'m',55);

Introduced in R2015b

Was this topic helpful?