-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (51 loc) · 1.74 KB
/
ci.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: CI
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
linters:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Installing flake8
run: |
pip install poetry
poetry config virtualenvs.create false
poetry install --with dev --no-root
- name: Lint
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 src --show-source --statistics
# exit-zero treats all errors as warnings
flake8 src --count --exit-zero --statistics
integration:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
pip install poetry
poetry config virtualenvs.create false
poetry install --with test --no-root
- name: Run integration tests
run: poetry run pytest src --cov
- name: Upload Codecov
uses: codecov/codecov-action@v3