diff options
author | melanie witt <melwittt@gmail.com> | 2017-09-27 20:02:36 +0000 |
---|---|---|
committer | melanie witt <melwittt@gmail.com> | 2017-10-05 21:45:46 +0000 |
commit | 53f244da1279dd9ffe6632193b580fc3cead9f37 (patch) | |
tree | a01a789f8b8c51dd5f15fe6e1ab5661298524f2d | |
parent | 3174ee13a1541230a4b7b2a4737d679691fb14b3 (diff) | |
download | nova-53f244da1279dd9ffe6632193b580fc3cead9f37.tar.gz |
Make setenv consistent for unit, func, and api-samples
Since ostestr switched to running stestr under the covers, we lost the
old magic setting of the environment variables via .testr.conf for
capturing stderr/stdout and the test timeout. This makes the unit,
functional, and api-samples envs consistent with the py27 env that was
already updated to set those variables.
This also updates the pretty_tox3.sh script to run stestr directly.
Change-Id: I27fa9b7e25c1a1dc921653eec84864423f898a85
-rwxr-xr-x | tools/pretty_tox3.sh | 4 | ||||
-rw-r--r-- | tox.ini | 26 |
2 files changed, 15 insertions, 15 deletions
diff --git a/tools/pretty_tox3.sh b/tools/pretty_tox3.sh index f73939531a..ffc0e58f36 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 @@ -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}' |