Browse Source

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: Ifc418b2911ec09d1f7968ffb3d3e4093f6d07d6c
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
changes/77/572977/2
Doug Hellmann 3 years ago
parent
commit
670a7beba2
1 changed files with 7 additions and 0 deletions
  1. +7
    -0
      tox.ini

+ 7
- 0
tox.ini View File

@ -18,19 +18,23 @@ whitelist_externals =
find
[testenv:pep8]
basepython = python3
commands = flake8 {posargs}
[testenv:genconfig]
basepython = python3
commands =
oslo-config-generator --config-file tools/config/config-generator.qinling.conf \
--output-file etc/qinling.conf.sample
#set PYTHONHASHSEED=0 to prevent oslo_policy.sphinxext from randomly failing.
[testenv:venv]
basepython = python3
setenv = PYTHONHASHSEED=0
commands = {posargs}
[testenv:cover]
basepython = python3
setenv =
{[testenv]setenv}
PYTHON=coverage run --source qinling --parallel-mode
@ -38,6 +42,7 @@ commands =
{toxinidir}/tools/cover.sh {posargs}
[testenv:docs]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
whitelist_externals = rm
commands =
@ -45,11 +50,13 @@ commands =
sphinx-build -W -b html doc/source doc/build/html
[testenv:releasenotes]
basepython = python3
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]
basepython = python3
commands = oslo_debug_helper {posargs}
[flake8]


Loading…
Cancel
Save