Simulink® Coverage™ performs model and code coverage analysis that measures testing completeness in models and generated code. It applies industry-standard metrics such as decision, condition, modified condition/decision coverage (MCDC), and relational boundary coverage to assess the effectiveness of simulation testing in models, software-in-the-loop (SIL), and processor-in-the-loop (PIL). You can use missing coverage data to find gaps in testing, missing requirements, or unintended functionality.
Simulink Coverage produces interactive reports showing how much of your model, C /C++ S-functions, MATLAB® functions, and code generated by Embedded Coder® has been exercised. You can highlight coverage results in blocks and subsystems to visualize gaps in testing. To assess testing completeness, you can accumulate coverage data from multiple test runs. You can apply filters to exclude blocks from coverage and justify missing coverage in reports.
Learn the basic Simulink Coverage workflow
Learn how Simulink Coverage helps you to increase confidence in your design through end-to-end systematic verification
This example shows how to use the Configuration Parameters dialog to enable coverage for a Simulink® model and adjust the type of information that is reported.
Validate your model tests by measuring how thoroughly the model objects are tested.
Determine which actions to take to resolve missing coverage
Create and run test cases by using the model coverage MATLAB commands
Strategies for verifying functional units of your model, in isolation or in the context of a larger system.
Analyze functional dependencies, test model components in isolation, create suites of test cases, test models and code to achieve coverage.