forked from openstack/designate-tempest-plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tox.ini
107 lines (98 loc) · 3.89 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
96
97
98
99
100
101
102
103
104
105
106
107
[tox]
minversion = 3.18.0
envlist = pep8
skipsdist = True
ignore_basepython_conflict = True
[testenv]
basepython = python3
usedevelop = True
install_command = pip install {opts} {packages}
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
setenv =
VIRTUAL_ENV={envdir}
PYTHONDONTWRITEBYTECODE=1
allowlist_externals = sh
find
rm
commands =
find . -type f -name "*.pyc" -delete
stestr run {posargs}
passenv = http_proxy
HTTP_PROXY
https_proxy
HTTPS_PROXY
no_proxy
NO_PROXY
OS_DEBUG
OS_LOG_CAPTURE
OS_STDERR_CAPTURE
OS_STDOUT_CAPTURE
[testenv:pep8]
commands = sh tools/pretty_flake8.sh
[testenv:docs]
deps = -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands = rm -rf doc/build
sphinx-build -E -W -b html doc/source doc/build/html
[testenv:releasenotes]
deps = {[testenv:docs]deps}
allowlist_externals = rm
commands =
rm -rf releasenotes/build
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
[testenv:bashate]
deps = bashate
allowlist_externals = bash
commands = bash -c "find {toxinidir}/devstack \
-not \( -type d -name .?\* -prune \) \
-not \( -type d -name doc -prune \) \
-type f \
-not -name \*~ \
-not -name \*.md \
\( \
-name \*.sh -or \
-name \*rc -or \
-name functions\* -or \
-wholename \*/lib/\* \
\) \
-print0 | xargs -0 bashate -v"
[testenv:pip-check-reqs]
# do not install test-requirements as that will pollute the virtualenv for
# determining missing packages
# this also means that pip-missing-reqs must be installed separately, outside
# of the requirements.txt files
deps = pip-check-reqs
-r{toxinidir}/requirements.txt
commands=pip-missing-reqs -d --ignore-file=designate/tests/* designate
[testenv:venv]
commands = {posargs}
[flake8]
# ignored flake8 codes:
# H302 import only modules
# H306 imports not in alphabetical order
# H402 one line docstring needs punctuation
# H404 multi line docstring should start with a summary
# H405 multi line docstring summary not separated with an empty line
# H904 Wrap long lines in parentheses instead of a backslash
# E126 continuation line over-indented for hanging indent
# E128 continuation line under-indented for visual indent
# W504 line break after binary operator
ignore = H302,H306,H402,H404,H405,H904,E126,E128,W504
exclude = .venv,.git,.tox,dist,doc,*openstack/common*,*openstack/deprecated*,*lib/python*,*egg,build,tools,.ropeproject
[flake8:local-plugins]
extension =
T102 = tempest.hacking.checks:import_no_clients_in_api_and_scenario_tests
T104 = tempest.hacking.checks:scenario_tests_need_service_tags
T105 = tempest.hacking.checks:no_setup_teardown_class_for_tests
T107 = tempest.hacking.checks:service_tags_not_in_module_path
T108 = tempest.hacking.checks:no_hyphen_at_end_of_rand_name
N322 = tempest.hacking.checks:no_mutable_default_args
T109 = tempest.hacking.checks:no_testtools_skip_decorator
T110 = tempest.hacking.checks:get_resources_on_service_clients
T111 = tempest.hacking.checks:delete_resources_on_service_clients
T112 = tempest.hacking.checks:dont_import_local_tempest_into_lib
T113 = tempest.hacking.checks:dont_use_config_in_tempest_lib
T114 = tempest.hacking.checks:use_rand_uuid_instead_of_uuid4