Skip to content

Commit 5200a95

Browse files
authored
Add codecov configuration (pushingkarmaorg#615)
* Add codecov configuration * Separate claimed & unclaimed coverage reports * Re-enable coverage comments
1 parent 9d23ec0 commit 5200a95

File tree

2 files changed

+25
-4
lines changed

2 files changed

+25
-4
lines changed

.github/workflows/ci.yaml

+14-4
Original file line numberDiff line numberDiff line change
@@ -200,10 +200,18 @@ jobs:
200200

201201

202202
coverage:
203-
name: Process test coverage
203+
name: Process test coverage (${{ matrix.plex }})
204204
runs-on: ubuntu-latest
205205
needs: pytest
206206
if: always()
207+
strategy:
208+
matrix:
209+
plex: ['unclaimed', 'claimed']
210+
is-master:
211+
- ${{ github.ref == 'refs/heads/master' }}
212+
exclude:
213+
- is-master: false
214+
plex: claimed
207215
steps:
208216
- name: Check out code from GitHub
209217
uses: actions/checkout@v2
@@ -235,12 +243,14 @@ jobs:
235243
- name: Download all coverage artifacts
236244
uses: actions/download-artifact@v2
237245

238-
- name: Combine coverage results
246+
- name: Combine ${{ matrix.plex }} coverage results
239247
run: |
240248
. venv/bin/activate
241-
coverage combine coverage*/.coverage*
249+
coverage combine coverage-${{ matrix.plex }}*/.coverage*
242250
coverage report --fail-under=50
243251
coverage xml
244252
245-
- name: Upload coverage to Codecov
253+
- name: Upload ${{ matrix.plex }} coverage to Codecov
246254
uses: codecov/codecov-action@v1
255+
with:
256+
flags: ${{ matrix.plex }}

codecov.yml

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
codecov:
2+
branch: master
3+
4+
coverage:
5+
status:
6+
project:
7+
default:
8+
target: auto
9+
threshold: 10%
10+
11+
comment: true

0 commit comments

Comments
 (0)