Replace testrepository with stestr

Move to stestr. That's what most of the OpenStack projects have done
given that testrepository seems to be unmaintained (last release in
2014[1]).

[1] https://pypi.org/project/testrepository/

Change-Id: I83c2ceb74eb291266b3afa33f49d17db84ee9cde
This commit is contained in:
Thomas Bechtold 2019-02-27 16:18:16 +01:00
parent 7ed1f4db45
commit b07ba3d6bd
6 changed files with 9 additions and 14 deletions

2
.gitignore vendored
View File

@ -26,7 +26,7 @@ pip-log.txt
.coverage
.tox
nosetests.xml
.testrepository
.stestr
.venv
# Translations

3
.stestr.conf Normal file
View File

@ -0,0 +1,3 @@
[DEFAULT]
test_path=${OS_TEST_PATH:-./os_win/tests}
top_dir=./

View File

@ -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

View File

@ -56,8 +56,8 @@ six==1.10.0
snowballstemmer==1.2.1
Sphinx==1.6.2
sphinxcontrib-websupport==1.0.1
stestr===2.0.0
stevedore==1.20.0
testrepository==0.0.18
testscenarios==0.4
testtools==2.2.0
traceback2==1.4.0

View File

@ -10,7 +10,7 @@ docutils>=0.11 # OSI-Approved Open Source, Public Domain
sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD
oslo.config>=5.2.0 # Apache-2.0
oslotest>=3.2.0 # Apache-2.0
testrepository>=0.0.18 # Apache-2.0/BSD
stestr>=2.0.0 # Apache-2.0
testscenarios>=0.4 # Apache-2.0/BSD
testtools>=2.2.0 # MIT
openstackdocstheme>=1.18.1 # Apache-2.0

View File

@ -10,9 +10,8 @@ deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/test-requirements.txt
-r{toxinidir}/requirements.txt
commands = rm -f .testrepository/times.dbm
python setup.py test --slowest --testr-args='{posargs}'
commands = stestr run --slowest {posargs}
[testenv:pep8]
basepython = python3
commands = flake8
@ -24,7 +23,7 @@ commands = {posargs}
[testenv:cover]
basepython = python3
commands = python setup.py test --coverage --testr-args='{posargs}'
[testenv:docs]
basepython = python3
commands = python setup.py build_sphinx