-
Notifications
You must be signed in to change notification settings - Fork 1
38 lines (31 loc) · 910 Bytes
/
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
name: Tests
on:
pull_request:
branches: [ master, develop ]
workflow_call:
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["${{ vars.PYTHON_VERSION }}"]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip --no-cache-dir
pip install flake8 ruff isort --no-cache-dir
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Run flake8
run: |
flake8 backend --count --exit-zero --max-complexity=10 --max-line-length=79 --config=setup.cfg
- name: Run ruff
run: |
python -m ruff check -n .
- name: Run isort
run: |
isort -c .