Add UUIDs to all tempest tests and gate check
Adds uuid4 as a decorator of the form:
@test.idempotent_id('12345678-1234-1234-1234-123456789abc')
to every test in the Tempest tree. Includes a gate check to
ensure the existence and uniqueness of the ids.
Modify check tool to ignore Tempest unit tests.
Change-Id: I19e3c7dd555a3ea09d585fb9091c357a300e6559
Co-Authored-By: Sergey Slipushenko <sslypushenko@mirantis.com>
Implements: bp test-uuid
diff --git a/tempest/api/data_processing/test_cluster_templates.py b/tempest/api/data_processing/test_cluster_templates.py
index 422ea5b..af7cbaf 100644
--- a/tempest/api/data_processing/test_cluster_templates.py
+++ b/tempest/api/data_processing/test_cluster_templates.py
@@ -112,10 +112,12 @@
return resp_body['id'], template_name
@test.attr(type='smoke')
+ @test.idempotent_id('3525f1f1-3f9c-407d-891a-a996237e728b')
def test_cluster_template_create(self):
self._create_cluster_template()
@test.attr(type='smoke')
+ @test.idempotent_id('7a161882-e430-4840-a1c6-1d928201fab2')
def test_cluster_template_list(self):
template_info = self._create_cluster_template()
@@ -126,6 +128,7 @@
self.assertIn(template_info, templates_info)
@test.attr(type='smoke')
+ @test.idempotent_id('2b75fe22-f731-4b0f-84f1-89ab25f86637')
def test_cluster_template_get(self):
template_id, template_name = self._create_cluster_template()
@@ -135,6 +138,7 @@
self.assertDictContainsSubset(self.cluster_template, template)
@test.attr(type='smoke')
+ @test.idempotent_id('ff1fd989-171c-4dd7-91fd-9fbc71b09675')
def test_cluster_template_delete(self):
template_id, _ = self._create_cluster_template()