Main Content

remove

Class: sltest.testmanager.TestInput
Namespace: sltest.testmanager

Remove test input

Syntax

remove

Description

remove removes the test input from a test case. The test input object is empty after a call to this function.

Input Arguments

expand all

The test input that you want to remove, specified as a sltest.testmanager.TestInput object.

Examples

expand all

Remove a test case input that was loaded from Excel®

Load Example Model, Create New Test File, and Get Suites and Cases

open_system("slexAutotransRootInportsExample");
tf = sltest.testmanager.TestFile("input_test_file.mldatx");
ts = getTestSuites(tf);
tc = getTestCases(ts);

Add the Model as the System Under Test

setProperty(tc,Model="slexAutotransRootInportsExample");

Add Excel Data as Inputs to the Test Case

excelfile = "sltestExampleInputs.xlsx";
input = addInput(tc,excelfile);

Map the First Input Signal by Block Name

map(input(1),0);

Remove the Second Input from the Test Case

remove(input(2));

Version History

Introduced in R2015b