Reactive Systems logo

Automated Testing and Validation with Reactis®

February 4, 2012
Support
spacer
White Papers
 
Spacer

Reactis and the Reactis for C Plugin

Model-Based Design with Simulink and Stateflow

Model-Based Testing and Validation of Control Software with Reactis

This white paper discusses how the Reactis automatic test generation tool may be used to validate Simulink models of embedded control software and to test for conformance of Simulink models to code. Reactis Tester automatically generates test cases that stress the model. The test generation often uncovers run-time errors in Simulink models. The generated tests aim to maximize coverage with respect to a number of test coverage metrics including Modified Condition/Decision Coverage (MC/DC). Reactis Simulator is a simulation environment for Simulink models that enables the user to execute and debug models and to track coverage during test execution. Reactis Validator enables an engineer to formalize model requirements as assertions and perform an automatic check for requirement violations. Validator performs these checks by thoroughly simulating the model with the goal of violating assertions. When an assertion fails, Validator returns a test that highlights the problem. Test suites generated by Reactis serve as a testing oracle to determine if source code conforms to the behavior of a Simulink model. The Reactis for C Plugin integrates seamlessly with Reactis to offer white-box testing for the C code portions of models (S-Functions and Stateflow® custom code).


Using Reactis with TargetLink Models and TargetLink-Generated Code

The automated testing and validation capability of the Reactis tool suite significantly enhances the gains realized from a model-based design process. Reactis can successfully test, simulate, and debug models created using the dSPACE TargetLink® blockset. Combined with a special C Plug-in, Reactis also provides a robust test-generation and debugging capability for TargetLink- generated C code integrated into the modeling environment. This document describes the steps necessary to configure Reactis and TargetLink models for test generation, simulation, and debug and for the execution and validation of automatically-generated C code.

Reactis for C

Advanced Testing and Validation for a C Code Process

Finding Bugs in C Code with Reactis for C

Reactis for C, now in beta test, is scheduled for release in Fall 2010. This white paper discusses how the automatic test generation tool may be used to find bugs in C programs. Reactis Tester automatically generates test cases that stress a program, often uncovering run-time errors. The generated tests aim to maximize coverage with respect to a number of test coverage metrics including Statement, Decision, Condition and Modified Condition/Decision Coverage (MC/DC). Reactis Simulator is a simulation environment for C programs that enables the user to execute and debug programs and to track coverage during test execution. Reactis Validator enables an engineer to formalize application requirements as assertions and perform an automatic check for requirement violations. Validator performs these checks by thoroughly simulating the model with the goal of violating assertions. When an assertion fails (or a runtime error is detected), Validator returns a test that may be run in Simulator to replay a concrete execution sequence leading to the problem in order to understand, diagnose, and fix the bug.

Spacer