hipcall/Mix Coverage
Parse mix test.coverage output (Elixir 1.20+), post a sticky PR comment, and enforce coverage thresholds.
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Activelast commit Jun 29, 2026
- License
- MIT
Pinned Snippet
uses: hipcall/mix-coverage-action@3244590516aef77e171cd52656e6e5e9b07ff1ee # v1.0.1tags can be moved; commit SHAs can't. why a SHA?
Inputs
| name | description | required | default |
|---|---|---|---|
| github-token | GitHub token used to post the PR comment. Pass secrets.GITHUB_TOKEN from the caller workflow. | yes | — |
| coverage-command | Command that produces a `mix test --cover` or `mix test.coverage` table on stdout. Ignored when `coverage-file` is set. | no | mix test.coverage |
| coverage-file | Path to a file containing pre-captured coverage output. When set, `coverage-command` is skipped. | no | "" |
| minimum-coverage | Fail the step when total coverage is below this percentage (0-100). Set to 0 to disable. | no | 0 |
| minimum-module-coverage | Fail the step when any reported module is below this percentage (0-100). Applies to every module in the report. Set to 0 to disable. | no | 0 |
| include-changed-files | When true and the event is `pull_request`, the PR comment includes a Changed files section listing modules mapped from files modified in the PR. Informational only; no gate is applied. | no | false |
| comment | PR comment behavior. One of `sticky` (create or update a marked comment), `new` (always add a new comment), or `off` (skip commenting). | no | sticky |
| working-directory | Directory to run the coverage command in. | no | . |
Outputs
| name | description |
|---|---|
| total-coverage | Total coverage percentage as a string, e.g. "85.70". |
| failed-modules | JSON array of modules below the per-module threshold after any changed-files filter. |