Skip to content

Automate coverage via CTest post-test hooks#1885

Open
thetic wants to merge 1 commit into
cpputest:masterfrom
thetic:feature/coverage-automation
Open

Automate coverage via CTest post-test hooks#1885
thetic wants to merge 1 commit into
cpputest:masterfrom
thetic:feature/coverage-automation

Conversation

@thetic
Copy link
Copy Markdown
Contributor

@thetic thetic commented Apr 1, 2026

Add configs so that lcov capture, filtering, and genhtml run automatically after ctest completes. Wire the coverage preset to load these configs, and update the CI workflow to drop the manual lcov shell steps and point coverallsapp at the new output path. This means the exact coverage workflow used in CI to feed coveralls can now also be run locally to produce HTML reports.

Add cmake/lcov.cmake and cmake/CTestCustom.cmake.in so that lcov
capture, filtering, and genhtml run automatically as CTEST_CUSTOM_POST_TEST
hooks after ctest completes. Wire the coverage preset to load lcov.cmake
via CMAKE_PROJECT_CppUTest_INCLUDE, and update the CI workflow to drop
the manual lcov shell steps and point coverallsapp at the new output path
(cpputest_build/coverage.lcov).
@coveralls
Copy link
Copy Markdown

Coverage Status

coverage: 99.281%. remained the same
when pulling 102bc19 on thetic:feature/coverage-automation
into 79c066e on cpputest:master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants