-
Notifications
You must be signed in to change notification settings - Fork 117
/
tox.ini
289 lines (222 loc) · 8.72 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
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
[tox]
envlist = py310,py39,py38,py36,pep8,docs
minversion = 4.11.0
ignore_basepython_conflict = True
[testenv]
basepython = python3
setenv = VIRTUAL_ENV={envdir}
OS_LOG_CAPTURE={env:OS_LOG_CAPTURE:true}
OS_STDOUT_CAPTURE={env:OS_STDOUT_CAPTURE:true}
OS_STDERR_CAPTURE={env:OS_STDERR_CAPTURE:true}
passenv =
TOX_CONSTRAINTS_FILE
OS_DEBUG
usedevelop = True
allowlist_externals = rm
deps =
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
commands =
stestr run --slowest --concurrency 1 {posargs}
[testenv:functional]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional run --slowest {posargs}
[testenv:dsvm-functional]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional run --slowest --concurrency 2 {posargs}
[testenv:dsvm-functional-sol-legacy-nfvo]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol/legacy_nfvo run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-vnflcm]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol/vnflcm run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-vnflcm-userdata]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol/vnflcm_userdata run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-vnfpkgm]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol/vnfpkgm run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-separated-nfvo]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_separated_nfvo run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-separated-nfvo-v2]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_separated_nfvo_v2 run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-kubernetes]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_kubernetes run --slowest --concurrency 2 {posargs}
[testenv:dsvm-functional-sol-v2-basic]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_v2/basic run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-v2-vnflcm]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_v2/vnflcm run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-v2-notification]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_v2/notification run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-v2-prometheus]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_v2/prometheus run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-v2-ubuntu-focal]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_v2 run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-v2-individual-vnfc-mgmt]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_v2_individual_vnfc_mgmt run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-kubernetes-v2]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_kubernetes_v2 run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol_kubernetes_oidc_auth]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_kubernetes_oidc_auth run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-multi-tenant]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_multi_tenant run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-kubernetes-multi-tenant]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_kubernetes_multi_tenant run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-v2-az-retry]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_v2_az_retry run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-enhanced-policy-sol]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_enhanced_policy/sol run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-enhanced-policy-sol-kubernetes]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_enhanced_policy/sol_kubernetes run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-https-v2]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_https_v2 run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-encrypt-cred-barbican]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_encrypt_cred_v2 run --slowest --concurrency 1 {posargs}
[testenv:dsvm-functional-sol-encrypt-cred-local]
setenv = {[testenv]setenv}
# Temporarily change directory permissions to read the contents of the fernet
# key file from the test code.
commands_pre =
sudo su stack -c 'chmod 755 /etc/tacker/crypt/fernet_keys'
commands =
stestr --test-path=./tacker/tests/functional/sol_encrypt_cred_v2 run --slowest --concurrency 1 {posargs}
commands_post =
sudo su stack -c 'chmod 700 /etc/tacker/crypt/fernet_keys'
allowlist_externals =
sudo
[testenv:dsvm-functional-sol-terraform-v2]
setenv = {[testenv]setenv}
commands =
stestr --test-path=./tacker/tests/functional/sol_terraform_v2 run --slowest --concurrency 1 {posargs}
[testenv:dsvm-compliance-sol-api]
passenv =
{[testenv]passenv}
*_PROXY
commands_pre =
git clone https://forge.etsi.org/rep/nfv/api-tests.git
git -C api-tests checkout 2.6.1-fix-plu
pip install -U -r{envdir}/api-tests/requirements.txt
commands =
stestr --test-path={toxinidir}/tacker/tests/compliance --top-dir={toxinidir} run --slowest --concurrency 1 {posargs}
commands_post =
rm -rf api-tests
allowlist_externals =
git
rm
changedir = {envdir}
[testenv:debug]
# NOTE(yasufum): Give optional test dir with `-t` explicitly because it cannot
# be found in oslo_debug_helper correctly for a deprecated warning from
# easy_install. It's needed until the warning is fixed.
commands = oslo_debug_helper -t tacker/tests {posargs}
[testenv:pep8]
deps = -r{toxinidir}/doc/requirements.txt
-r{toxinidir}/test-requirements.txt
commands =
flake8
doc8 -e .rst doc/source/ CONTRIBUTING.rst HACKING.rst README.rst TESTING.rst
tacker-db-manage check_migration
allowlist_externals = bash
[testenv:docs]
allowlist_externals =
sphinx-build
deps =
-r{toxinidir}/doc/requirements.txt
-c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
commands =
sphinx-build -W -b html doc/source doc/build/html
oslopolicy-sample-generator --config-file=etc/tacker-policy-generator.conf
[testenv:api-ref]
deps = {[testenv:docs]deps}
commands =
rm -rf api-ref/build
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
allowlist_externals = rm
[testenv:releasenotes]
deps = {[testenv:docs]deps}
commands =
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
[testenv:cover]
setenv =
PYTHON=coverage run --source tacker --parallel-mode
commands =
stestr run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
[testenv:venv]
commands = {posargs}
[flake8]
# E128 continuation line under-indented for visual indent
# N320 log messages does not translate
# W503 line break before binary operator
# W504 line break after binary operator
ignore = E128,N320,W503,W504
show-source = true
builtins = _
exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools,.ropeproject
[hacking]
import_exceptions = tacker._i18n
[flake8:local-plugins]
extension =
N320 = checks:validate_log_translations
T301 = checks:no_log_warn
paths = ./tacker/hacking
[testenv:config-gen]
commands =
oslo-config-generator --config-file=etc/config-generator.conf
[testenv:genpolicy]
commands =
oslopolicy-sample-generator --config-file=etc/tacker-policy-generator.conf
[testenv:bindep]
# Do not install any requirements. We want this to be fast and work even if
# system dependencies are missing, since it's used to tell you what system
# dependencies are missing! This also means that bindep must be installed
# separately, outside of the requirements files, and develop mode disabled
# explicitly to avoid unnecessarily installing the checked-out repo too (this
# further relies on "tox.skipsdist = True" above).
deps = bindep
commands = bindep test