C/C++ Unit Testing Tool

Powered by Parasoft C/C++test, the most complete development testing solution for C and C++

Try Parasoft C/C++test

C++ Caps

Unit Testing on Host and Target for C and C++ Applications

With Parasoft C/C++test’s complete framework for unit testing, developers get everything they need to create, execute, and maintain tests. Integrating with leading IDEs, Parasoft C/C++test’s unit testing features include multi-metric code coverage analysis, a powerful stubbing/mocking framework, and automated cross-platform execution. These features are easy to use, reduce the burden of implementing unit testing, and improve developers' productivity.

Unit Testing

How does it work?

With a combination of convenient graphical editors and views, Parasoft C/C++test is used by developers who want to quickly build and execute their test cases, and testers, who benefit from its graphical editors.

Unit testing modules in Parasoft C/C++test include the Test Case Explorer, Test Case Editor, Stubs View, and Coverage View, which come together to simplify unit test creation and results analysis. Users can quickly discover untested code, locate unsatisfied stub call expectations, or find failed assertions, and corrections can be made right away from the views in which the problem was located.

Users optimize their testing efforts by analyzing merged coverage results (from previous tests, build-by-build) that present data generated from system and unit level testing, and the Coverage View can be synchronized with the Test Case Explorer to present filtered data for any arbitrary selection of test cases.

Suitable for use in large organizations as well as in small teams, users can either review their work directly in the IDE, or aggregate team-wide testing efforts for further post-processing, reporting, and advanced analytics through Parasoft’s web interface. From there, teams can generate interactive reports with traceability between requirements, source, and test cases.


Unit testing is easier and more productive when used together with a stubbing/mocking framework. Parasoft C/C++test provides a powerful module for automatically creating stubs and mocks, which can help in fault injection testing, reduce dependencies of the tested code, or simply stub out not-yet-implemented source code. Stub/mock logic is efficiently implemented using dedicated graphical editors or by typing code.

The C/C++test stubbing framework does not require any special code design to apply stubs (e.g. virtual functions) and is supported for all compilers, including cross-compilers.

Comprehensive code coverage reports automatically provide information about the thoroughness of the unit testing process (and are required to achieve compliance with functional-safety standards). Parasoft C/C++test supports all important types of code coverage, including statement, branch, and MC/DC coverage types.

Dedicated coverage views are closely integrated with the source code editor and Test Case Explorer, allowing developers to quickly understand coverage gaps and focus their effort based on areas of risk. Merging coverage results from different testing sessions (including from system-level testing) enables teams to focus their testing to untested code and tests impacted by recent code changes, thus reducing the amount of time spent on testing.

Parasoft C/C++test makes unit testing easier by simplifying the process of test case creation. With its easy-to-understand GUI, Parasoft C/C++test reduces technical barriers, allowing testers or QA staff, who don’t necessarily have deep development skills, to create unit tests.

Users can easily build advanced test scenarios by defining a collection of steps responsible for various elements of test scenario implementation, such as parameters initialization, stubs configuration, or assertions validation. Users with large test vectors recorded during a model simulation phase or during real-world experiments, can easily connect those data sources to parameterized test cases, which fetch test inputs and outputs directly from csv files or XLS spreadsheets.

Developers who prefer to create test cases and stubs by writing the source code instead of using graphical interface can use C/C++test's powerful APIs to define test cases logic and behavior of isolated components.

Parasoft C/C++test can be used to execute unit tests on the host platform, target processor simulator, or on the embedded target. Optimized to take minimal additional overhead for the binary footprint or process cycles, Parasoft C/C++test’s test harness is provided in the form of source code, and can be customized if platform-specific modifications are required. 

Dedicated integrations with embedded IDEs and debuggers make the process of executing unit test cases smooth and automated. Supported environments include Green Hills Multi, Wind River Workbench, IAR EW, ARM MDK, ARM DS-5, TI CCS, and many others.

Parasoft C/C++test’s unit testing framework was designed with safety-critical software testing in mind. Stubs and test cases with values for tested software simulation can be edited with graphical editors, but are generated as source code. Users can store and review created test artifacts together with the project’s files, and the initialization of the variables and input parameters for tested software simulation is done in exactly the same way as during production software operation. As such, the unit testing framework can be easily qualified for achieving compliance with safety standards such as ISO 26262, DO 178B/C, IEC 61508, or EN 50128. Parasoft C/C++test is certified by TÜV SÜD for these standards.

Benefit from the Parasoft Approach

Want to learn more?

Parasoft C/C++test integrates with a wide variety of software, tools and frameworks,
so you can easily adopt and scale within your existing development environment.

Streamlining Unit Testing for Embedded and Safety Critical Systems

Streamline Unit Testing for Embedded and Safety Critical Systems

Learn the key elements to successfully address unit testing in a way that's scalable across the entire project and organization, enabling more than just engineers to contribute to unit testing.