Main Content


Class: sltest.testmanager.ResultSet
Package: sltest.testmanager

Delete specified simulation test results in result set objects


bytes = clearSimulationData(rs,results)


bytes = clearSimulationData(rs,results) removes the simulation test results specified by results from the result set object array, rs.

Input Arguments

expand all

Results sets, specified as a sltest.testmanager.ResultSet object array.

Test results to remove from the results set, specified by one of the following options:

Output Arguments

expand all

Number of bytes deleted, returned as a positive integer.

Data Types: uint64


expand all

Open the model for this example.


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");

Remove the default test suite.

tsDel = getTestSuiteByName(tf,"New Test Suite 1");

Assign the system under test to the test case.


Capture the baseline criteria and set the tolerance.

baseline = captureBaselineCriteria(tc,"baseline_API.mat",true);
baseline.AbsTol = 15;

Change the model. Set the value of the Constant block, Desired relative slip, to 0.22.

set_param("sldemo_absbrake/Desired relative slip",Value="0.22");

Run the test case and return a sltest.testmanager.ResultSet object with results data.

resultsObj = run(tc);

Delete the passed baseline criteria comparison results.


Version History

Introduced in R2022a