Put stestr group_regex in .stestr.conf
This dries up tox.ini a bit while preserving the explanatory comment. Having the grouping expression on test jobs that don't require it has only minor impact: the regex is applied to the list of tests and no groups are found. Change-Id: I89330cf5b0ace25db6a7575cfa4f93d9575b08ac
This commit is contained in:
parent
81d40b37b3
commit
12a9e321bd
|
@ -1,3 +1,12 @@
|
||||||
[DEFAULT]
|
[DEFAULT]
|
||||||
test_path=./placement/tests/unit
|
test_path=./placement/tests/unit
|
||||||
top_dir=./
|
top_dir=./
|
||||||
|
# The group_regex describes how stestr will group tests into the same process
|
||||||
|
# when running concurently. The following ensures that gabbi tests coming from
|
||||||
|
# the same YAML file are all in the same process. This is important because
|
||||||
|
# each YAML file represents an ordered sequence of HTTP requests. Note that
|
||||||
|
# tests which do not match this regex will not be grouped in any special way.
|
||||||
|
# See the following for more details.
|
||||||
|
# http://stestr.readthedocs.io/en/latest/MANUAL.html#grouping-tests
|
||||||
|
# https://gabbi.readthedocs.io/en/latest/#purpose
|
||||||
|
group_regex=placement\.tests\.functional\.test_api(?:\.|_)([^_]+)
|
||||||
|
|
12
tox.ini
12
tox.ini
|
@ -72,15 +72,7 @@ envdir = {toxworkdir}/py27
|
||||||
setenv = {[testenv]setenv}
|
setenv = {[testenv]setenv}
|
||||||
commands =
|
commands =
|
||||||
{[testenv]commands}
|
{[testenv]commands}
|
||||||
# NOTE(cdent): The group_regex describes how stestr will group tests into the
|
stestr --test-path=./placement/tests/functional run {posargs}
|
||||||
# same process when running concurently. The following ensures that gabbi tests
|
|
||||||
# coming from the same YAML file are all in the same process. This is important
|
|
||||||
# because each YAML file represents an ordered sequence of HTTP requests. Note
|
|
||||||
# that tests which do not match this regex will not be grouped in any
|
|
||||||
# special way. See the following for more details.
|
|
||||||
# http://stestr.readthedocs.io/en/latest/MANUAL.html#grouping-tests
|
|
||||||
# https://gabbi.readthedocs.io/en/latest/#purpose
|
|
||||||
stestr --test-path=./placement/tests/functional --group_regex=placement\.tests\.functional\.test_api(?:\.|_)([^_]+) run {posargs}
|
|
||||||
stestr slowest
|
stestr slowest
|
||||||
|
|
||||||
# TODO(gcb) Merge this into [testenv:functional] when functional tests are gating
|
# TODO(gcb) Merge this into [testenv:functional] when functional tests are gating
|
||||||
|
@ -121,7 +113,7 @@ setenv =
|
||||||
commands =
|
commands =
|
||||||
{[testenv]commands}
|
{[testenv]commands}
|
||||||
coverage erase
|
coverage erase
|
||||||
stestr --test-path=./placement/tests --group_regex=placement\.tests\.functional\.test_api(?:\.|_)([^_]+) run {posargs}
|
stestr --test-path=./placement/tests run {posargs}
|
||||||
coverage combine
|
coverage combine
|
||||||
coverage html -d cover
|
coverage html -d cover
|
||||||
coverage xml -o cover/coverage.xml
|
coverage xml -o cover/coverage.xml
|
||||||
|
|
Loading…
Reference in New Issue