I have about five years of experience in C unit testing, particularly in embedded systems. One C unit testing framework that stands out is Check (Check | Unit testing framework for C). Here’s a list of other C unit testing frameworks:
- AceUnit: Mimics JUnit 4.x with reflection-like capabilities. Suitable for embedded software with no standard library functions. AceUnit homepage.
- GNU Autounit: Similar to Check, uses GLib, and runs tests in a separate address space. GNU Autounit homepage.
- cUnit: Uses GLib but does not fork to protect the address space.
- CUnit: Standard C, with plans for a Win32 GUI. Does not fork. CUnit homepage.
- CuTest: Simple framework with one .c and one .h file. CuTest homepage.
- CppUnit: For C++, can test C code. Requires a C++ compiler. CppUnit homepage.
- embUnit: For embedded systems, superseded by AceUnit. Embedded Unit homepage.
- MinUnit: Minimal set of macros for unit testing. MinUnit homepage.
- CUnit for Mr. Ando: New implementation in early development. CUnit for Mr. Ando homepage.
- CMocka: Test framework for C with mock objects. CMocka homepage.
- Criterion: Cross-platform with support for multiple formats. Each test runs in its own process. Criterion homepage.
- HWUT: General unit test tool with support for C, can create Makefiles and generate test cases. HWUT homepage.
- CGreen: Modern framework for C and C++, includes BDD notation and a mocking library. CGreen homepage.