-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
62 lines (55 loc) · 1.65 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
56
57
58
59
60
61
62
[tox]
minversion = 3.18
envlist =
py{39,310}-django32
py{39,310,311}-django{41,42}
system-tests
flake
isort
black
[testenv]
deps =
.[tests]
django32: Django~=3.2.0
django41: Django~=4.1.0
django42: Django~=4.2.0
changedir = {toxinidir}/tests
commands =
coverage erase
coverage run --data-file={envdir}/.coverage --include="*/anfema_django_testutils/*" manage.py test
coverage html --data-file={envdir}/.coverage -d {envdir}/coverage-report --title={envname} --skip-empty
[testenv:system-tests]
description = Runs the system tests
basepython = python3.11
changedir = {toxinidir}/tests
commands = python -m unittest system_tests/system_tests.py
[testenv:flake]
description = Checks the code for compliance with Flake8 coding standards.
basepython = python3.11
changedir = {toxinidir}
deps = flakeheaven
commands = flakeheaven lint anfema_django_testutils tests
[testenv:isort]
description = Checks if imports are in the correct order and correctly formatted.
basepython = python3.11
changedir = {toxinidir}
deps = isort
commands = isort --check-only anfema_django_testutils tests
[testenv:black]
description = Checks if the code is formatted according to Black coding standards.
basepython = python3.11
changedir = {toxinidir}
deps = black
commands = black --check anfema_django_testutils tests
[testenv:docs]
description = Builds the package documentation into the given directory.
basepython = python3.11
changedir = {toxinidir}
skip_install = true
deps = .[docs]
commands = sphinx-build -n -a -E docs/source {posargs:docs/build}
[gh-actions]
python =
3.9: py39
3.10: py310
3.11: py311, flake, black, isort, system-tests