Skip to content

Latest commit

 

History

History
22 lines (16 loc) · 794 Bytes

File metadata and controls

22 lines (16 loc) · 794 Bytes

🧪 C++ Code Coverage Example (GTest + lcov)

This repository demonstrates how to:

  • Build a C++ project with CMake and GoogleTest
  • Generate code coverage reports using lcov and genhtml
  • Automate everything via GitHub Actions

📦 What’s Inside

  • ✅ Unit tests with GoogleTest
  • ✅ Coverage tracking via --coverage flags
  • ✅ HTML report generation with genhtml
  • ✅ GitHub Actions workflow that:
    • Builds and tests your code
    • Captures and summarizes coverage
    • Uploads an artifact with the HTML report
    • Enforces a minimum coverage threshold (default: 80%)

🚀 Demo

  • Check the open PRs for this repository to see how it works in practice!