Skip to content
This repository was archived by the owner on Aug 9, 2021. It is now read-only.

Commit cbb6afa

Browse files
authored
Add codecov badge (#31)
* Add codecov upload action to Github Actions * Add codecov badge to README * Remove write coverage report Didn't have a coverage directory initialised so cp to dir in CI bugged out
1 parent 659f802 commit cbb6afa

File tree

2 files changed

+14
-2
lines changed

2 files changed

+14
-2
lines changed

.github/workflows/python-package.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,14 @@ jobs:
5050
run: poetry run black . --check
5151

5252
- name: Test with pytest
53-
run: poetry run pytest --cov . -n 2
53+
run: poetry run pytest --cov . -n 2 --cov-report=xml
54+
55+
- name: Upload coverage to Codecov
56+
uses: codecov/codecov-action@v1
57+
with:
58+
token: ${{ secrets.CODECOV_TOKEN }}
59+
file: ./coverage.xml
60+
flags: unittests
61+
env_vars: OS,PYTHON
62+
name: codecov-umbrella
63+
fail_ci_if_error: true

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
# Dublin Region Energy Masterplan Code Guide
1+
# Dublin Region Energy Masterplan (drem)
2+
3+
[![Codecov](https://codecov.io/gh/codema-dev/drem/branch/master/graph/badge.svg)](https://codecov.io/gh/codema-dev/drem)
24

35
## Installation
46

0 commit comments

Comments
 (0)