forked from torchbox/wagtailmedia
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtox.ini
83 lines (63 loc) · 1.68 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
78
79
80
81
82
83
[tox]
requires = tox-docker
skipsdist = True
toxworkdir = /home/vagrant/.tox
usedevelop = True
envlist =
py{36,37,38,39}-dj{20,21,22}-wag{27,210,211}
py{38,39}-dj{30,31}-wag{210,211}
interactive
flake
isort
[testenv]
install_command = pip install -e ".[testing]" -U {opts} {packages}
commands =
{posargs:coverage run runtests.py}
basepython =
py36: python3.6
py37: python3.7
py38: python3.8
py39: python3.9
{interactive,flake,isort}: python3.6
deps =
dj22: Django>=2.2,<2.3
dj30: Django>=3.0,<3.1
dj31: Django>=3.1,<3.2
wag27: wagtail>=2.7,<2.8
wag210: wagtail>=2.10,<2.11
wag211: wagtail>=2.11,<2.12
{interactive,flake,isort}: wagtail
[testenv:flake]
commands = {posargs:flake8 wagtailmedia}
[testenv:isort]
commands = {posargs:isort --check-only --diff wagtailmedia}
[testenv:interactive]
commands_pre =
python {toxinidir}/manage.py makemigrations
python {toxinidir}/manage.py migrate
python {toxinidir}/manage.py shell -c "from django.contrib.auth.models import User; User.objects.create_superuser('super', '[email protected]', 'super')"
commands =
{posargs:python manage.py runserver 0.0.0.0:8020}
docker =
postgres
redis
dockerenv =
POSTGRES_PASSWORD=postgres
POSTGRES_USER=postgres
POSTGRES_DB=postgres
setenv =
INTERACTIVE = 1
[docker:redis]
image = redis:5.0
healthcheck_cmd = redis-cli ping | grep -q PONG
healthcheck_interval = 3
healthcheck_timeout = 3
healthcheck_retries = 30
healthcheck_start_period = 5
[docker:postgres]
image = postgres:12.0
healthcheck_cmd = pg_isready
healthcheck_interval = 3
healthcheck_timeout = 3
healthcheck_retries = 30
healthcheck_start_period = 5