From 6e13d60c572605f736520dee2db50b2ddefac45e Mon Sep 17 00:00:00 2001 From: zhurong Date: Thu, 26 Jul 2018 12:04:08 +0800 Subject: [PATCH] Switch to using stestr Depends-On: https://review.openstack.org/#/c/585960/ Change-Id: I290e3eb9c6f7eebf785e58a5b00f09198f7783a7 --- .gitignore | 5 ++++- .stestr.conf | 3 +++ .testr.conf | 7 ------- lower-constraints.txt | 1 + test-requirements.txt | 1 + tox.ini | 2 +- 6 files changed, 10 insertions(+), 9 deletions(-) create mode 100644 .stestr.conf delete mode 100644 .testr.conf diff --git a/.gitignore b/.gitignore index b1d88e0..1f97166 100644 --- a/.gitignore +++ b/.gitignore @@ -56,4 +56,7 @@ ChangeLog .*sw? # Files created by releasenotes build -releasenotes/build \ No newline at end of file +releasenotes/build + +!/.stestr.conf +.stestr/ diff --git a/.stestr.conf b/.stestr.conf new file mode 100644 index 0000000..896f568 --- /dev/null +++ b/.stestr.conf @@ -0,0 +1,3 @@ +[DEFAULT] +test_path=${OS_TEST_PATH:-./muranopkgcheck/tests} +top_dir=./ diff --git a/.testr.conf b/.testr.conf deleted file mode 100644 index 6d83b3c..0000000 --- a/.testr.conf +++ /dev/null @@ -1,7 +0,0 @@ -[DEFAULT] -test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \ - OS_STDERR_CAPTURE=${OS_STDERR_CAPTURE:-1} \ - OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-60} \ - ${PYTHON:-python} -m subunit.run discover -t ./ . $LISTOPT $IDOPTION -test_id_option=--load-list $IDFILE -test_list_option=--list diff --git a/lower-constraints.txt b/lower-constraints.txt index 2833864..26e8b73 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -40,6 +40,7 @@ snowballstemmer==1.2.1 Sphinx==1.6.5 sphinxcontrib-websupport==1.0.1 stevedore==1.20.0 +stestr==1.0.0 testrepository==0.0.18 testscenarios==0.4 testtools==2.2.0 diff --git a/test-requirements.txt b/test-requirements.txt index 2f22260..f4f2f6b 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -12,6 +12,7 @@ oslotest>=3.2.0 # Apache-2.0 testrepository>=0.0.18 # Apache-2.0/BSD testscenarios>=0.4 # Apache-2.0/BSD testtools>=2.2.0 # MIT +stestr>=1.0.0 # Apache-2.0 # releasenotes reno>=2.5.0 # Apache-2.0 diff --git a/tox.ini b/tox.ini index f1658e5..674096e 100644 --- a/tox.ini +++ b/tox.ini @@ -14,7 +14,7 @@ deps = -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt -commands = python setup.py test --slowest --testr-args='{posargs}' +commands = stestr run {posargs} [testenv:pep8] basepython = python3