fix tox python3 overrides

We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: I59ac21cb0d34f0b6767c736d0419eb6b874efca1
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
This commit is contained in:
Doug Hellmann 2018-06-06 16:06:01 -04:00
parent 7f990ffa16
commit a245fd5f8f
1 changed files with 9 additions and 0 deletions

View File

@ -16,6 +16,7 @@ commands =
stestr slowest
[testenv:releasenotes]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/requirements.txt
@ -27,6 +28,7 @@ commands =
whitelist_externals = rm
[testenv:debug]
basepython = python3
commands = oslo_debug_helper {posargs}
[testenv:debug-py27]
@ -60,17 +62,21 @@ commands =
{toxinidir}/tools/check_logging.sh {toxinidir}/manila
[testenv:genconfig]
basepython = python3
whitelist_externals = bash
commands =
oslo-config-generator --config-file etc/oslo-config-generator/manila.conf
[testenv:genpolicy]
basepython = python3
commands = oslopolicy-sample-generator --config-file=etc/manila/manila-policy-generator.conf
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:docs]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/requirements.txt
@ -83,6 +89,7 @@ commands =
whitelist_externals = rm
[testenv:cover]
basepython = python3
setenv =
{[testenv]setenv}
PYTHON=coverage run --source manila --parallel-mode
@ -109,6 +116,7 @@ deps = -r{toxinidir}/requirements.txt
commands = python tools/lintstack.py check
[testenv:api-ref]
basepython = python3
# This environment is called from CI scripts to test and publish
# the API Ref to developer.openstack.org.
whitelist_externals = rm
@ -117,6 +125,7 @@ commands =
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
[testenv:dbrevision]
basepython = python3
deps = -r{toxinidir}/requirements.txt
commands = alembic -c manila/db/migrations/alembic.ini revision -m ""{posargs}