tox: Trivial cleanup

move 'basepython' to the top-level 'testenv'

Change-Id: I6d7b469b45bb4c5e7f5e0d793cc76941d76167df
This commit is contained in:
caoyuan 2019-12-23 00:10:29 +08:00
parent 2f2b2aa3c8
commit e5a7674a89
1 changed files with 1 additions and 11 deletions

12
tox.ini
View File

@ -4,6 +4,7 @@ envlist = py37,pep8,docs,releasenotes
skipsdist = True
[testenv]
basepython = python3
setenv = VIRTUAL_ENV={envdir}
usedevelop = True
install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt} -U {opts} {packages}
@ -15,12 +16,10 @@ commands =
whitelist_externals = find
[testenv:pep8]
basepython = python3
commands =
flake8 {posargs}
[testenv:cover]
basepython = python3
setenv =
VIRTUAL_ENV={envdir}
{[testenv]setenv}
@ -33,21 +32,17 @@ commands =
coverage report
[testenv:venv]
basepython = python3
commands = {posargs}
[testenv:genconfig]
basepython = python3
commands =
oslo-config-generator --config-file etc/oslo-config-generator/searchlight.conf
[testenv:genpolicy]
basepython = python3
commands =
oslopolicy-sample-generator --config-file etc/oslo-policy-generator/searchlight.conf
[testenv:docs]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
whitelist_externals = rm
commands =
@ -55,7 +50,6 @@ commands =
sphinx-build -W --keep-going -b html -d doc/build/doctrees doc/source doc/build/html
[testenv:pdf-docs]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
envdir = {toxworkdir}/docs
whitelist_externals =
@ -65,7 +59,6 @@ commands =
make -C doc/build/pdf
[testenv:api-ref]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
whitelist_externals = rm
commands =
@ -73,7 +66,6 @@ commands =
sphinx-build -W --keep-going -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
[testenv:releasenotes]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
commands = sphinx-build -a -E -W -d releasenotes/build/doctrees --keep-going -b html releasenotes/source releasenotes/build/html
@ -81,7 +73,6 @@ commands = sphinx-build -a -E -W -d releasenotes/build/doctrees --keep-going -b
commands = oslo_debug_helper {posargs}
[testenv:debug-py36]
basepython = python3.6
commands = oslo_debug_helper {posargs}
[flake8]
@ -100,7 +91,6 @@ local-check-factory = searchlight.hacking.checks.factory
import_exceptions = searchlight.i18n
[testenv:lower-constraints]
basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt