Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code coverage tools #7451

Draft
wants to merge 14 commits into
base: main
Choose a base branch
from
Draft

Code coverage tools #7451

wants to merge 14 commits into from

Conversation

starswan
Copy link
Contributor

@starswan starswan commented Jan 28, 2025

Trello card URL

https://trello.com/c/CUdxmu4H/1538-implement-coverage-checks-with-simplecov-lcov-simplecov-html-and-undercover-gems

Changes in this PR:

This introduces a suite of code coverage tools:

  • simplecov - the foundation

  • simplecov-html - a reporting tool showing human-readable coverage data

  • simplecov-lcov - a reporting tool in 'lcov' format, readable by machines

  • undercover
    This is integrated with git, and compares the coverage data with the 'current' branch against main. It will detect any 'changed' code and make sure that it has complete branch coverage. This can be overridden with the :nocov: annotation if really required

Coverage is off locally by default (it adds about 20% overhead with our current setup) but can be enabled with COVERAGE=1. It's switched on for CI (so that undercover can detect it)

Screenshots of UI changes:

Before

After

Coveraqge

@starswan starswan marked this pull request as ready for review January 28, 2025 17:06
@starswan starswan force-pushed the add-simplecov branch 2 times, most recently from 3cfe81b to 9108753 Compare January 29, 2025 16:13
@starswan starswan marked this pull request as draft January 30, 2025 08:50
@starswan starswan force-pushed the add-simplecov branch 3 times, most recently from 2794621 to 32da39a Compare January 31, 2025 09:12
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.

1 participant