-
Notifications
You must be signed in to change notification settings - Fork 1
33 lines (31 loc) · 904 Bytes
/
coverage.yml
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
name: Test and Coverage
on: [push, pull_request]
jobs:
test:
if: github.actor != 'dependabot[bot]'
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.10"
- name: Install Graphviz
run: |
sudo apt-get update
sudo apt-get install -y graphviz graphviz-dev
- name: Install Poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -
- name: Install dependencies
run: |
poetry install
- name: Run tests
run: |
poetry run pytest --cov=app --cov-report=xml
- name: Upload coverage to Codecov
run: |
bash <(curl -s https://codecov.io/bash)
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}