You can upload your code coverage results to Codeac to view detailed coverage metrics alongside static analysis issues. By defining coverage thresholds, you can ensure consistent test quality and enforce them as part of your commit status checks.
The Code Coverage feature is currently in beta testing.
First, start generating lcov
files from your test framework. Here are a couple of tips for popular frameworks: Code Coverage in Codeac.
In Codeac, in repository settings, generate a $TOKEN
. Save $TOKEN
as a secret in your CI environment.
You can upload your coverage report to Codeac from your CI pipeline. Below is a command that securely uploads the report using your repository token and metadata from your Git commit and branch.
After successfully uploading code coverage, you can view in several places:
Codeac and your CI pipeline run in parallel, so code quality and coverage results may appear in the UI at different times. It can take a few minutes for all results to show up.
By specifying a minimum coverage threshold in your .codeac.yml
, you can ensure that your team maintains an acceptable level of test coverage.
To learn more about Code Coverage Thresholds, check out the documentation.