Add skip for api tests
We should skip tests if this service environment doesn't consist in environment
Change-Id: I67d2596b32063df92092e58bb3803372b22d1492
Related-Prod: PRODX-5292
(cherry picked from commit cc7c63686d02ded823d85012d79826d715208582)
(cherry picked from commit 428ee443b6c71957fd243744ec1a9ea029f8cc4f)
(cherry picked from commit f17220962c343675d049659cf662210a797fd062)
(cherry picked from commit 4175d615ce123e74d26c281eda2ce2f747feaa64)
(cherry picked from commit bb54171adb2072c6c30afed54227304c26014a62)
diff --git a/barbican_tempest_plugin/tests/api/base.py b/barbican_tempest_plugin/tests/api/base.py
index 7256a10..26fe533 100644
--- a/barbican_tempest_plugin/tests/api/base.py
+++ b/barbican_tempest_plugin/tests/api/base.py
@@ -65,6 +65,12 @@
created_objects = {}
@classmethod
+ def skip_checks(cls):
+ super(BaseKeyManagerTest, cls).skip_checks()
+ if not CONF.service_available.barbican:
+ raise cls.skipException('Barbican is not enabled.')
+
+ @classmethod
def setup_clients(cls):
super(BaseKeyManagerTest, cls).setup_clients()
os = getattr(cls, 'os_%s' % cls.credentials[0])