Skip to content

Commit 39db804

Browse files
committed
feat: enhance testing workflow with improved coverage reporting and junit results upload
1 parent 8c51d49 commit 39db804

1 file changed

Lines changed: 12 additions & 2 deletions

File tree

.github/workflows/tests.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ jobs:
1010
test:
1111
runs-on: ubuntu-latest
1212
strategy:
13+
fail-fast: false
1314
matrix:
1415
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
1516

@@ -20,6 +21,7 @@ jobs:
2021
uses: actions/setup-python@v5
2122
with:
2223
python-version: ${{ matrix.python-version }}
24+
cache: "pip"
2325

2426
- name: Install dependencies
2527
run: |
@@ -34,9 +36,17 @@ jobs:
3436
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
3537
3638
- name: Run tests
37-
run: pytest --cov --cov-branch --cov-report=xml
39+
run: pytest --cov --cov-branch --cov-report=xml --junitxml=junit.xml
3840

39-
- name: Upload results to Codecov
41+
- name: Upload coverage to Codecov
4042
uses: codecov/codecov-action@v5
4143
with:
4244
token: ${{ secrets.CODECOV_TOKEN }}
45+
46+
- name: Upload test results to Codecov
47+
if: ${{ !cancelled() }}
48+
uses: codecov/codecov-action@v5
49+
with:
50+
token: ${{ secrets.CODECOV_TOKEN }}
51+
files: junit.xml
52+
report_type: test_results

0 commit comments

Comments
 (0)