Skip to content

Commit e3943aa

Browse files
committed
Prevent CI from trying to use '--cov' when pytest-cov is not installed
1 parent 2bd13ae commit e3943aa

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/main.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,12 @@ jobs:
3939
run: |
4040
python -m pip install tox
4141
- name: Run tests
42-
run: tox -- --cov-report xml
42+
run: tox
43+
- name: Create coverage report
44+
if: hashFiles('.coverage') != '' # Rudimentary `file.exists()`
45+
run: pipx run coverage xml --ignore-errors
4346
- name: Publish coverage
44-
if: false # disabled for #2727
47+
if: hashFiles('coverage.xml') != '' # Rudimentary `file.exists()`
4548
uses: codecov/codecov-action@v1
4649
with:
4750
flags: >- # Mark which lines are covered by which envs

0 commit comments

Comments
 (0)