Add pretty_tox.sh wrapper script to use subunit-trace

This commit adds a pretty_tox.sh wrapper script for the tempest-lib
unit tests to use subunit-trace when running the tests. This should
make the output a bit more clear and help with future debugging.

Change-Id: I48d670353bb85f7f87a05041bed60ad131555057
This commit is contained in:
Matthew Treinish
2014-10-18 01:26:11 -04:00
parent 5715fd6514
commit dd266f725d
2 changed files with 8 additions and 1 deletions

6
tools/pretty_tox.sh Executable file
View File

@@ -0,0 +1,6 @@
#!/usr/bin/env bash
set -o pipefail
TESTRARGS=$1
python setup.py testr --slowest --testr-args="--subunit $TESTRARGS" | subunit-trace --no-failure-debug -f

View File

@@ -6,11 +6,12 @@ skipsdist = True
[testenv]
usedevelop = True
install_command = pip install -U {opts} {packages}
whitelist_externals = bash
setenv =
VIRTUAL_ENV={envdir}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
commands = python setup.py testr --slowest --testr-args='{posargs}'
commands = bash tools/pretty_tox.sh {posargs}
[testenv:pep8]
commands = flake8