Skip to content

Commit aa92483

Browse files
Fix coverage badge: parse Cover column instead of Miss (#29)
* Add pytest test suite with coverage and CI workflow * Fix ExecutionContext tests for FetchResponse return type * Add tests for FetchResponse dataclass and headers * Fix: preserve pytest exit code with pipefail in CI * Add testing and coverage documentation to AGENTS.md, README.md, and RELEASING.md * Add tests to reach 99% coverage: default config path, polling trigger validation, JSON parse fallback * Add CI, PyPI, Python, and license badges to READMEs; add coverage badge support to CI * Add coverage badge to READMEs * Update gistID for coverage badge * Include commit hash and message in coverage report title * Add release notes step to RELEASING.md and action-error-demo sample to README * Use actual PR head commit for coverage report title instead of merge commit * Show commit message and author in coverage report title * Use GitHub username for coverage title and always show coverage table * Replace MishaKav action with custom flat coverage comment * Fix coverage comment: write markdown to file to avoid backtick escaping issues * Link commit SHA and missing line numbers in coverage comment * Fix coverage parsing: use column 4 (Cover) not column 3 (Miss)
1 parent 0a3fdde commit aa92483

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

.github/workflows/tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ jobs:
5656
- name: Build coverage comment
5757
id: coverage
5858
run: |
59-
TOTAL=$(grep '^TOTAL' pytest-coverage.txt | awk '{print $(NF-1)}')
59+
TOTAL=$(grep '^TOTAL' pytest-coverage.txt | awk '{print $4}')
6060
echo "total=${TOTAL}" >> "$GITHUB_OUTPUT"
6161
6262
REPO_URL="${{ github.server_url }}/${{ github.repository }}"

0 commit comments

Comments
 (0)