Main Content

sltest.TestCase.forInteractiveUse

Class: sltest.TestCase
Namespace: sltest

Create test case for interactive use

Since R2020b

Description

example

testCase = sltest.TestCase.forInteractiveUse returns a test case instance configured for interactive use at the MATLAB command line. Use this method at the MATLAB command line to debug a TestCase object without having to write a complete test file. You cannot use this method within a test file.

Output Arguments

expand all

Instance of a test case, returned as an sltest.TestCase object. This instance is configured to print qualification failures and successes to the standard output, which is usually the screen.

Attributes

Staticyes

To learn about attributes of methods, see Method Attributes.

Examples

expand all

testCase =...
   sltest.TestCase.forInteractiveUse;
 
expected = testCase.simulate('myModel',...
   'SimulationMode','Normal');
actual = testCase.simulate('myModel',...
   'SimulationMode','Rapid-Accelerator');
 
testCase.verifySignalsMatch(actual,expected)

Version History

Introduced in R2020b