Main Content


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

Capture equivalence criteria and add to test case


eq = captureEquivalenceCriteria(tc,replaceAll)


eq = captureEquivalenceCriteria(tc,replaceAll) runs the System Under Test in Simulation 1 and captures an equivalence criteria set. 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 capture equivalence criteria in, specified as an sltest.testmanager.TestCase object.

Replace existing equivalence criteria if criteria already exist in the test case, specified as a Boolean. true replaces existing criteria, and false produces an error if criteria already exist in the test case.

Output Arguments

expand all

Equivalence criteria added to 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);
Introduced in R2015b