Main Content

Test Case Verification Status

Since R2021b

Metric ID

TestCaseVerificationStatus

Description

Use this metric to determine whether a test has pass/fail criteria.

A test has pass/fail criteria if it has at least one of the following:

  • at least one executed verify statement

  • at least one executed temporal or logical assessment

  • custom criteria that has a pass/fail status in Test Manager

  • baseline criteria which determine the pass/fail criteria of the test

Supported Artifacts

You can collect this metric for the Units in your project. To control what the dashboard classifies as a unit, see Categorize Models in Hierarchy as Components or Units.

Computation Details

The metric:

  • Includes only tests in the project that test the model or subsystems in the unit for which you collect metric data.

  • Does not count the pass/fail criteria of tests that run in software-in-the-loop (SIL) or processor-in-the-loop (PIL) mode. The metric shows these tests as Missing Pass/Fail Criteria.

Collection

To collect data for this metric:

  • In the Model Testing Dashboard, in the Model Test Status section, click the Inconclusive widget to view the TestCaseVerificationStatus results in a table.

  • Use getMetrics with the metric ID TestCaseVerificationStatus.

Collecting data for this metric loads the model file and test result files and requires a Simulink® Test™ license.

Results

For this metric, instances of metric.Result return Value as one of these integer outputs:

  • 0 — The test is missing pass/fail criteria.

  • 1 — The test has pass/fail criteria.

  • 2 — The test was not run.

See Also

Related Topics