-
Notifications
You must be signed in to change notification settings - Fork 33
/
tox.ini
96 lines (82 loc) · 2.62 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
93
94
95
[tox]
minversion = 3.18.0
envlist = py3,pep8
ignore_basepython_conflict = True
[testenv]
basepython = python3
usedevelop = True
allowlist_externals = find
setenv =
VIRTUAL_ENV={envdir}
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt
commands =
stestr run --serial {posargs}
stestr slowest
oslo-config-generator --config-file=etc/vitrage/vitrage-config-generator.conf
find . -type f -name "test-*.db" -delete
passenv =
http_proxy
HTTP_PROXY
https_proxy
HTTPS_PROXY
no_proxy
NO_PROXY
[testenv:pep8]
commands = flake8
[testenv:genconfig]
commands = oslo-config-generator --config-file=etc/vitrage/vitrage-config-generator.conf
[testenv:genpolicy]
commands = oslopolicy-sample-generator --config-file=etc/vitrage/vitrage-policy-generator.conf
[testenv:venv]
commands = {posargs}
[testenv:cover]
setenv =
PYTHON=coverage run --source $project --parallel-mode
commands =
stestr run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
coverage report
[testenv:docs]
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands = sphinx-build -W -b html doc/source doc/build/html
[testenv:debug]
commands = oslo_debug_helper {posargs}
[flake8]
# E123, E125 skipped as they are invalid PEP-8.
# H106: Don't put vim configuration in source files
# H203: Use assertIs(Not)None to check for None
show-source = True
ignore = E123,E125,E402,W503,W504,E731
enable-extensions=H104,H106,H203
builtins = _
filename = *.py,app.wsgi
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools/datasource-scaffold
[hacking]
import_exceptions = vitrage.i18n
[flake8:local-plugins]
extension =
V316 = checks:assert_true_instance
V329 = checks:check_assert_true_false
V317 = checks:assert_equal_type
V319 = checks:no_translate_logs
V327 = checks:no_mutable_default_args
V321 = checks:check_no_contextlib_nested
V322 = checks:dict_constructor_with_list_copy
V323 = checks:check_python3_xrange
V324 = checks:check_python3_no_iteritems
V325 = checks:check_python3_no_iterkeys
V326 = checks:check_python3_no_itervalues
V328 = checks:no_log_warn
paths = ./vitrage/hacking
[testenv:releasenotes]
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html