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: Ic9645685e0f9ae25b0b2b754b11e34d8aef41829 Signed-off-by: Doug Hellmann <doug@doughellmann.com>
This commit is contained in:
parent
dd54b4881a
commit
f3496591ae
11
tox.ini
11
tox.ini
@ -5,7 +5,6 @@ skipsdist = True
|
||||
|
||||
[testenv]
|
||||
# Set default python version
|
||||
basepython = python2.7
|
||||
setenv =
|
||||
VIRTUAL_ENV={envdir}
|
||||
PYTHONWARNINGS=default::DeprecationWarning
|
||||
@ -64,6 +63,7 @@ commands =
|
||||
stestr run --whitelist-file ./broken-functional-py35-ssl-tests.txt {posargs}
|
||||
|
||||
[testenv:pep8]
|
||||
basepython = python3
|
||||
commands =
|
||||
flake8 {posargs}
|
||||
# Run security linter
|
||||
@ -73,6 +73,7 @@ commands =
|
||||
doc8 {posargs}
|
||||
|
||||
[testenv:genconfig]
|
||||
basepython = python3
|
||||
commands =
|
||||
oslo-config-generator --config-file etc/oslo-config-generator/glance-api.conf
|
||||
oslo-config-generator --config-file etc/oslo-config-generator/glance-registry.conf
|
||||
@ -82,6 +83,7 @@ commands =
|
||||
oslo-config-generator --config-file etc/oslo-config-generator/glance-image-import.conf
|
||||
|
||||
[testenv:api-ref]
|
||||
basepython = python3
|
||||
# This environment is called from CI scripts to test and publish
|
||||
# the API Ref to developer.openstack.org.
|
||||
deps =
|
||||
@ -92,6 +94,7 @@ commands =
|
||||
sphinx-build -W -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
|
||||
|
||||
[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
|
||||
@ -119,6 +122,7 @@ local-check-factory = glance.hacking.checks.factory
|
||||
import_exceptions = glance.i18n
|
||||
|
||||
[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
|
||||
@ -128,12 +132,15 @@ commands =
|
||||
whereto doc/source/_extra/.htaccess doc/test/redirect-tests.txt
|
||||
|
||||
[testenv:venv]
|
||||
basepython = python3
|
||||
commands = {posargs}
|
||||
|
||||
[testenv:bandit]
|
||||
basepython = python3
|
||||
commands = bandit -c bandit.yaml -r glance -n5 -p gate
|
||||
|
||||
[testenv:releasenotes]
|
||||
basepython = python3
|
||||
deps =
|
||||
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
|
||||
-r{toxinidir}/doc/requirements.txt
|
||||
@ -141,6 +148,7 @@ commands =
|
||||
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
||||
|
||||
[testenv:cover]
|
||||
basepython = python3
|
||||
setenv =
|
||||
PYTHON=coverage run --source glance --parallel-mode
|
||||
commands =
|
||||
@ -150,6 +158,7 @@ commands =
|
||||
coverage xml -o cover/coverage.xml
|
||||
|
||||
[testenv:debug]
|
||||
basepython = python3
|
||||
commands =
|
||||
oslo_debug_helper {posargs}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user