-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (31 loc) · 1016 Bytes
/
test.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: PR Coverage Diff - CI
on:
pull_request:
jobs:
run-tests:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-versions:
- "3.11"
name: Test Job
runs-on: ${{matrix.os}}
steps:
- name: Checkout PR branch
uses: actions/checkout@v4
- name: Set up python
uses: actions/setup-python@v4
with:
python-version: ${{matrix.python-versions}}
- name: Install dependencies
run: pip install pytest pytest-cov
- name: Run tests
run: pytest --cov
- name: Upload results to Codecov
run: |
# Replace `linux` below with the appropriate OS
# Options are `alpine`, `linux`, `macos`, `windows`
curl -Os https://cli.codecov.io/latest/linux/codecov
chmod +x codecov
./codecov --verbose upload-process --fail-on-error -t ${{ secrets.CODECOV_TOKEN }} -n 'service'-${{ github.run_id }} -F service -f coverage-service.xml