5f35b695bf
This patch provides a base to support multi version API. The existing code of functions for SOL specification was hard to understand and enhance since it is based on the code of legacy tacker API and they are connected with each other complicatedly. Therefore the code for SOL specification is newly created which is independent to the legacy tacker API so that it will be easy to maintain and enhance. This patch supports vnflcm v2 API (api_version 2.0.0) as a starting point. It supports less functions than the exsisting v1 API at the moment(Xena) but it will catch up with by the next release (Y). This patch makes supporting another API version easy when it will be supported in the future. Possibly it may thought to add v1 API to this code base. TODO: enhance UT/FT UT/FT is not sufficient at the moment. Additional UTs and FTs will be provided with another patches. Implements: blueprint multi-version-api Implements: blueprint support-nfv-solv3-start-and-terminate-vnf Implements: blueprint support-nfv-solv3-query-vnf-instances Implements: blueprint support-nfv-solv3-query-operation-occurrences Implements: blueprint support-nfv-solv3-subscriptions Change-Id: If76f315d8b3856e0eef9b8808b90f0b15d80d488
158 lines
4.4 KiB
INI
158 lines
4.4 KiB
INI
[tox]
|
|
envlist = py39,py38,py36,pep8,docs
|
|
minversion = 3.18.0
|
|
skipsdist = True
|
|
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
|
|
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-legacy]
|
|
setenv = {[testenv]setenv}
|
|
|
|
commands =
|
|
stestr --test-path=./tacker/tests/functional/legacy run --slowest --concurrency 1 {posargs}
|
|
|
|
[testenv:dsvm-functional-sol]
|
|
setenv = {[testenv]setenv}
|
|
|
|
commands =
|
|
stestr --test-path=./tacker/tests/functional/sol 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-kubernetes]
|
|
setenv = {[testenv]setenv}
|
|
|
|
commands =
|
|
stestr --test-path=./tacker/tests/functional/sol_kubernetes run --slowest --concurrency 2 {posargs}
|
|
|
|
[testenv:dsvm-functional-sol-v2]
|
|
setenv = {[testenv]setenv}
|
|
|
|
commands =
|
|
stestr --test-path=./tacker/tests/functional/sol_v2 run --slowest --concurrency 1 {posargs}
|
|
|
|
[testenv:debug]
|
|
commands = oslo_debug_helper {posargs}
|
|
|
|
[testenv:debug-py36]
|
|
basepython = python3.6
|
|
commands = oslo_debug_helper {posargs}
|
|
|
|
[testenv:debug-py39]
|
|
basepython = python3.9
|
|
commands = oslo_debug_helper {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:i18n]
|
|
commands = python ./tools/check_i18n.py ./tacker
|
|
|
|
[testenv:docs]
|
|
deps = -r{toxinidir}/doc/requirements.txt
|
|
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 = -r{toxinidir}/doc/requirements.txt
|
|
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 = -r{toxinidir}/doc/requirements.txt
|
|
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
|
|
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:lower-constraints]
|
|
deps =
|
|
-c{toxinidir}/lower-constraints.txt
|
|
-r{toxinidir}/test-requirements.txt
|
|
-r{toxinidir}/requirements.txt
|
|
|
|
[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
|