diff --git a/docs/packstack.rst b/docs/packstack.rst index 383179c53..729699d6d 100755 --- a/docs/packstack.rst +++ b/docs/packstack.rst @@ -1035,6 +1035,9 @@ Provisioning tempest config **CONFIG_RUN_TEMPEST_TESTS** Test suites to run, example: "smoke dashboard TelemetryAlarming". Optional, defaults to "smoke". +**CONFIG_SKIP_TEMPEST_TESTS** + Tests to skip, example: "test_basic_scenario test_volume". Optional, defaults to "". + **CONFIG_PROVISION_UEC_IMAGE_NAME** Name of the uec image created in Glance used in tempest tests (default "cirros-uec"). diff --git a/packstack/plugins/postscript_951.py b/packstack/plugins/postscript_951.py index fd4da8877..a6e02f21e 100644 --- a/packstack/plugins/postscript_951.py +++ b/packstack/plugins/postscript_951.py @@ -56,8 +56,9 @@ def run_tempest(config, messages): print("Running Tempest on %s" % config['CONFIG_TEMPEST_HOST']) server = utils.ScriptRunner(config['CONFIG_TEMPEST_HOST']) server.append('pushd /var/lib/tempest') - server.append('tempest run --regex \'(%s)\' --concurrency 2 > %s' + server.append('tempest run --regex \'(%s)\' --black-regex \'%s\' --concurrency 2 > %s' % (config['CONFIG_RUN_TEMPEST_TESTS'].replace(' ', '|'), + config['CONFIG_SKIP_TEMPEST_TESTS'].replace(' ', '|'), logfile)) server.append('popd') server.execute() diff --git a/packstack/plugins/provision_700.py b/packstack/plugins/provision_700.py index f6212c6de..5e359a573 100644 --- a/packstack/plugins/provision_700.py +++ b/packstack/plugins/provision_700.py @@ -406,6 +406,19 @@ def initConfig(controller): "CONF_NAME": "CONFIG_RUN_TEMPEST_TESTS", "USE_DEFAULT": False, "NEED_CONFIRM": False, + "CONDITION": False}, + + {"CMD_OPTION": "skip-tempest-tests", + "PROMPT": ("What tempest tests should skipped ?" + " (If blank, Tempest will not skip any tests)"), + "OPTION_LIST": [], + "VALIDATORS": False, + "DEFAULT_VALUE": "", + "MASK_INPUT": False, + "LOOSE_VALIDATION": True, + "CONF_NAME": "CONFIG_SKIP_TEMPEST_TESTS", + "USE_DEFAULT": False, + "NEED_CONFIRM": False, "CONDITION": False} ], diff --git a/releasenotes/notes/add-skip-tempest-tests-option-86cf59ec5a61d349.yaml b/releasenotes/notes/add-skip-tempest-tests-option-86cf59ec5a61d349.yaml new file mode 100644 index 000000000..0bf75aaaa --- /dev/null +++ b/releasenotes/notes/add-skip-tempest-tests-option-86cf59ec5a61d349.yaml @@ -0,0 +1,6 @@ +--- +features: + - | + Add new config option "CONFIG_SKIP_TEMPEST_TESTS" to allow + skipping of some of tempest tests which are running as part + of "CONFIG_RUN_TEMPEST_TESTS".