Merge "Switch to stestr in README.rst and the method name"

This commit is contained in:
Zuul 2018-08-24 08:45:38 +00:00 committed by Gerrit Code Review
commit 78818b7dc8
3 changed files with 11 additions and 6 deletions

View File

@ -111,15 +111,18 @@ as it is simpler, and quicker to work with.
$ tempest run --workspace cloud-01
There is also the option to use testr directly, or any `testr`_ based test
runner, like `ostestr`_. For example, from the workspace dir run::
There is also the option to use `stestr`_ directly. For example, from
the workspace dir run::
$ ostestr --regex '(?!.*\[.*\bslow\b.*\])(^tempest\.(api|scenario))'
$ stestr run --black-regex '\[.*\bslow\b.*\]' '^tempest\.(api|scenario)'
will run the same set of tests as the default gate jobs.
will run the same set of tests as the default gate jobs. Or you can
use `unittest`_ compatible test runners such as `testr`_, `pytest`_ etc.
.. _unittest: https://docs.python.org/3/library/unittest.html
.. _testr: https://testrepository.readthedocs.org/en/latest/MANUAL.html
.. _ostestr: https://docs.openstack.org/os-testr/latest/
.. _stestr: https://stestr.readthedocs.org/en/latest/MANUAL.html
.. _pytest: https://docs.pytest.org/en/latest/
Library
-------

View File

@ -22,7 +22,7 @@ from tempest.tests import base
class TestTempestInit(base.TestCase):
def test_generate_testr_conf(self):
def test_generate_stestr_conf(self):
# Create fake conf dir
conf_dir = self.useFixture(fixtures.TempDir())

View File

@ -78,6 +78,7 @@ setenv = {[tempestenv]setenv}
deps = {[tempestenv]deps}
# The regex below is used to select which tests to run and exclude the slow tag:
# See the testrepository bug: https://bugs.launchpad.net/testrepository/+bug/1208610
# FIXME: We can replace it with the `--black-regex` option to exclude tests now.
commands =
find . -type f -name "*.pyc" -delete
tempest run --regex '(?!.*\[.*\bslow\b.*\])(^tempest\.api)' {posargs}
@ -100,6 +101,7 @@ setenv = {[tempestenv]setenv}
deps = {[tempestenv]deps}
# The regex below is used to select which tests to run and exclude the slow tag:
# See the testrepository bug: https://bugs.launchpad.net/testrepository/+bug/1208610
# FIXME: We can replace it with the `--black-regex` option to exclude tests now.
commands =
find . -type f -name "*.pyc" -delete
tempest run --serial --regex '(?!.*\[.*\bslow\b.*\])(^tempest\.(api|scenario))' {posargs}