Use tox 3.1.1 and basepython fix

tox 3.1.1 fixed https://github.com/tox-dev/tox/issues/477 which
mishandled the basepython directive. Require this version and remove the
workarounds.

http://lists.openstack.org/pipermail/openstack-dev/2018-July/132085.html

Change-Id: Iccc0284c725dc5dea18d1e30cc35bd185119535d
This commit is contained in:
Eric Fried 2018-07-12 16:36:27 -05:00
parent bb7162b26d
commit fa64a93c96
1 changed files with 6 additions and 11 deletions

17
tox.ini
View File

@ -1,9 +1,14 @@
[tox]
minversion = 1.6
minversion = 3.1.1
envlist = py35,py27,pep8
skipsdist = True
# Automatic envs (pyXX) will use the python version appropriate to that
# env and ignore basepython inherited from [testenv]. That's what we
# want, and we don't need to be warned about it.
ignore_basepython_conflict = True
[testenv]
basepython = python3
usedevelop = True
install_command = pip install {opts} {packages}
setenv =
@ -24,31 +29,24 @@ commands =
find . -type f -name "*.pyc" -delete
[testenv:py27]
# TODO(efried): Remove this once https://github.com/tox-dev/tox/issues/425 is fixed.
basepython = python2.7
commands =
{[testenv]commands}
stestr run {posargs}
stestr slowest
[testenv:py35]
# TODO(efried): Remove this once https://github.com/tox-dev/tox/issues/425 is fixed.
basepython = python3.5
commands =
{[testenv]commands}
stestr run {posargs}
stestr slowest
[testenv:pep8]
basepython = python3
commands = flake8
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:cover]
basepython = python3
# TODO(stephenfin): Remove the PYTHON hack below in favour of a [coverage]
# section once we rely on coverage 4.3+
#
@ -66,14 +64,12 @@ commands =
coverage report
[testenv:docs]
basepython = python3
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/doc/requirements.txt
commands = sphinx-build -W -b html doc/source doc/build/html
[testenv:bashate]
basepython = python3
commands =
bash -c "ls devstack/*.sh | xargs bashate -v {posargs}"
whitelist_externals = bash
@ -87,7 +83,6 @@ exclude = .venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build,t
local-check-factory = nova_powervm.hacking.checks.factory
[testenv:lower-constraints]
basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt