forked from businho/django-migrations-ci
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
43 lines (37 loc) · 925 Bytes
/
tox.ini
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
[tox]
isolated_build = true
envlist = py{310,311}-dj{32,42,50,latest}-{mysql,postgresql,sqlite},lint,mypy,py312-dj{50,latest}
[testenv]
allowlist_externals = poetry
setenv =
mysql: DATABASES_MODULE=mysql
postgresql: DATABASES_MODULE=postgresql
sqlite: DATABASES_MODULE=sqlite
commands =
poetry install --no-root --with dev
dj32: poetry run pip install "Django>=3.2,<4.0"
dj42: poetry run pip install "Django>=4.2,<5.0"
dj50: poetry run pip install "Django>=5.0,<5.1"
latest: poetry run pip install -U Django
poetry run pytest --cov-report xml:coverage{envname}.xml
[testenv:lint]
description = lint source code
deps =
ruff
commands =
ruff --check .
ruff format --check .
[testenv:mypy]
description = lint source code
deps =
mypy
django-stubs
pytest
pytest-django
commands =
mypy .
[gh-actions]
python =
3.10: py310
3.11: py311
3.12: py312