From c8ba7a5a0f93a3e6be3ee1d824394fc5d89b3d47 Mon Sep 17 00:00:00 2001 From: Sorin Sbarnea Date: Wed, 4 Apr 2018 21:57:33 +0100 Subject: Replace testr with stestr Switch to use stestr which is maintained as opposed to testrepository (testr) which became a defunct project. Change-Id: I47f628a7d224189362f2b2cfd9fe4c54af198cde --- tox.ini | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'tox.ini') diff --git a/tox.ini b/tox.ini index e6fc39fe..2e641e9d 100644 --- a/tox.ini +++ b/tox.ini @@ -20,7 +20,7 @@ deps = -r{toxinidir}/test-requirements.txt commands = - find . -type f -name "*.pyc" -delete - find . -type d -name "__pycache__" -delete - python setup.py testr --slowest --testr-args='{posargs}' + stestr run --slowest {posargs} whitelist_externals = bash find @@ -28,17 +28,21 @@ whitelist_externals = [testenv:tips] # tests what happens with unreleased version of dependencies, like python-jenkins install_command = pip install -U {opts} {packages} -ignore_outcome = true commands = bash -c "if [ -d {toxinidir}/../python-jenkins ]; then \ pip install -q -U -e 'git+file://{toxinidir}/../python-jenkins#egg=python-jenkins' ; else \ pip install -q -U -e 'git+https://git.openstack.org/openstack/python-jenkins@master#egg=python-jenkins' ; fi " - python setup.py testr --slowest --testr-args='{posargs}' + stestr run --slowest {posargs} [testenv:cover] +setenv = + {[testenv]setenv} + PYTHON=coverage run --source jenkins_jobs --parallel-mode commands = - python setup.py test --coverage --coverage-package-name=jenkins_jobs - coverage report + stestr run {posargs} + coverage combine + coverage html -d cover + coverage xml -o cover/coverage.xml [testenv:pep8] commands = flake8 -- cgit