From 7ed98230cbb9b598892e531082b36bf081e00a6f Mon Sep 17 00:00:00 2001 From: "huang.zhiping" Date: Sat, 9 Jun 2018 09:52:10 +0800 Subject: [PATCH] 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: I634e5ed6236ff0253b713b411ab203072485af2c --- tox.ini | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tox.ini b/tox.ini index 948f83782..862bd8510 100644 --- a/tox.ini +++ b/tox.ini @@ -33,12 +33,15 @@ basepython = python3.5 commands = oslo_debug_helper {posargs} [testenv:pep8] +basepython = python3 commands = flake8 [testenv:venv] +basepython = python3 commands = {posargs} [testenv:cover] +basepython = python3 commands = rm -f .testrepository/times.dbm python setup.py test --coverage --testr-args='{posargs}' \ @@ -46,6 +49,7 @@ commands = coverage report [testenv:docs] +basepython = python3 deps = -r{toxinidir}/doc/requirements.txt commands = sphinx-build -W -b html doc/source doc/build/html @@ -57,6 +61,7 @@ enable-extensions = H106,H203 exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools,.ropeproject,rally-scenarios,neutron/tests/unit/vmware*,releasenotes [testenv:pylint] +basepython = python3 deps = {[testenv]deps} pylint @@ -68,9 +73,11 @@ import_exceptions = neutron.i18n local-check-factory = neutron_lib.hacking.checks.factory [testenv:genconfig] +basepython = python3 commands = oslo-config-generator --config-file=etc/oslo-config-generator/kuryr.conf [testenv:releasenotes] +basepython = python3 deps = -r{toxinidir}/doc/requirements.txt commands = sphinx-build -a -W -E -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html