Merge "Switch to stestr"

This commit is contained in:
Zuul 2018-07-20 08:56:35 +00:00 committed by Gerrit Code Review
commit 1959f2d4f5
5 changed files with 15 additions and 12 deletions

3
.gitignore vendored
View File

@ -34,10 +34,9 @@ pip-delete-this-directory.txt
# Unit test / coverage reports
htmlcov/
.tox/
.testrepository
.stestr/
.coverage
.cache
nosetests.xml
coverage.xml
cover

4
.stestr.conf Normal file
View File

@ -0,0 +1,4 @@
[DEFAULT]
test_path=./cloudkitty/tests
top_dir=./
group_regex=gabbi\.(suitemaker|driver)\.(test_[^_]+_[^_]+)

View File

@ -1,5 +0,0 @@
[DEFAULT]
test_command=${PYTHON:-python} -m subunit.run discover -t ./ ./cloudkitty/tests $LISTOPT $IDOPTION
test_id_option=--load-list $IDFILE
test_list_option=--list
group_regex=gabbi\.(suitemaker|driver)\.(test_[^_]+_[^_]+)

View File

@ -10,7 +10,7 @@ kombu<4.0.0 # BSD
ddt>=1.0.1 # MIT
gabbi>=1.26.1 # Apache-2.0
testscenarios>=0.4 # Apache-2.0/BSD
testrepository>=0.0.18 # Apache-2.0/BSD
stestr>=2.0.0 # Apache-2.0
mock>=1.2 # BSD
sphinx>=1.6.2 # BSD
openstackdocstheme>=1.11.0 # Apache-2.0

13
tox.ini
View File

@ -15,7 +15,7 @@ deps = -r{toxinidir}/requirements.txt
commands =
/usr/bin/find . -type f -name "*.py[co]" -delete
rm -f .testrepository/times.dbm
python setup.py testr --testr-args='{posargs}'
stestr run {posargs}
[testenv:debug]
basepython = python3
@ -28,10 +28,15 @@ commands =
[testenv:cover]
basepython = python3
setenv = VIRTUAL_ENV={envdir}
setenv =
VIRTUAL_ENV={envdir}
PYTHON=coverage run --source $project --parallel-mode
commands =
python setup.py testr --coverage --testr-args='{posargs}'
coverage report
stestr run '{posargs}'
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
coverage report
[testenv:genconfig]
basepython = python3