User`s guide

Language and Programming
2-9
LoggingPlugin or TestRunProgressPlugin, or a test runner constructed with the
TestRunner.withTextOutput method.
Constraint for scalar values in unit testing framework
You can use the matlab.unittest.constraints.IsScalar constraint class to test that an
actual value is a scalar.
Test suites from packaged functions and scripts
The unit testing framework recognizes function-based and script-based tests
that are contained within a user-defined package. For more information, see
TestSuite.fromPackage and runtests.
Failure of unit tests using a relative tolerance when the expected value is
infinite and the actual value is finite
If a test qualification applies a relative tolerance and the expected value is infinite, the
test fails if the actual value is finite. For example,
tc = matlab.unittest.TestCase.forInteractiveUse;
tc.verifyEqual(1,Inf,'RelTol',1e-12);
Interactive verification failed.
---------------------
Framework Diagnostic:
---------------------
verifyEqual failed.
--> The values are not equal using "isequaln".
--> The error was not within relative tolerance.
--> Failure table:
Index Actual Expected Error RelativeError RelativeTolerance
_____ ______ ________ _____ _____________ _________________
1 1 Inf -Inf NaN 1e-12
Actual double:
1
Expected double: