tox: Trivial cleanup

Move 'basepython' to the top-level 'testenv'.

Change-Id: I13e72ec6cbd006ca6eccfe21f2a0584e86a52669
This commit is contained in:
Hervé Beraud 2019-12-20 10:42:49 +01:00
parent 41a4423043
commit cc6cf12c3d
1 changed files with 3 additions and 15 deletions

18
tox.ini
View File

@ -1,8 +1,10 @@
[tox]
minversion = 2.0
minversion = 3.1
envlist = py27,py37,pep8
ignore_basepython_conflict = True
[testenv]
basepython = python3
setenv =
VIRTUAL_ENV={envdir}
passenv = OS_*
@ -16,14 +18,12 @@ deps =
commands = stestr run --slowest {posargs}
[testenv:pep8]
basepython = python3
commands =
flake8
# run security linter
bandit -r oslo_messaging -x tests -n5
[testenv:cover]
basepython = python3
setenv =
PYTHON=coverage run --source oslo_messaging --parallel-mode
commands =
@ -33,11 +33,9 @@ commands =
coverage report
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:docs]
basepython = python3
whitelist_externals = rm
deps = -r{toxinidir}/doc/requirements.txt
commands =
@ -45,21 +43,18 @@ commands =
sphinx-build -W --keep-going -b html doc/source doc/build/html
[testenv:py27-func-rabbit]
basepython = python2.7
setenv =
{[testenv]setenv}
TRANSPORT_DRIVER=rabbit
commands = pifpaf run rabbitmq -- stestr run --slowest {posargs:oslo_messaging.tests.functional}
[testenv:py36-func-rabbit]
basepython = python3.6
setenv =
{[testenv]setenv}
TRANSPORT_DRIVER=rabbit
commands = pifpaf run rabbitmq -- stestr run --slowest {posargs:oslo_messaging.tests.functional}
[testenv:py27-func-kafka]
basepython = python2.7
setenv =
{[testenv]setenv}
TRANSPORT_URL=kafka://127.0.0.1:9092/
@ -67,7 +62,6 @@ setenv =
commands = {toxinidir}/setup-test-env-kafka.sh stestr run --slowest {posargs:oslo_messaging.tests.functional}
[testenv:py27-func-amqp1]
basepython = python2.7
setenv =
{[testenv]setenv}
TRANSPORT_URL=amqp://stackqpid:secretqpid@127.0.0.1:5672//
@ -76,7 +70,6 @@ setenv =
commands = {toxinidir}/tools/setup-test-env-amqp1.sh stestr run --slowest {posargs:oslo_messaging.tests.functional}
[testenv:py36-func-amqp1]
basepython = python3.6
setenv =
{[testenv]setenv}
TRANSPORT_URL=amqp://stackqpid:secretqpid@127.0.0.1:5672//
@ -85,7 +78,6 @@ setenv =
commands = {toxinidir}/tools/setup-test-env-amqp1.sh stestr run --slowest {posargs:oslo_messaging.tests.functional}
[testenv:py36-func-kafka]
basepython = python3.6
setenv =
{[testenv]setenv}
TRANSPORT_URL=kafka://127.0.0.1:9092/
@ -96,7 +88,6 @@ commands = {toxinidir}/setup-test-env-kafka.sh stestr run --slowest {posargs:osl
[testenv:bandit]
# NOTE(kgiusti): This is required for the integration test job of the bandit
# project. Please do not remove.
basepython = python3
commands = bandit -r oslo_messaging -x tests -n5
[flake8]
@ -113,7 +104,6 @@ import_exceptions =
local-check-factory = oslo_messaging.hacking.checks.factory
[testenv:releasenotes]
basepython = python3
whitelist_externals = rm
commands =
rm -rf releasenotes/build
@ -121,12 +111,10 @@ commands =
deps = -r{toxinidir}/doc/requirements.txt
[testenv:bindep]
basepython = python3
deps = bindep
commands = bindep {posargs}
[testenv:lower-constraints]
basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt