Skip to content

Commit 2e38a03

Browse files
authored
Merge pull request #319 from DoubleML/s-workflows-coverage
Update workflows
2 parents 2334cb9 + 012efd7 commit 2e38a03

File tree

1 file changed

+18
-3
lines changed

1 file changed

+18
-3
lines changed

.github/workflows/pytest.yml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,21 +68,36 @@ jobs:
6868
matrix.config.python-version == '3.9'
6969
run: |
7070
pip install pytest-cov
71-
pytest --cov=./ --cov-report=xml
71+
pytest --cov=./ --cov-report=xml --cov-report=html
72+
73+
- name: Archive code coverage results
74+
if: |
75+
matrix.config.os == 'ubuntu-latest' &&
76+
matrix.config.python-version == '3.9'
77+
uses: actions/upload-artifact@v4
78+
with:
79+
name: code-coverage-report
80+
path: |
81+
coverage.xml
82+
htmlcov/
83+
retention-days: 5
7284

7385
- name: Upload coverage to Codecov
7486
if: |
7587
matrix.config.os == 'ubuntu-latest' &&
7688
matrix.config.python-version == '3.9'
77-
uses: codecov/codecov-action@v3
89+
uses: codecov/codecov-action@v5
7890
with:
79-
file: ./coverage.xml
91+
fail_ci_if_error: false
92+
files: ./coverage.xml
8093
flags: unittests
94+
token: ${{ secrets.CODECOV_TOKEN }}
8195

8296
- name: Upload coverage to codacy
8397
if: |
8498
matrix.config.os == 'ubuntu-latest' &&
8599
matrix.config.python-version == '3.9'
100+
continue-on-error: true
86101
uses: codacy/codacy-coverage-reporter-action@v1
87102
with:
88103
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}

0 commit comments

Comments
 (0)