-
Notifications
You must be signed in to change notification settings - Fork 1
55 lines (45 loc) · 1.49 KB
/
tests.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: tests
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches: [ main ]
pull_request:
branches: [ main ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
tests:
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Uncomment this part in case unit tests joins the party
# strategy:
# matrix:
# python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
# poetry-version: ["1.4.0"]
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.8
# python-version: ${{ matrix.python-version }}
- name: Run image
uses: abatilo/actions-poetry@v2
with:
poetry-version: latest
# poetry-version: ${{ matrix.poetry-version }}
- name: Setup the virtualenv for celery-prometheus
run: poetry install --with dev
- name: Check lint with Flake8
run: |
poetry run flake8 .
- name: Check imports with isort
run: |
poetry run isort -c .
- name: Check formatting with black
run: |
poetry run black -C .
- name: Check typing with mypy
run: |
poetry run mypy src/celery_prometheus/