Skip to content

Commit

Permalink
Merge pull request #7 from taskiq-python/feature/new-ci
Browse files Browse the repository at this point in the history
Updated CI.
  • Loading branch information
s3rius authored Sep 13, 2022
2 parents 4e9836a + 148fd38 commit 9efc168
Showing 1 changed file with 20 additions and 42 deletions.
62 changes: 20 additions & 42 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,48 +3,29 @@ name: Testing taskiq-aio-pika
on: push

jobs:
black:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.9"
- name: Install deps
uses: knowsuchagency/poetry-install@v1
env:
POETRY_VIRTUALENVS_CREATE: false
- name: Run black check
run: poetry run black --check .
flake8:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.9"
- name: Install deps
uses: knowsuchagency/poetry-install@v1
env:
POETRY_VIRTUALENVS_CREATE: false
- name: Run flake8 check
run: poetry run flake8 --count .
mypy:
lint:
strategy:
matrix:
cmd:
- black
- flake8
- isort
- mypy
- autoflake
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install poetry
run: pipx install poetry
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "3.9"
cache: "poetry"
- name: Install deps
uses: knowsuchagency/poetry-install@v1
env:
POETRY_VIRTUALENVS_CREATE: false
- name: Run mypy check
run: poetry run mypy .
run: poetry install
- name: Run lint check
run: poetry run pre-commit run -a ${{ matrix.cmd }}
pytest:
services:
rabbit:
Expand All @@ -66,17 +47,14 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v2
- name: Install poetry
run: pipx install poetry
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: "${{ matrix.py_version }}"
- name: Update pip
run: python -m pip install -U pip
- name: Install poetry
run: python -m pip install poetry
cache: "poetry"
- name: Install deps
run: poetry install
env:
POETRY_VIRTUALENVS_CREATE: false
- name: Run pytest check
run: poetry run pytest -vv -n auto --cov="taskiq_aio_pika" .

0 comments on commit 9efc168

Please # to comment.