Skip to content

Commit dd17851

Browse files
committed
Upload coverage reports to Codecov
1 parent 4bbfdfd commit dd17851

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

.github/workflows/python-app.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,12 @@ jobs:
3131
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
3232
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
3333
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
34-
- name: Test with pytest
34+
- name: Run tests and collect coverage
35+
run: pytest --cov .
36+
- name: Upload coverage reports to Codecov
3537
run: |
36-
cd tests
37-
coverage run -m pytest
38+
# Replace `linux` below with the appropriate OS
39+
# Options are `alpine`, `linux`, `macos`, `windows`
40+
curl -Os https://uploader.codecov.io/latest/linux/codecov
41+
chmod +x codecov
42+
./codecov -t ${CODECOV_TOKEN}

CONTRIBUTING.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ sudo python3 main.py --install true --version 13
2727
### Test
2828

2929
```bash
30-
cd tests
3130
# run test
3231
pytest
3332
# run test with code covarege

0 commit comments

Comments
 (0)