Skip to content

Commit

Permalink
Document how to write multiline regex with comments
Browse files Browse the repository at this point in the history
It is possible to add multiline and docummented regex to the
tempest_test_regex but it might not be evident at first, although very
useful for some scenarios.

This patch documents how this should be achieved to make it easier for
people in the future.

Change-Id: Id54679debedb1667cc70004b9a28fba921e50c0b
  • Loading branch information
mpeterson committed Dec 25, 2017
1 parent e3075a1 commit 515edd4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions roles/run-tempest/README.rst
Expand Up @@ -16,9 +16,19 @@ Run Tempest
:default: ''

A regular expression used to select the tests.

It works only when used with some specific tox environments
('all', 'all-plugin'.)

Multi-line and commented regexs can be achieved by doing this:

::
vars:
tempest_test_regex: |
(?x) # Ignore comments and whitespaces
# Line with only a comment.
(tempest\.(api|scenario|thirdparty)).*$ # Run only api scenario and third party

.. zuul:rolevar:: tox_venvlist
:default: smoke

Expand Down

0 comments on commit 515edd4

Please sign in to comment.