diff --git a/tools/pretty_tox3.sh b/tools/pretty_tox3.sh index f73939531aa3..ffc0e58f3674 100755 --- a/tools/pretty_tox3.sh +++ b/tools/pretty_tox3.sh @@ -9,7 +9,7 @@ else fi if [ -z "$TESTRARGS" ]; then - ostestr --blacklist_file $blacklist_file + stestr run --blacklist-file $blacklist_file else - ostestr -r "$TESTRARGS" + stestr run "$TESTRARGS" fi diff --git a/tox.ini b/tox.ini index 878205b40f6a..19c5f8b286a1 100644 --- a/tox.ini +++ b/tox.ini @@ -12,7 +12,6 @@ whitelist_externals = bash env install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} {opts} {packages} setenv = VIRTUAL_ENV={envdir} - OS_TEST_PATH=./nova/tests/unit LANGUAGE=en_US LC_ALL=en_US.utf-8 OS_STDOUT_CAPTURE=1 @@ -27,6 +26,8 @@ passenv = OS_DEBUG GENERATE_HASHES # mode. To do this define the TRACE_FAILONLY environmental variable. [testenv:py27] +setenv = {[testenv]setenv} + OS_TEST_PATH=./nova/tests/unit commands = {[testenv]commands} stestr run '{posargs}' @@ -34,6 +35,8 @@ commands = stestr slowest [testenv:py35] +setenv = {[testenv]setenv} + OS_TEST_PATH=./nova/tests/unit commands = {[testenv]commands} bash tools/pretty_tox3.sh '{posargs}' @@ -64,11 +67,10 @@ commands = # python 3.x basepython = python2.7 usedevelop = True -setenv = VIRTUAL_ENV={envdir} - OS_TEST_PATH=./nova/tests/functional - LANGUAGE=en_US +setenv = {[testenv]setenv} + OS_TEST_PATH=./nova/tests/functional commands = - find . -type f -name "*.pyc" -delete + {[testenv]commands} stestr run '{posargs}' stestr slowest @@ -77,20 +79,18 @@ commands = [testenv:functional-py35] basepython = python3.5 usedevelop = True -setenv = VIRTUAL_ENV={envdir} - OS_TEST_PATH=./nova/tests/functional - LANGUAGE=en_US +setenv = {[testenv]setenv} + OS_TEST_PATH=./nova/tests/functional commands = {[testenv]commands} bash tools/pretty_tox3.sh '{posargs}' [testenv:api-samples] usedevelop = True -setenv = VIRTUAL_ENV={envdir} - GENERATE_SAMPLES=True - PYTHONHASHSEED=0 - OS_TEST_PATH=./nova/tests/functional/api_sample_tests - LANGUAGE=en_US +setenv = {[testenv]setenv} + GENERATE_SAMPLES=True + PYTHONHASHSEED=0 + OS_TEST_PATH=./nova/tests/functional/api_sample_tests commands = find . -type f -name "*.pyc" -delete stestr run '{posargs}'