Migrate .testr.conf to .stestr.conf

With the latests changes to os-testr[0] it now expects a
.stestr.conf file instead of a .testr.conf file. This
change migrates .testr.conf into .stestr.conf and adds the
new testing directory into .gitignore.

[0] http://lists.openstack.org/pipermail/openstack-dev/2017-September/122135.html

Change-Id: I1ff2f4d0c719b0947da70b21cbbfc9e74be76047
This commit is contained in:
Gage Hugo 2017-09-25 10:42:22 -05:00
parent fb512cd3ab
commit d73fc14b1b
4 changed files with 11 additions and 14 deletions

2
.gitignore vendored
View File

@ -71,9 +71,9 @@ coverage.xml
ostro-daemon.pid
.project
.pydevproject
.testrepository
.settings
.settings/
.stestr
# Translations
*.mo

3
.stestr.conf Normal file
View File

@ -0,0 +1,3 @@
[DEFAULT]
test_path=./valet/tests/unit
top_dir=.

View File

@ -1,7 +0,0 @@
[DEFAULT]
test_command=OS_STDOUT_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
OS_STDERR_CAPTURE=${OS_STDOUT_CAPTURE:-1} \
OS_TEST_TIMEOUT=${OS_TEST_TIMEOUT:-1000} \
${PYTHON:-python} -m subunit.run discover ${OS_TEST_PATH:-./valet/tests/unit} -t . $LISTOPT $IDOPTION
test_id_option=--load-list $IDFILE
test_list_option=--list

13
tox.ini
View File

@ -39,14 +39,15 @@ commands = python setup.py testr --slowest --testr-args='{posargs}'
[testenv:cover]
# Do NOT run test_coverage_ext tests while gathering coverage.
# Those tests conflict with coverage.
setenv = VIRTUAL_ENV={envdir}
OS_TEST_PATH=valet/tests/unit
setenv =
{[testenv]setenv}
PYTHON=coverage run --source valet --parallel-mode
commands =
coverage erase
find . -type f -name "*.pyc" -delete
python setup.py test --slowest --coverage --coverage-package-name 'valet' --testr-args='{posargs}'
coverage html
coverage report
stestr run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
[testenv:docs]
commands = python setup.py build_sphinx