Ubuntu Manpages

cgreen

a framework for C and C++ unit tests and mocking

Cgreen is a framework for creating and running compact and easy-to-read unittests for C and/or C++.

Here are some of its features:

  • Fluent API resulting in very readable tests
  • Expressive and clear output using the default reporter
  • Fully functional mocks, both strict and loose
  • Each test runs in its own process for test suite robustness
  • Automatic discovery and running of tests using dynamic library inspection
  • Extensive and expressive constraints for many datatypes
  • BDD-flavoured test declarations with Before and After declarations
  • Extensible reporting mechanism
  • Fully composable test suites
  • An isolated test can be run in a single process for debugging

cgreen-runner(1)

The full documentation for cgreen-runner and the Cgreen framework is in the Cgreen manual available at