/
tox.ini
55 lines (49 loc) · 1.31 KB
/
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
44
45
46
47
48
49
50
51
52
53
54
55
[tox]
envlist = {py38,py39,py310}-dj32,
{py38,py39,py310,py311}-dj42,
migrations,
docs,
coverage
# Configuration for https://github.com/ymyzk/tox-gh-actions
[gh-actions]
python =
3.8: py38
3.9: py39
3.10: py310, migrations, coverage, docs
3.11: py311
[default]
deps = pip>9
-r{toxinidir}/tests/requirements/dev.txt
[testenv]
basepython =
py38: python3.8
py39: python3.9
py310: python3.10
py311: python3.11
deps =
dj32: Django>=3.2,<4.0
dj42: Django>=4.2,<5.0
{[default]deps}
setenv = PYTHON_PATH = {toxinidir}
DJANGO_SETTINGS_MODULE = tests.default
commands = {envpython} -Wd run_tests.py {posargs}
[testenv:migrations]
basepython = python3.10
deps = Django>=4.2,<5.0
{[default]deps}
setenv = {[testenv]setenv}
commands = django-admin makemigrations --dry-run --check
# Try to mimick Read The Docs' environment (Python 3.7, no explicit Django version)
[testenv:docs]
basepython = python3.10
deps = Sphinx<8.0
{[default]deps}
commands =
{envbindir}/sphinx-build -a -n -W -b html -d docs/_build/doctrees docs docs/_build/html
[testenv:coverage]
basepython = python3.10
commands = coverage run run_tests.py
coverage report -m --fail-under=85
deps = coverage
Django>=4.2,<5.0
{[default]deps}