forked from jazzband/django-polymorphic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
77 lines (66 loc) · 1.55 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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
[tox]
envlist =
begincoverage
py37-django{22,30,31}
py38-django{22,30,31,32}
py39-django{40,41,42,43}
py310-django{40,41,42,43}
endcoverage
docs
lint
[testenv]
setenv =
PYTHONWARNINGS = all
postgres: DEFAULT_DATABASE = postgres:///default
postgres: SECONDARY_DATABASE = postgres:///secondary
deps =
coverage
dj-database-url
django22: Django ~= 2.2
django30: Django ~= 3.0
django31: Django ~= 3.1
django40: Django>=4.0a1,<4.1
django41: Django>=4.1,<4.2
django42: Django>=4.2,<4.3
djangomain: https://github.com/django/django/archive/main.tar.gz
postgres: psycopg2
makemigrations: Django>=4.0a1,<4.1
depends=
py{37,38,39,310}: begincoverage
endcoverage: py{37}-django{22,30,31}, py38-django22, py{38,39,310}-django{31,32}, py{39,310}-django{40,41,42,43}
commands =
coverage run -p --source polymorphic runtests.py
[testenv:begincoverage]
deps=coverage
commands = coverage erase
[testenv:endcoverage]
deps=coverage
commands =
coverage combine
coverage report
coverage xml -o ./.tox/coverage.xml
coverage html
[testenv:makemigrations]
commands = python runtests.py makemigrations
[testenv:lint]
deps =
black
flake8
flake8-black
commands =
black polymorphic
flake8 polymorphic
[testenv:docs]
deps =
Sphinx
sphinx_rtd_theme
-r{toxinidir}/docs/_ext/djangodummy/requirements.txt
changedir = docs
commands = sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html
[flake8]
# ignore line size
max-line-length = 300
extend-ignore =
# See https://github.com/PyCQA/pycodestyle/issues/373
E203
exclude = tests