Run Unit Tests

Run test suites in the testing framework

Start Here

To run a group of tests in matlab.unittest, create a test suite from the matlab.unittest.TestSuite class. Test suites can contain:

  • All tests in a package

  • All tests in a class

  • All tests in a folder

  • A single test method

  • Arrays of test suites


runtests Run set of tests Run TestCase test Run TestSuite array using TestRunner object configured for text output Run all tests in TestSuite array
matlab.unittest.TestRunner.addPlugin Add plugin to TestRunner object


matlab.unittest.TestSuite Class for grouping tests to run
matlab.unittest.Test Specification of a single test method
matlab.unittest.TestRunner Class for running tests in matlab.unittest framework


matlab.unittest.parameters Summary of classes associated with MATLAB Unit Test parameters
matlab.unittest.plugins Summary of classes in MATLAB Plugins Interface
matlab.unittest.plugins.plugindata Summary of classes in MATLAB Plugin Data Interface
matlab.unittest.selectors Summary of classes in MATLAB Selectors Interface
Was this topic helpful?