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.

Co-Authored-By: Nguyen Hai <nguyentrihai93@gmail.com>
Change-Id: I889acfe16c7175d14b8a15e55eb936a03e41e2fb
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
This commit is contained in:
Doug Hellmann 2018-06-06 17:58:16 -04:00 committed by Nguyen Hai
parent d070f6a68c
commit f8d87cdb28
1 changed files with 5 additions and 0 deletions

View File

@ -13,6 +13,7 @@ deps = -r{toxinidir}/requirements.txt
commands = stestr run {posargs}
[testenv:debug]
basepython = python3
commands = oslo_debug_helper {posargs}
[testenv:functional]
@ -20,12 +21,15 @@ passenv = OS_CLOUD OS_PROJECT_DOMAIN_ID OS_USER_DOMAIN_ID OS_PROJECT_DOMAIN_NAME
commands = stestr run --concurrency=1 --test-path ./cloudkittyclient/tests/functional
[testenv:pep8]
basepython = python3
commands = flake8
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:docs]
basepython = python3
commands = python setup.py build_sphinx
[flake8]
@ -40,4 +44,5 @@ exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build,releasenotes
import_exceptions = cloudkittyclient.i18n
[testenv:releasenotes]
basepython = python3
commands = sphinx-build -a -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html