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

Generate and store Circle-CI XML test reports #1576

Merged
merged 1 commit into from
Feb 28, 2022

Conversation

jwhitlock
Copy link
Member

Adjust the test commands to store the test results as XML, which are then stored as test results.

This may give more detailed information when a test fails. This could be extended to use a site like codecov to track coverage over time:

https://about.codecov.io/tool/circleci/

@jwhitlock jwhitlock force-pushed the circle-ci-xml-test-reports branch 3 times, most recently from c18ef07 to a250ef6 Compare February 25, 2022 22:00
@jwhitlock jwhitlock marked this pull request as draft February 25, 2022 22:12
@jwhitlock jwhitlock force-pushed the circle-ci-xml-test-reports branch 6 times, most recently from 3b3ee60 to 805e165 Compare February 25, 2022 23:30
Adjust the test commands to store the test results as XML, which are
then stored as test results.
@jwhitlock jwhitlock force-pushed the circle-ci-xml-test-reports branch from 805e165 to 26557ad Compare February 25, 2022 23:37
@jwhitlock jwhitlock marked this pull request as ready for review February 25, 2022 23:38
@jwhitlock
Copy link
Member Author

jwhitlock commented Feb 25, 2022

Like a lot of CI work, that took several rounds to get a working set of commands.

The hard part is that CircleCI runs docker commands on a remote instance, so you have to do some tricks to use a docker volume rather than mounting local folders (which is how I got this working locally). I used the Mounting folders doc to get me started.

The next hard part was writing YAML, but I'm pretty happy with the results.

As a bonus, the CircleCI display now knows how many tests ran when you view the "test" step:

CircleCI Tests Tab

.circleci/config.yml Show resolved Hide resolved
@groovecoder groovecoder merged commit c6fbdd1 into main Feb 28, 2022
@groovecoder groovecoder deleted the circle-ci-xml-test-reports branch February 28, 2022 19:33
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