summaryrefslogtreecommitdiff
path: root/tox.ini
diff options
context:
space:
mode:
authorDoug Hellmann <doug@doughellmann.com>2018-06-06 14:50:06 -0400
committerDoug Hellmann <doug@doughellmann.com>2018-06-06 14:53:48 -0400
commit69b23ef7dec71da1189d26ecbc850fd3b0f454c5 (patch)
treea9d66ecbf2fc40af8d6ca2b3d1814d2939ef5e58 /tox.ini
parent06b64aea945d7025d77ec3f97a381d1bf0e606ca (diff)
downloadoslo-db-69b23ef7dec71da1189d26ecbc850fd3b0f454c5.tar.gz
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: I31a207868c07e08ae27c14635d52506021032cb7 Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Diffstat (limited to 'tox.ini')
-rw-r--r--tox.ini8
1 files changed, 7 insertions, 1 deletions
diff --git a/tox.ini b/tox.ini
index 7983cb4..f1db2f1 100644
--- a/tox.ini
+++ b/tox.ini
@@ -3,7 +3,6 @@ minversion = 2.0
envlist = py35,py27,pep8
[testenv]
-basepython = python3
install_command = pip install {opts} {packages}
whitelist_externals = bash
env
@@ -26,6 +25,7 @@ commands =
passenv = OS_TEST_DBAPI_ADMIN_CONNECTION
[testenv:sqla_09]
+basepython = python3
commands = pip install SQLAlchemy>=0.9.0,!=0.9.5,<1.0.0
python setup.py testr --slowest --testr-args='{posargs}'
@@ -36,24 +36,29 @@ commands =
env TEST_EVENTLET=1 bash tools/pretty_tox.sh '{posargs}'
[testenv:pep8]
+basepython = python3
commands =
flake8
# Run security linter
bandit -r oslo_db -x tests -n5 --skip B105,B311
[testenv:venv]
+basepython = python3
commands = {posargs}
[testenv:cover]
+basepython = python3
commands = python setup.py test --coverage --coverage-package-name=oslo_db --testr-args='{posargs}'
[testenv:docs]
+basepython = python3
deps = -r{toxinidir}/doc/requirements.txt
commands =
doc8 -e .rst CONTRIBUTING.rst HACKING.rst README.rst doc/source
sphinx-build -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
@@ -68,6 +73,7 @@ import_exceptions =
oslo_db._i18n
[testenv:lower-constraints]
+basepython = python3
deps =
-c{toxinidir}/lower-constraints.txt
-r{toxinidir}/test-requirements.txt