# cpputest/cpputest

CppUTest unit testing and mocking framework for C/C++

Repository: https://github.com/cpputest/cpputest
Canonical: https://ross.abutalabs.com/products/cpputest
Homepage: http://cpputest.github.io
Language: C++
License: BSD-3-Clause
License Family: permissive
Topics: cpputest, unit-testing, test-driven-development, c-plus-plus, very-kewl, memory-leak, mocking-framework
Last push: 2026-07-30T11:59:16+00:00

## Health v2 (maintenance only)
Score: 66/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 95, release rhythm 8, longevity 100
- inputs: {"age_days": 5144, "days_push": 34, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1480, forks 530 (observed 2026-08-28T04:04:50.757385+00:00)

## What it is
CppUTest is a C/C++ xUnit-style unit testing and mocking framework, written in C++ but usable from both C and C++ projects. It is designed for test-driven development, includes a built-in memory leak detector, and is especially popular in embedded systems work.

## Use cases
- unit test c code
- unit testing framework for c++
- mocking framework for embedded c
- detect memory leaks in c++ tests
- test-driven development for embedded c
- test legacy c code in a harness

## When to choose
- You are doing TDD in C or C++, especially on embedded or resource-constrained platforms
- You need built-in memory leak detection and mocking in a lightweight xUnit framework
- You need portability to old compilers and platforms

## When to avoid
- You prefer a modern C++ framework with rich assertion APIs like Catch2 or GoogleTest
- Your project is not C/C++

## Facets
- artifact type: library
- maturity: stable
- function: testing, mocking
- domain: testing, developer-tools, embedded-systems
- platform: windows, cpp, c, cross-platform
- tags: unit-testing, xunit, test-driven-development, memory-leak-detection, embedded, linux, macos

## Member repositories
- cpputest/cpputest (main) score 66

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:50.757385+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:34:14.090262+00:00, confidence not recorded.
  - readme: https://github.com/cpputest/cpputest (fetched 2026-08-28T04:04:50.757385+00:00, sha ab3bd688ff4c)
  - homepage: http://cpputest.github.io (fetched 2026-08-29T11:41:00.907786+00:00, sha 618015c743fb)
- Data as of 2026-08-30T08:39:29.467469+00:00.
