Skip to content

Commit afb6c90

Browse files
committedDec 11, 2024
Add coverage report to test action
1 parent dda3d4e commit afb6c90

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed
 

‎.github/workflows/tests.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,17 @@ on:
77
pull_request:
88

99
jobs:
10-
test:
11-
runs-on: ubuntu-latest
12-
10+
build-test:
11+
runs-on: ${{ matrix.os }}
1312
strategy:
13+
fail-fast: true
1414
matrix:
15-
python-version: ['3.8', '3.9', '3.10', '3.11']
15+
os: ["ubuntu-latest", "macos-latest", "windows-latest"]
16+
python-version: ["3.8", "3.9", "3.10", "3.11"]
1617

1718
steps:
1819
- name: Check out repository
19-
uses: actions/checkout@v3
20+
uses: actions/checkout@v4
2021

2122
- name: Set up Python
2223
uses: actions/setup-python@v4
@@ -29,4 +30,8 @@ jobs:
2930
pip install .[test]
3031
3132
- name: Run tests
32-
run: pytest
33+
run: pytest --cov-report=xml
34+
35+
- name: Upload coverage report
36+
if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.10'}}
37+
uses: codecov/codecov-action@v3

0 commit comments

Comments
 (0)