From 447ce96f3d80ed003095b032dd0a624937a3e0ed Mon Sep 17 00:00:00 2001 From: ghanshyam Date: Fri, 27 Jan 2017 06:35:57 +0000 Subject: [PATCH] Switch to decorators.idempotent_id test.idempotent_id is being kept temporary to migrate to new lib interface. Now idempotent_id is available as Tempest stable interface decorators and all plugins tests using the old decorator should be switched to new interface. In future, Once all plugins are switched to new decorator Tempest will remove the test.idempotent_id Change-Id: Idf6d897fe1e4c3658f45f291dc478d8dff867628 Related-Bug: 1616913 --- neutron_taas/tests/tempest_plugin/tests/api/test_taas.py | 5 +++-- .../tests/tempest_plugin/tests/scenario/test_taas.py | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/neutron_taas/tests/tempest_plugin/tests/api/test_taas.py b/neutron_taas/tests/tempest_plugin/tests/api/test_taas.py index 4370dcd..0837aa3 100644 --- a/neutron_taas/tests/tempest_plugin/tests/api/test_taas.py +++ b/neutron_taas/tests/tempest_plugin/tests/api/test_taas.py @@ -14,6 +14,7 @@ # under the License. from tempest import config +from tempest.lib import decorators from tempest import test from neutron_taas.tests.tempest_plugin.tests.api import base @@ -30,7 +31,7 @@ class TaaSExtensionTestJSON(base.BaseTaaSTest): msg = "TaaS Extension not enabled." raise cls.skipException(msg) - @test.idempotent_id('b993c14e-797a-4c91-b4da-8cb1a450aa2f') + @decorators.idempotent_id('b993c14e-797a-4c91-b4da-8cb1a450aa2f') def test_create_tap_service_and_flow(self): network = self.create_network() port = self.create_port(network) @@ -38,7 +39,7 @@ class TaaSExtensionTestJSON(base.BaseTaaSTest): self.create_tap_flow(tap_service_id=tap_service['id'], direction='BOTH', source_port=port['id']) - @test.idempotent_id('d7a2115d-16b4-41cf-95a6-dcebc3682b24') + @decorators.idempotent_id('d7a2115d-16b4-41cf-95a6-dcebc3682b24') def test_delete_tap_service_after_delete_port(self): network = self.create_network() port = self.create_port(network) diff --git a/neutron_taas/tests/tempest_plugin/tests/scenario/test_taas.py b/neutron_taas/tests/tempest_plugin/tests/scenario/test_taas.py index a531a9f..3fcd685 100644 --- a/neutron_taas/tests/tempest_plugin/tests/scenario/test_taas.py +++ b/neutron_taas/tests/tempest_plugin/tests/scenario/test_taas.py @@ -14,6 +14,7 @@ # under the License. from tempest import config +from tempest.lib import decorators from tempest import test from neutron_taas.tests.tempest_plugin.tests.scenario import base @@ -31,6 +32,6 @@ class TestTaaS(base.TaaSScenarioTest): msg = "%s Extension not enabled." % ext raise cls.skipException(msg) - @test.idempotent_id('40903cbd-0e3c-464d-b311-dc77d3894e65') + @decorators.idempotent_id('40903cbd-0e3c-464d-b311-dc77d3894e65') def test_dummy(self): pass