2. Reactis Overview#

In this section we give a brief overview of Reactis functionality that is useful for Automotive SPICE. For a more detailed introduction to Reactis please see Testing and Validation of Simulink Models with Reactis or the Reactis for Simulink User’s Guide.

Reactis consists of three main components:

Reactis Tester

generates comprehensive test suites from Simulink models.

Reactis Simulator

is an advanced model debug environment that lets you execute Reactis-generated tests in order to diagnose and debug any issues uncovered by Reactis. It also lets you interactively construct tests, track test coverage, and generate reports.

Reactis Validator

lets you check if a Simulink model satisfies its requirements.

Reactis Tester uses a collection of structural coverage metrics including decision coverage, condition coverage, and modified condition/decision coverage (MC/DC) to generate tests. Tester aims to maximize the level of coverage for each metric with the test suites it creates. For each test that Reactis creates, it stores the input values which drive the simulation to exercise the different coverage targets, along with the output values that the model computes in response to the inputs at each step.

The structure of Tester-generated tests makes them useful for a number of different activities. First, since they maximize coverage, Reactis performs a very comprehensive simulation of the model under test as the tests are being constructed. This makes it likely that any potential runtime errors in the model will be detected and flagged. Reactis searches for different types of runtime errors including overflows, divide-by-zero occurrences, floating point computations resulting in Inf or NaN, bad indexes to a vector or Multiport Switch block, and infinite loops.

A second use for the test suites is regression testing. A test suite generated from an old version of the model can be run on a revised version of the model in Reactis Simulator. Whenever Simulator executes tests, it compares the output values stored in the test against those computed by the model and flags any differences. A mechanism is available for specifying a tolerance for these comparisons, both a global one and a tolerance a specific output.

Finally, the generated tests can be used for back-to-back testing to check for conformance of C code to the Simulink model that specifies its behavior. In this use case, tests are generated from the model then run on the C code. Reactis for C, a version of Reactis that can be applied directly to C code, can easily execute the tests generated by Reactis for Simulink and flag any differences in computed outputs. Additionally, Reactis for C tracks coverage at the code level and flags any runtime errors in the C code.

Reactis Validator lets you formulate a requirement the model should satisfy as an assertion (using a c-like notation or a Simulink observer model) and then perform an automated search for violations of the requirement. If a violation is detected, then a test is returned that can be executed in Reactis Simulator to diagnose and debug the issue.

For each of the verification activities described here Reactis can generate HTML reports to summarize the outcomes and provide extensive details about the testing.

Reactive Systems logo