-
Notifications
You must be signed in to change notification settings - Fork 174
/
tox.ini
70 lines (61 loc) · 1.84 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
[tox]
minversion = 2.0
envlist = py3,pep8
skipdist = True
[testenv]
basepython = python3
sitepackages = False
usedevelop = True
install_command = pip install -U {opts} {packages} -c{env:CONSTRAINTS_FILE:/dev/null}
setenv = VIRTUAL_ENV={envdir}
deps = -r{toxinidir}/test-requirements.txt
extras = server
[testenv:venv]
commands = {posargs}
[testenv:docs]
deps = -r{toxinidir}/doc/requirements.txt
commands =
sphinx-build -W -b html doc/source doc/build/html
setenv =
# programoutput might end up creating things, don't pollute outside of tov envtmpdir
ARA_BASE_DIR={env:ARA_BASE_DIR:{envtmpdir}}
[testenv:linters]
allowlist_externals = {toxinidir}/tests/linters.sh
commands = {toxinidir}/tests/linters.sh
[testenv:py3]
commands = ara-manage test -v 2 ara
setenv =
ARA_DEBUG=true
ARA_LOG_LEVEL=DEBUG
ARA_BASE_DIR={env:ARA_BASE_DIR:{envtmpdir}}
[testenv:runserver]
commands =
ara-manage migrate
ara-manage runserver
setenv =
ARA_DEBUG=true
ARA_LOG_LEVEL=DEBUG
ARA_BASE_DIR={env:ARA_BASE_DIR:{envtmpdir}}
[testenv:ansible-integration]
deps = ansible
commands =
ansible-playbook -i localhost, --connection=local \
{toxinidir}/tests/basic.yaml \
-e ara_api_root_dir={envtmpdir}/.ara {posargs}
[testenv:benchmark]
deps = ansible
commands =
ansible-playbook -i localhost, --connection=local \
{toxinidir}/tests/integration/benchmark.yaml {posargs}
setenv =
ANSIBLE_CALLBACK_PLUGINS={toxinidir}/ara/plugins/callback
ANSIBLE_ACTION_PLUGINS={toxinidir}/ara/plugins/action
ANSIBLE_LOOKUP_PLUGINS={toxinidir}/ara/plugins/lookup
ARA_API_CLIENT={env:ARA_API_CLIENT:offline}
ARA_API_SERVER={env:ARA_API_SERVER:"http://127.0.0.1:8000"}
[testenv:cover]
commands =
coverage erase
coverage run {toxinidir}/ara/server/__main__.py test ara/server
coverage run -a {toxinidir}/ara/server/__main__.py test ara/api
coverage html