Skip tests when heat is unavailable
Currently the [service_available] heat parameter is not actually used and the plugin tests are always executed regardless of availability of Heat service. This change ensures that the parameter is honored so that users can disable plugin tests even if the plugin package is enabled. Change-Id: I148d7a9c92f210d4584798131a1b23f648f6e5e3
This commit is contained in:
parent
111afa34bd
commit
c4b871a79e
@ -170,6 +170,9 @@ class HeatIntegrationTest(testtools.testcase.WithAttributes,
|
||||
def setUp(self):
|
||||
super(HeatIntegrationTest, self).setUp()
|
||||
|
||||
if not config.CONF.service_available.heat:
|
||||
raise self.skipException("Heat is not available")
|
||||
|
||||
self.conf = config.CONF.heat_plugin
|
||||
|
||||
self.assertIsNotNone(self.conf.auth_url,
|
||||
|
@ -16,10 +16,14 @@ import os
|
||||
from gabbi import fixture
|
||||
from heat_tempest_plugin.services import clients
|
||||
from tempest import config
|
||||
import unittest.case
|
||||
|
||||
|
||||
class AuthenticationFixture(fixture.GabbiFixture):
|
||||
def start_fixture(self):
|
||||
if not config.CONF.service_available.heat:
|
||||
raise unittest.case.SkipTest("Heat is not available")
|
||||
|
||||
conf = config.CONF.heat_plugin
|
||||
manager = clients.ClientManager(conf)
|
||||
os.environ['OS_TOKEN'] = manager.identity_client.auth_token
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
The ``[service_available] heat`` parameter now takes effect and disables
|
||||
all tests when it is set to ``False``.
|
Loading…
Reference in New Issue
Block a user