Contenu principal

Unit Boundary MCDC Coverage Breakdown

R2026b
Since R2022b

Metric ID

UnitBoundaryMCDCCoverageBreakdown

Description

This metric returns the fraction of overall achieved MC/DC coverage that comes from unit-boundary tests.

Supported Artifacts

This metric collects metric results for Units in the project. To control what the dashboard classifies as a unit, see Categorize Models in Hierarchy as Components or Units.

Computation Details

The metric:

  • Analyzes the overall aggregated coverage results.

  • Does not analyze coverage from tests that run in software-in-the-loop (SIL) or processor-in-the-loop (PIL) mode.

Collection

To collect metric results, execute the metric engine using the metric ID.

metricEngine = metric.Engine;
metricResults = execute(metricEngine,"UnitBoundaryMCDCCoverageBreakdown")

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

Results

For this metric, instances of metric.Result return the Value as a structure that contains these fields:

  • Numerator — The number of unit-boundary tests that contribute to the overall achieved MC/DC coverage.

  • Denominator — The total number of tests (unit-boundary and non-unit-boundary) that contribute to the overall achieved MC/DC coverage.

  • Value — The ratio of unit-boundary tests to all tests that contribute to MC/DC coverage, calculated by dividing the Numerator by the Denominator.

Compliance Thresholds

This metric does not have predefined thresholds.

See Also

Objects

Functions

Topics