Migrate from testr to stestr
* Replace .testr.conf by .stestr.conf for migration and update .gitignore,test-requirements files accordingly * Use 3.18.0 as the minversion for tox Change-Id: I6bf98adecb772896c6243a90271a1b258569a4df
This commit is contained in:
parent
0c56491a7e
commit
556a43ef31
2
.gitignore
vendored
2
.gitignore
vendored
@ -25,7 +25,7 @@ pip-log.txt
|
|||||||
.coverage
|
.coverage
|
||||||
.tox
|
.tox
|
||||||
nosetests.xml
|
nosetests.xml
|
||||||
.testrepository
|
.stestr/
|
||||||
.venv
|
.venv
|
||||||
|
|
||||||
# Translations
|
# Translations
|
||||||
|
3
.stestr.conf
Normal file
3
.stestr.conf
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
[DEFAULT]
|
||||||
|
test_path=./vitrage_dashboard/dashboard/tests/
|
||||||
|
top_dir=./
|
@ -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
|
|
@ -7,7 +7,7 @@ hacking>=3.0.1,<3.1.0 # Apache-2.0
|
|||||||
coverage>=3.6
|
coverage>=3.6
|
||||||
python-subunit>=0.0.18
|
python-subunit>=0.0.18
|
||||||
nodeenv>=0.9.4 # BSD
|
nodeenv>=0.9.4 # BSD
|
||||||
testrepository>=0.0.18
|
stestr>=2.0.0 # Apache-2.0
|
||||||
testscenarios>=0.4
|
testscenarios>=0.4
|
||||||
testtools>=1.4.0
|
testtools>=1.4.0
|
||||||
pytest>=5.3.5 # MIT
|
pytest>=5.3.5 # MIT
|
||||||
|
15
tox.ini
15
tox.ini
@ -1,5 +1,5 @@
|
|||||||
[tox]
|
[tox]
|
||||||
minversion = 2.3.2
|
minversion = 3.18.0
|
||||||
envlist = py3,pep8,npm
|
envlist = py3,pep8,npm
|
||||||
skipsdist = True
|
skipsdist = True
|
||||||
ignore_basepython_conflict = True
|
ignore_basepython_conflict = True
|
||||||
@ -54,7 +54,18 @@ deps =
|
|||||||
commands = {posargs}
|
commands = {posargs}
|
||||||
|
|
||||||
[testenv:cover]
|
[testenv:cover]
|
||||||
commands = python setup.py test --coverage --testr-args='{posargs}'
|
allowlist_externals = find
|
||||||
|
setenv =
|
||||||
|
PYTHON=coverage run --source vitrage-dashboard --parallel-mode
|
||||||
|
commands =
|
||||||
|
coverage erase
|
||||||
|
find . -type f -name "*.pyc" -delete
|
||||||
|
stestr run {posargs}
|
||||||
|
coverage combine
|
||||||
|
coverage html -d cover
|
||||||
|
coverage xml -o cover/coverage.xml
|
||||||
|
coverage report
|
||||||
|
|
||||||
|
|
||||||
[testenv:docs]
|
[testenv:docs]
|
||||||
deps = -r{toxinidir}/doc/requirements.txt
|
deps = -r{toxinidir}/doc/requirements.txt
|
||||||
|
Loading…
Reference in New Issue
Block a user