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: Iff786d273a1511b32fbdae4b5ad647c859df349f
This commit is contained in:
huang.zhiping 2018-08-15 06:35:26 +00:00
parent a18a2b6e8a
commit 172eb0b3da
1 changed files with 7 additions and 0 deletions

View File

@ -29,6 +29,7 @@ commands =
stestr run {posargs}
[testenv:cover]
basepython = python3
setenv =
PYTHON=coverage run --source monasca_persister --parallel-mode
commands =
@ -38,9 +39,11 @@ commands =
coverage xml -o cover/coverage.xml
[testenv:debug]
basepython = python3
commands = oslo_debug_helper -t monasca_persister/tests {posargs}
[testenv:pep8]
basepython = python3
deps =
{[testenv]deps}
commands =
@ -49,15 +52,18 @@ commands =
python setup.py check --restructuredtext --strict
[testenv:genconfig]
basepython = python3
description = Generates sample configuration file for monasca-persister
whitelist_externals = bash
commands =
oslo-config-generator --config-file=config-generator/persister.conf
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:bindep]
basepython = python3
# Do not install any requirements. We want this to be fast and work even if
# system dependencies are missing, since it's used to tell you what system
# dependencies are missing! This also means that bindep must be installed
@ -66,6 +72,7 @@ deps = bindep
commands = bindep test
[testenv:flake8]
basepython = python3
commands =
flake8 monasca_persister