Sign inSign up

skluck/circleci-required-coverage

By skluck

•Updated about 8 years ago

Ensure unit test coverage in Circle CI is increased on every pull request with no external tools

Image
0

10K+

skluck/circleci-required-coverage repository overview

https://github.com/skluck/circleci-code-coverage-compare⁠

This project provides a way to ensure unit test coverage is increased in every pull request without the need for external tools such as Coveralls.io.

It does this by providing the following functionality:

  1. Parse clover XML output to generate a total unit test code coverage

  2. Cache this value as a file within Circle CI, using the commit SHA as the key.

  3. If the job is running on non-master:

    1. Fetch the current commit SHA of the master branch using the GitHub API
    2. Load from cache the coverage stored for that SHA
    3. Compare the values, and fail the job if code coverage is not increased.

Tag summary

Content type

Image

Digest

Size

299.9 MB

Last updated

about 8 years ago

docker pull skluck/circleci-required-coverage