Skip to content

Commit 2a841ab

Browse files
committed
Upload code coverage report to codecov.io
1 parent a51a371 commit 2a841ab

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

.github/workflows/unit-tests.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,14 @@ jobs:
4040
composer-options: --ignore-platform-reqs
4141

4242
- name: Run tests
43-
run: composer run phpunit -- --coverage-text
43+
run: composer run phpunit -- --coverage-clover .phpunit.cache/clover.xml
44+
45+
- name: Upload coverage reports to Codecov
46+
if: ${{ success() && matrix.php == '8.2' }}
47+
uses: codecov/codecov-action@v3
48+
env:
49+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
50+
with:
51+
files: ./.phpunit.cache/clover.xml
52+
fail_ci_if_error: true
53+
verbose: true

0 commit comments

Comments
 (0)