Switch tox unit test command to use ostestr

This commit switches the tox command to use ostestr instead of calling
testr through setup.py. The primary advantage here is that it uses the
subunit-trace output filter. ostestr primarily exists as a replacement for
pretty_tox.sh bash scripts which spread like a plague through OpenStack
projects after Nova copied it from Tempest.

Note that this dramatically increases output while running tests.
However, test failures are still at the bottom of the output, so it
shouldn't cause much pain, if any.

Change-Id: Id1ad26bc9670efa94c3c91142a177c75a12ce7d6
This commit is contained in:
Lucas Alvares Gomes 2017-01-03 11:25:56 +00:00 committed by Steve Martinelli
parent abaf1b5bf7
commit 53adca6deb
2 changed files with 3 additions and 1 deletions

View File

@ -19,6 +19,7 @@ stevedore>=1.17.1 # Apache-2.0
testrepository>=0.0.18 # Apache-2.0/BSD
testresources>=0.2.4 # Apache-2.0/BSD
testtools>=1.4.0 # MIT
os-testr>=0.8.0 # Apache-2.0
python-memcached>=1.56 # PSF
WebTest>=2.0 # MIT

View File

@ -11,11 +11,12 @@ setenv = VIRTUAL_ENV={envdir}
CLIENT_NAME=keystonemiddleware
OS_STDOUT_NOCAPTURE=False
OS_STDERR_NOCAPTURE=False
TESTS_DIR=./keystonemiddleware/tests/unit/
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
.[audit_notifications]
commands = python setup.py testr --testr-args='{posargs}'
commands = ostestr {posargs}
[testenv:pep8]
commands =