Feature flag: allow disabling 'manage snapshot' tests

Manage/unmanage snapshots is an optional feature of Cinder, not every
backend supports it. Thus we should disable the related tests by
default, and enable them on supported backends.

Change-Id: I77be1cf85a946bf72e852f6378f0d7b43af8023a
This commit is contained in:
Jordan Pittier 2017-01-11 14:29:49 +01:00
parent e3785d7092
commit 3125625e0f
2 changed files with 5 additions and 3 deletions
tempest

@ -32,9 +32,8 @@ class SnapshotManageAdminV2Test(base.BaseVolumeAdminTest):
"""
@test.idempotent_id('0132f42d-0147-4b45-8501-cc504bbf7810')
@testtools.skipIf(CONF.volume.storage_protocol == 'ceph',
'Currently, Ceph does not support '
'unmanage/manage snapshot')
@testtools.skipUnless(CONF.volume_feature_enabled.manage_snapshot,
"Manage snapshot tests are disabled")
def test_unmanage_manage_snapshot(self):
# Create a volume
volume = self.create_volume()

@ -804,6 +804,9 @@ VolumeFeaturesGroup = [
cfg.BoolOpt('clone',
default=True,
help='Runs Cinder volume clone test'),
cfg.BoolOpt('manage_snapshot',
default=False,
help='Runs Cinder manage snapshot tests'),
cfg.ListOpt('api_extensions',
default=['all'],
help='A list of enabled volume extensions with a special '