ovsdbapp/tox.ini
wangzihao 26f24cf228 Drop py37 and add py38 test
Drop python3.7 and add python3.8 from setup.cfg and tox.ini, since Wallaby's python
supported runtimes are python 3.6 ~ python 3.8[1] ,python 3.7 still in use but not test [2]:

[1] https://governance.openstack.org/tc/reference/runtimes/wallaby.html
[2] http://lists.openstack.org/pipermail/openstack-discuss/2021-January/019648.html

Change-Id: Id68d7015f97b7c2bb903bb7015998347e19980ea
2021-01-14 02:20:08 +00:00

85 lines
2.2 KiB
INI

[tox]
minversion = 3.1.1
envlist = py38,py36,pep8
skipsdist = True
ignore_basepython_conflict = True
[testenv]
basepython = python3
usedevelop = True
setenv =
VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
OS_TEST_PATH=./ovsdbapp/tests/unit
install_command = pip install {opts} {packages}
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt
commands = stestr run --slowest {posargs}
[testenv:pep8]
commands = flake8
{toxinidir}/tools/coding-checks.sh --all '{posargs}'
[testenv:venv]
commands = {posargs}
[testenv:cover]
commands = python setup.py test --coverage --testr-args='{posargs}'
[testenv:docs]
deps =
-r{toxinidir}/doc/requirements.txt
commands =
sphinx-build -W -b html -d doc/build/doctrees doc/source doc/build/html
[testenv:pdf-docs]
envdir = {toxworkdir}/docs
deps = {[testenv:docs]deps}
whitelist_externals =
make
commands =
sphinx-build -W -b latex doc/source doc/build/pdf
make -C doc/build/pdf
[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:debug]
commands = oslo_debug_helper {posargs}
[testenv:functional]
setenv = {[testenv]setenv}
OS_TEST_PATH=./ovsdbapp/tests/functional
OVS_SRCDIR={envdir}/src/ovs
OVN_SRCDIR={envdir}/src/ovn
OVS_BRANCH={env:OVS_BRANCH:}
OVN_BRANCH={env:OVN_BRANCH:}
passenv = KEEP_VENV
commands =
{toxinidir}/tools/setup-ovs.sh
{[testenv]commands}
[flake8]
# W504 line break after binary operator
ignore = W504
# H106: Don't put vim configuration in source files
# H203: Use assertIs(Not)None to check for None
# H204: Use assert(Not)Equal to check for equality
# H205: Use assert(Greater|Less)(Equal) for comparison
# H904: Delay string interpolations at logging calls
enable-extensions=H106,H203,H204,H205,H904
show-source = True
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build
import-order-style = pep8
[testenv:lower-constraints]
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt