Switch to use stestr for unit test

According to Openstack summit session [1],
stestr is maintained project to which all Openstack projects should migrate.
So we should switch to stestr.

[1] https://etherpad.openstack.org/p/YVR-python-pti

Change-Id: Iee13deb54056e1c81d3732cb51a61c68481607fa
This commit is contained in:
Ha Manh Dong
2018-07-17 14:28:12 +07:00
parent 15e65aec62
commit 42379399a2
5 changed files with 14 additions and 8 deletions

11
tox.ini
View File

@@ -10,7 +10,7 @@ setenv =
VIRTUAL_ENV={envdir}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
commands = python setup.py testr --slowest --testr-args='{posargs}'
commands = stestr run --slowest {posargs}
[testenv:pep8]
commands = flake8
@@ -19,7 +19,14 @@ commands = flake8
commands = {posargs}
[testenv:cover]
commands = python setup.py testr --coverage --testr-args='{posargs}'
setenv =
{[testenv]setenv}
PYTHON=coverage run --source cloudkittydashboard --parallel-mode
commands =
stestr run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
[testenv:docs]
commands = python setup.py build_sphinx