From f3480a7bda597ac13a3a3536da3c3add972a8fd8 Mon Sep 17 00:00:00 2001 From: "huang.zhiping" Date: Sat, 9 Jun 2018 11:02:29 +0800 Subject: [PATCH] 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: Ib660c909b6b7afeb8edc6b802d5e6897d72f7980 --- tox.ini | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 6533406..52fe139 100644 --- a/tox.ini +++ b/tox.ini @@ -1,7 +1,7 @@ [tox] minversion = 2.0 skipsdist = True -envlist = py27,pep8,cover +envlist = py27,py35,pep8,cover [testenv] usedevelop = True @@ -20,6 +20,7 @@ commands = nosetests -w test [testenv:cover] +basepython = python3 commands = nosetests -w test --cover-package monasca_analytics setenv = VIRTUAL_ENV={envdir} NOSE_WITH_COVERAGE=1 @@ -38,6 +39,7 @@ commands = [testenv:docs] [testenv:venv] +basepython = python3 install_command = pip install -U {opts} {packages} commands = {posargs}