forked from torchbox/wagtail-grapple
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
92 lines (73 loc) · 2.15 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
84
85
86
87
88
89
90
91
92
[tox]
min_version = 4.0
envlist =
py{38,39,310}-django{32,41}-wagtail{41,50,51}
py{311}-django{41,42}-wagtail{50,51}
interactive
[gh-actions]
python =
3.8: py38
3.9: py39
3.10: py310
3.11: py311
[gh-actions:env]
DB =
sqlite: sqlite
postgres: postgres
[testenv]
package = wheel
wheel_build_env = .pkg
pass_env =
FORCE_COLOR
NO_COLOR
setenv =
PYTHONPATH = {tox_root}
PYTHONDEVMODE = 1
change_dir = {tox_root}/tests
deps =
flit>=3.8
coverage[toml]>=7.0,<8.0
factory-boy==3.2.1
wagtail-factories>=4.1.0
django-cors-headers==3.4.0
wagtailmedia>=0.13
dj-database-url==2.1.0
psycopg2>=2.9.5,<3.0.0
django32: Django>=3.2,<3.3
django41: Django>=4.1,<4.2
django42: Django>=4.2,<5.0
wagtail41: wagtail>=4.1,<4.2
wagtail50: wagtail>=5.0,<5.1
wagtail51: wagtail>=5.1,<5.2
interactive: wagtail>=4.1
install_command = python -Im pip install -U {opts} {packages}
commands =
python -m coverage run manage.py test {posargs: -v1} --exclude-tag=needs-custom-settings
python manage.py test -v1 --tag=needs-custom-settings --settings=settings_custom_page_interface
[testenv:coverage-report]
; a bit of a hack - we keep deps to a minimum, and move coverage data to the tox root for easier excludes
deps =
install_command = python -Im pip install -U "coverage[toml]>=7.0,<8.0"
change_dir = {tox_root}
allowlist_externals = mv
pre_commands =
mv {tox_root}/tests/.coverage* {tox_root}/
commands =
python -Im coverage report -m
[testenv:wagtailmain]
description = Test with latest Wagtail main branch
[testenv:interactive]
package = editable
description = An interactive environment for local testing purposes
base_python = python3.11
deps =
wagtail>=4.1
commands_pre =
python manage.py makemigrations
python manage.py migrate
python manage.py shell -c "from django.contrib.auth.models import User;(not User.objects.filter(username='admin').exists()) and User.objects.create_superuser('admin', '[email protected]', 'changeme')"
python manage.py createcachetable
commands =
{posargs:python manage.py runserver 0.0.0.0:8020}
set_env =
INTERACTIVE = 1