2022-08-25 03:41:19 +00:00
|
|
|
name: CI
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
pull_request:
|
|
|
|
jobs:
|
2023-05-25 09:50:09 +00:00
|
|
|
tests:
|
|
|
|
name: tests
|
2022-08-25 03:41:19 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2023-05-25 09:50:09 +00:00
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- uses: actions/setup-python@v4
|
2022-08-25 03:41:19 +00:00
|
|
|
with:
|
2023-05-25 09:50:09 +00:00
|
|
|
python-version: '3.10'
|
2022-08-25 03:41:19 +00:00
|
|
|
- uses: snok/install-poetry@v1
|
|
|
|
- run: poetry install
|
|
|
|
- name: Run backend tests
|
|
|
|
run: |-
|
|
|
|
poetry run python3 manage.py test
|
|
|
|
mypy:
|
|
|
|
name: mypy
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2023-05-25 09:50:09 +00:00
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- uses: actions/setup-python@v4
|
2022-08-25 03:41:19 +00:00
|
|
|
with:
|
2023-05-25 09:50:09 +00:00
|
|
|
python-version: '3.10'
|
2022-08-25 03:41:19 +00:00
|
|
|
- uses: snok/install-poetry@v1
|
|
|
|
- run: |-
|
|
|
|
poetry install
|
|
|
|
poetry run mypy
|
|
|
|
black:
|
|
|
|
name: black
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2023-05-25 09:50:09 +00:00
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- uses: actions/setup-python@v4
|
2022-08-25 03:41:19 +00:00
|
|
|
with:
|
2023-05-25 09:50:09 +00:00
|
|
|
python-version: '3.10'
|
|
|
|
- uses: snok/install-poetry@v1
|
|
|
|
- run: |-
|
|
|
|
poetry install
|
|
|
|
poetry run black . --check
|