Skip to content

Commit b98e8cb

Browse files
ci: add codecoverage action to test workflow (#117)
Integrate ggilder/codecoverage@v1 to annotate pull requests with missing test coverage. The action processes the clover.xml coverage report generated by PHPUnit and highlights lines that lack test coverage directly in PR reviews. --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent ac7133c commit b98e8cb

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

.github/workflows/test.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,13 @@ jobs:
4848
- name: Run tests
4949
run: vendor/bin/phpunit --coverage-clover build/logs/clover.xml
5050

51+
- name: Code Coverage Annotation
52+
uses: ggilder/codecoverage@v1
53+
with:
54+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
55+
COVERAGE_FILE_PATH: build/logs/clover.xml
56+
COVERAGE_FORMAT: clover
57+
5158
- name: Upload test results
5259
if: always()
5360
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6

0 commit comments

Comments
 (0)