Skip to content

Commit 0474e77

Browse files
committed
Add coverage
1 parent 527799e commit 0474e77

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.github/workflows/tests.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,13 @@ jobs:
4848
run: |
4949
python -m pip list
5050
- name: Test with pytest
51-
run: pytest -v -n 2
51+
run: pytest -v -n 2 --cov=segmentation_models_pytorch --cov-report=xml
52+
- name: Upload coverage reports to Codecov
53+
uses: codecov/codecov-action@v5
54+
with:
55+
token: ${{ secrets.CODECOV_TOKEN }}
56+
slug: qubvel-org/segmentation_models.pytorch
57+
if: matrix.os == 'macos-latest' && matrix.python-version == '3.12'
5258

5359
minimum:
5460
runs-on: ubuntu-latest

requirements/test.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
pytest==8.3.4
22
pytest-xdist==3.6.1
3+
pytest-cov==6.0.0
34
ruff==0.8.4

0 commit comments

Comments
 (0)