-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: report coverage in Cobertura XML format (#946)
The simplest way to report XML coverage in our multi-language project is to separate coverage generation per language, using bespoke tools to generate/convert to XML (we use `python3-coverage` for Python, `gocov` to convert Go coverage to an intermediate JSON format, and `gocov-xml` to convert the JSON to Cobertura XML). Additionally, `reportgenerator` is used to combine the resulting XML files into a single report, which is then uploaded to Codecov. The way it works under the hood is: - skip Python XML generation if `reportgenerator`, `gocov`, or `gocov-xml` do not exist in the `PATH` - if the executables are present, Python coverage is converted to XML and copied to `$PROJECTROOT/coverage` - as part of the QA action, the Go-only coverage is converted to XML - the Python and Go XML files are combined to a single report using `reportgenerator` It's important to note that existing coverage generation is not affected by these changes, thus everything here is additive. Fixes UDENG-2034
- Loading branch information
Showing
3 changed files
with
139 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters