From 653c0b4cfc6325382a3fb93a2185ab74f9cee62a Mon Sep 17 00:00:00 2001 From: Joshua Powers Date: Fri, 1 Sep 2017 16:35:01 -0600 Subject: tox: add nose timer output This adds the output of the nose timer plugin to the py3 environment to tox. This will print out the 10 longest running tests and automatically turn tests longer than 1 second "red" after the coverage output. --- tox.ini | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'tox.ini') diff --git a/tox.ini b/tox.ini index ec96e859..72de9830 100644 --- a/tox.ini +++ b/tox.ini @@ -30,10 +30,13 @@ commands = {envpython} -m pylint {posargs:cloudinit} [testenv:py3] basepython = python3 -deps = -r{toxinidir}/test-requirements.txt -commands = {envpython} -m nose {posargs:--with-coverage \ - --cover-erase --cover-branches --cover-inclusive \ - --cover-package=cloudinit tests/unittests cloudinit} +deps = + nose-timer + -r{toxinidir}/test-requirements.txt +commands = {envpython} -m nose --with-timer --timer-top-n 10 \ + {posargs:--with-coverage --cover-erase --cover-branches \ + --cover-inclusive --cover-package=cloudinit \ + tests/unittests cloudinit} [testenv:py27] basepython = python2.7 -- cgit v1.2.3