Migrating oslo.config to use stestr
os-testr has moved over to use stestr instead of testr. While this is usually compaible with existing settings, there is a warning that is emitted when .stestr.conf is not present. It is usually able to fall back to parsing the .testr.conf file, but to be more correct and to prevent future problems we should update the config. Change-Id: I929f75d069f20b8cfa8af4e0712883e91a54dc4f
This commit is contained in:
parent
d32126b84f
commit
819534b20b
1
.gitignore
vendored
1
.gitignore
vendored
@ -24,6 +24,7 @@ doc/source/api/
|
|||||||
dist/
|
dist/
|
||||||
.testrepository/
|
.testrepository/
|
||||||
/doc/source/sample.config
|
/doc/source/sample.config
|
||||||
|
.stestr/
|
||||||
|
|
||||||
# Files created by releasenotes build
|
# Files created by releasenotes build
|
||||||
releasenotes/build
|
releasenotes/build
|
||||||
|
3
.stestr.conf
Normal file
3
.stestr.conf
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
[DEFAULT]
|
||||||
|
test_path=.
|
||||||
|
top_dir=./
|
@ -46,6 +46,7 @@ smmap==0.9.0
|
|||||||
snowballstemmer==1.2.1
|
snowballstemmer==1.2.1
|
||||||
Sphinx==1.6.2
|
Sphinx==1.6.2
|
||||||
sphinxcontrib-websupport==1.0.1
|
sphinxcontrib-websupport==1.0.1
|
||||||
|
stestr==2.0.0
|
||||||
stevedore==1.20.0
|
stevedore==1.20.0
|
||||||
testrepository==0.0.18
|
testrepository==0.0.18
|
||||||
testscenarios==0.4
|
testscenarios==0.4
|
||||||
|
@ -6,6 +6,7 @@ hacking!=0.13.0,<0.14,>=0.12.0 # Apache-2.0
|
|||||||
fixtures>=3.0.0 # Apache-2.0/BSD
|
fixtures>=3.0.0 # Apache-2.0/BSD
|
||||||
testrepository>=0.0.18 # Apache-2.0/BSD
|
testrepository>=0.0.18 # Apache-2.0/BSD
|
||||||
testscenarios>=0.4 # Apache-2.0/BSD
|
testscenarios>=0.4 # Apache-2.0/BSD
|
||||||
|
stestr>=2.0.0 # Apache-2.0
|
||||||
testtools>=2.2.0 # MIT
|
testtools>=2.2.0 # MIT
|
||||||
oslotest>=3.2.0 # Apache-2.0
|
oslotest>=3.2.0 # Apache-2.0
|
||||||
|
|
||||||
|
14
tox.ini
14
tox.ini
@ -5,13 +5,17 @@ envlist = py35,py27,pep8
|
|||||||
|
|
||||||
[testenv]
|
[testenv]
|
||||||
install_command = pip install {opts} {packages}
|
install_command = pip install {opts} {packages}
|
||||||
|
setenv = OS_STDOUT_CAPTURE=1
|
||||||
|
OS_STDERR_CAPTURE=1
|
||||||
|
OS_TEST_TIMEOUT=60
|
||||||
deps =
|
deps =
|
||||||
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
|
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
|
||||||
-r{toxinidir}/test-requirements.txt
|
-r{toxinidir}/test-requirements.txt
|
||||||
-r{toxinidir}/requirements.txt
|
-r{toxinidir}/requirements.txt
|
||||||
commands =
|
commands =
|
||||||
python setup.py test --coverage --coverage-package-name=oslo_config --slowest --testr-args='{posargs}'
|
find . -type f -name "*.pyc" -delete
|
||||||
coverage report --show-missing
|
stestr run {posargs}
|
||||||
|
stestr slowest
|
||||||
|
|
||||||
[testenv:lower-constraints]
|
[testenv:lower-constraints]
|
||||||
basepython = python3
|
basepython = python3
|
||||||
@ -33,7 +37,11 @@ commands =
|
|||||||
[testenv:cover]
|
[testenv:cover]
|
||||||
basepython = python3
|
basepython = python3
|
||||||
commands =
|
commands =
|
||||||
python setup.py test --coverage --coverage-package-name=oslo_config --testr-args='{posargs}'
|
coverage erase
|
||||||
|
{[testenv]commands}
|
||||||
|
coverage combine
|
||||||
|
coverage html -d cover
|
||||||
|
coverage xml -o cover/coverage.xml
|
||||||
coverage report --show-missing
|
coverage report --show-missing
|
||||||
|
|
||||||
[testenv:venv]
|
[testenv:venv]
|
||||||
|
Loading…
Reference in New Issue
Block a user