Skip to content

Test against current Django & python #10

Test against current Django & python

Test against current Django & python #10

Workflow file for this run

name: Test
on:
push:
branches:
- master
pull_request:
types: [opened, synchronize, reopened]
jobs:
lint:
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 and configure Poetry
uses: snok/install-poetry@v1
with:
version: 1.5.1
virtualenvs-create: true
virtualenvs-in-project: false
virtualenvs-path: /home/runner/.cache/pypoetry/virtualenvs
installer-parallel: true
- name: Cache Poetry virtualenv
uses: actions/cache@v1
id: cache
with:
path: /home/runner/.cache/pypoetry/virtualenvs
key: lint-poetry-${{ hashFiles('**/poetry.lock') }}
restore-keys: |
lint-poetry-${{ hashFiles('**/poetry.lock') }}
- name: Install Dependencies
run: poetry install
- name: Lint
run:
make ci.lint
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
django-version: ["3.2", "4.2"]
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install and configure Poetry
uses: snok/install-poetry@v1
with:
version: 1.5.1
virtualenvs-create: true
virtualenvs-in-project: false
virtualenvs-path: /home/runner/.cache/pypoetry/virtualenvs
installer-parallel: true
- name: Cache Poetry virtualenv
uses: actions/cache@v1
id: cache
with:
path: /home/runner/.cache/pypoetry/virtualenvs
key: poetry-${{ hashFiles('**/poetry.lock') }}
restore-keys: |
poetry-${{ hashFiles('**/poetry.lock') }}
- name: Install Dependencies
run: poetry install
- name: Test
run: poetry run tox -e py${{ matrix.python-version }}-django${{ matrix.django-version }}