Merge "Define python3 as basepython for Tempest tox env"
diff --git a/tox.ini b/tox.ini
index effd400..ff31fe8 100644
--- a/tox.ini
+++ b/tox.ini
@@ -1,9 +1,11 @@
 [tox]
 envlist = pep8,py36,py37,py27,bashate,pip-check-reqs
-minversion = 2.3.1
+minversion = 3.1.1
 skipsdist = True
+ignore_basepython_conflict = True
 
 [tempestenv]
+basepython = python3.6
 sitepackages = False
 setenv =
     VIRTUAL_ENV={envdir}
@@ -13,6 +15,7 @@
     -r{toxinidir}/requirements.txt
 
 [testenv]
+basepython = python3
 setenv =
     VIRTUAL_ENV={envdir}
     OS_LOG_CAPTURE=1
@@ -49,12 +52,12 @@
   coverage report
 
 [testenv:debug]
-basepython = python3
 commands = oslo_debug_helper -t tempest/tests {posargs}
 
 [testenv:all]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 # 'all' includes slow tests
 setenv =
     {[tempestenv]setenv}
@@ -77,6 +80,7 @@
 setenv =
     {[tempestenv]setenv}
     OS_TEST_TIMEOUT={env:OS_TEST_TIMEOUT:1200}
+basepython = {[tempestenv]basepython}
 deps = {[tempestenv]deps}
 commands =
     echo "WARNING: The all-plugin env is deprecated and will be removed"
@@ -90,6 +94,7 @@
 setenv =
     {[tempestenv]setenv}
     OS_TEST_TIMEOUT={env:OS_TEST_TIMEOUT:1200}
+basepython = {[tempestenv]basepython}
 deps = {[tempestenv]deps}
 commands =
     find . -type f -name "*.pyc" -delete
@@ -98,6 +103,7 @@
 [testenv:full]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select which tests to run and exclude the slow tag:
@@ -111,6 +117,7 @@
 [testenv:full-parallel]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select all tempest scenario and including the non slow api tests
@@ -121,6 +128,7 @@
 [testenv:integrated-network]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select which tests to run and exclude the slow tag and
@@ -133,6 +141,7 @@
 [testenv:integrated-compute]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select which tests to run and exclude the slow tag and
@@ -145,6 +154,7 @@
 [testenv:integrated-placement]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select which tests to run and exclude the slow tag and
@@ -157,6 +167,7 @@
 [testenv:integrated-storage]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select which tests to run and exclude the slow tag and
@@ -169,6 +180,7 @@
 [testenv:integrated-object-storage]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select which tests to run and exclude the slow tag and
@@ -181,6 +193,7 @@
 [testenv:full-serial]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select which tests to run and exclude the slow tag:
@@ -193,6 +206,7 @@
 [testenv:scenario]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select all scenario tests
@@ -203,6 +217,7 @@
 [testenv:smoke]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 commands =
@@ -212,6 +227,7 @@
 [testenv:smoke-serial]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # This is still serial because neutron doesn't work with parallel. See:
@@ -224,6 +240,7 @@
 [testenv:slow-serial]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # The regex below is used to select the slow tagged tests to run serially:
@@ -234,6 +251,7 @@
 [testenv:ipv6-only]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 # Run only smoke and ipv6 tests. This env is used to tests
@@ -253,12 +271,12 @@
 [testenv:venv-tempest]
 envdir = .tox/tempest
 sitepackages = {[tempestenv]sitepackages}
+basepython = {[tempestenv]basepython}
 setenv = {[tempestenv]setenv}
 deps = {[tempestenv]deps}
 commands = {posargs}
 
 [testenv:docs]
-basepython = python3
 deps =
   -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
   -r{toxinidir}/requirements.txt
@@ -269,7 +287,6 @@
 whitelist_externals = rm
 
 [testenv:pdf-docs]
-basepython = python3
 deps = {[testenv:docs]deps}
 whitelist_externals =
    make
@@ -281,7 +298,6 @@
 deps =
     -r{toxinidir}/test-requirements.txt
     autopep8
-basepython = python3
 commands =
     autopep8 --exit-code --max-line-length=79 --experimental --diff -r tempest setup.py
     flake8 {posargs}
@@ -289,7 +305,6 @@
 
 [testenv:autopep8]
 deps = autopep8
-basepython = python3
 commands =
     {toxinidir}/tools/format.sh
 
@@ -313,7 +328,6 @@
 import-order-style = pep8
 
 [testenv:releasenotes]
-basepython = python3
 deps =
   -c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
   -r{toxinidir}/requirements.txt
@@ -325,7 +339,6 @@
 whitelist_externals = rm
 
 [testenv:bashate]
-basepython = python3
 # if you want to test out some changes you have made to bashate
 # against tempest, just set BASHATE_INSTALL_PATH=/path/... to your
 # modified bashate tree
@@ -360,7 +373,6 @@
 
 [testenv:plugin-sanity-check]
 # perform tempest plugin sanity
-basepython = python3
 whitelist_externals = bash
 commands =
   bash tools/tempest-plugin-sanity.sh