Add sanity check for idempotent id's in tempest tests
Idempotent id's for tempest tests must be unique, as it's used to trace
tests even in the event of refactors [1].
This patch adds a new check using check-uuid tool from tempest to
validate id uniqueness. This adds a new test-only dependency to pull in
tempest from PyPI to make pep8 tox target work.
Also, the duplicate idempotent id's in our tests have been fixed.
[1]
http://docs.openstack.org/developer/tempest/HACKING.html#test-identification-with-idempotent-id
Co-Authored-By: Ihar Hrachyshka <ihrachys@redhat.com>
Change-Id: Ie92e4576d9ce6c26f19bdd668426c71a62409e7a
diff --git a/neutron/tests/tempest/scenario/test_basic.py b/neutron/tests/tempest/scenario/test_basic.py
index 8fa6aea..c05e1c2 100644
--- a/neutron/tests/tempest/scenario/test_basic.py
+++ b/neutron/tests/tempest/scenario/test_basic.py
@@ -14,6 +14,7 @@
# under the License.
from oslo_log import log as logging
from tempest.common import waiters
+from tempest import test
from neutron.tests.tempest import config
from neutron.tests.tempest.scenario import base
@@ -30,6 +31,8 @@
# Default to ipv4.
_ip_version = 4
+
+ @test.idempotent_id('de07fe0a-e955-449e-b48b-8641c14cd52e')
def test_basic_instance(self):
network = self.create_network()
subnet = self.create_subnet(network)