Skip to content

Bump django from 6.0 to 6.0.2 (#15) #10

Bump django from 6.0 to 6.0.2 (#15)

Bump django from 6.0 to 6.0.2 (#15) #10

Workflow file for this run

name: CI and unit tests
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-24.04
strategy:
matrix:
DJANGO_VERSION:
[
"django>=4.2,<5.0",
"django>=5.2,<6.0",
"django>=6.0,<6.1",
]
services:
postgres:
image: postgres:15
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
POSTGRES_DB: test
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: "3.13"
- name: Install Poetry
uses: snok/install-poetry@v1
with:
version: 2.0.1
- name: Install dependencies
run: poetry install --no-interaction
- name: Use ${{ matrix.DJANGO_VERSION }}
run: poetry add "${{ matrix.DJANGO_VERSION }}"
- name: Check code formatting
run: |
poetry run black --config=pyproject.toml --check datetimeutc
poetry run black --config=pyproject.toml --check tests
- name: Check import sort order
run: |
poetry run isort --settings=pyproject.toml --check datetimeutc
poetry run isort --settings=pyproject.toml --check tests
- name: Check code linter
run: |
poetry run pylint --rcfile pyproject.toml datetimeutc
poetry run pylint --rcfile pyproject.toml tests
- name: Check static types
run: |
poetry run mypy --config-file pyproject.toml datetimeutc
poetry run mypy --config-file pyproject.toml tests
- name: Run unit tests
run: DJANGO_SETTINGS_MODULE="settings" poetry run pytest