From 6f746b92282f1a4b82509448d53130a74adeb0c4 Mon Sep 17 00:00:00 2001 From: Eyal Date: Wed, 26 Feb 2020 14:31:28 +0200 Subject: [PATCH] Fix preinstalled workflows tests The 'std' prefix was removed from the workflow name make sure it passes on both cases. Change-Id: I9bd36bf2ad1a36ff569f385190c186b63b78f1e1 --- mistral_tempest_tests/tests/api/v2/test_workflows.py | 2 +- mistral_tempest_tests/tests/base.py | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/mistral_tempest_tests/tests/api/v2/test_workflows.py b/mistral_tempest_tests/tests/api/v2/test_workflows.py index 60641c6..26abc23 100644 --- a/mistral_tempest_tests/tests/api/v2/test_workflows.py +++ b/mistral_tempest_tests/tests/api/v2/test_workflows.py @@ -44,7 +44,7 @@ class WorkflowTestsV2(base.TestCase): names = [wf['name'] for wf in body['workflows']] - self.assertIn('std.create_instance', names) + self.assertPartIn('create_instance', names) self.assertNotIn('next', body) diff --git a/mistral_tempest_tests/tests/base.py b/mistral_tempest_tests/tests/base.py index 13116bc..923648c 100644 --- a/mistral_tempest_tests/tests/base.py +++ b/mistral_tempest_tests/tests/base.py @@ -59,6 +59,9 @@ class TestCase(test.BaseTestCase): self.alt_client = mistral_client.MistralClientV2( self.alt_mgr.auth_provider, self._service) + def assertPartIn(self, needle, haystack, message=''): + self.assertTrue(any(needle in s for s in haystack), message) + def tearDown(self): super(TestCase, self).tearDown()