Main Content


Class: sltest.testmanager.TestCase
Package: sltest.testmanager

Get equivalence criteria from test case


eq = getEquivalenceCriteria(tc)


eq = getEquivalenceCriteria(tc) gets the equivalence criteria set from the test case. The function returns an equivalence criteria object, sltest.testmanager.EquivalenceCriteria. This function can be used only if the test type is an equivalence test case.

Input Arguments

expand all

Test case to get equivalence criteria from, specified as an sltest.testmanager.TestCase object.

Output Arguments

expand all

Equivalence criteria in the test case, returned as an sltest.testmanager.EquivalenceCriteria object.


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,'equivalence','Equivalence Test Case');

% Remove the default test suite
tsDel = getTestSuiteByName(tf,'New Test Suite 1');

% Assign the system under test to the test case
% for Simulation 1 and Simulation 2

% Capture equivalence criteria
eq = captureEquivalenceCriteria(tc);

% Set the equivalence criteria tolerance for one signal
sc = getSignalCriteria(eq);
sc(1).AbsTol = 2.2;

% Get and check the equivalence criteria
eq = getEquivalenceCriteria(tc);
Introduced in R2015b