Rename Cinder V2 API tests
As http://lists.openstack.org/pipermail/openstack-dev/2017-March/114507.html we will use the existing Cinder V2 API tests for testing the base microversion of Cinder V3 API also. The V2 test classes contained "V2" on these names, and that will be confusing when using them for the V3 tests. This patch just renames the V2 tests by removing "V3" from the test class names. Change-Id: Ia89f4c1492983aef7d3394a6278c3c3c5fd11529
This commit is contained in:
parent
391516076b
commit
e8afb8c2c5
@ -20,18 +20,18 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumeMultiBackendV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumeMultiBackendTest(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumeMultiBackendV2Test, cls).skip_checks()
|
||||
super(VolumeMultiBackendTest, cls).skip_checks()
|
||||
|
||||
if not CONF.volume_feature_enabled.multi_backend:
|
||||
raise cls.skipException("Cinder multi-backend feature disabled")
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumeMultiBackendV2Test, cls).resource_setup()
|
||||
super(VolumeMultiBackendTest, cls).resource_setup()
|
||||
|
||||
# read backend name from a list .
|
||||
backend_names = set(CONF.volume.backend_names)
|
||||
@ -89,7 +89,7 @@ class VolumeMultiBackendV2Test(base.BaseVolumeAdminTest):
|
||||
cls.admin_volume_client.delete_volume(volume_id)
|
||||
cls.admin_volume_client.wait_for_resource_deletion(volume_id)
|
||||
|
||||
super(VolumeMultiBackendV2Test, cls).resource_cleanup()
|
||||
super(VolumeMultiBackendTest, cls).resource_cleanup()
|
||||
|
||||
@decorators.idempotent_id('c1a41f3f-9dad-493e-9f09-3ff197d477cc')
|
||||
def test_backend_name_reporting(self):
|
||||
|
@ -18,16 +18,16 @@ from tempest.lib.common.utils import data_utils as utils
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class QosSpecsV2TestJSON(base.BaseVolumeAdminTest):
|
||||
class QosSpecsTestJSON(base.BaseVolumeAdminTest):
|
||||
"""Test the Cinder QoS-specs.
|
||||
|
||||
Tests for create, list, delete, show, associate,
|
||||
disassociate, set/unset key V2 APIs.
|
||||
disassociate, set/unset key APIs.
|
||||
"""
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(QosSpecsV2TestJSON, cls).resource_setup()
|
||||
super(QosSpecsTestJSON, cls).resource_setup()
|
||||
# Create admin qos client
|
||||
# Create a test shared qos-specs for tests
|
||||
cls.qos_name = utils.rand_name(cls.__name__ + '-QoS')
|
||||
|
@ -20,16 +20,16 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class SnapshotsActionsV2Test(base.BaseVolumeAdminTest):
|
||||
class SnapshotsActionsTest(base.BaseVolumeAdminTest):
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(SnapshotsActionsV2Test, cls).skip_checks()
|
||||
super(SnapshotsActionsTest, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException("Cinder snapshot feature disabled")
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(SnapshotsActionsV2Test, cls).resource_setup()
|
||||
super(SnapshotsActionsTest, cls).resource_setup()
|
||||
|
||||
# Create a test shared volume for tests
|
||||
cls.volume = cls.create_volume()
|
||||
@ -43,7 +43,7 @@ class SnapshotsActionsV2Test(base.BaseVolumeAdminTest):
|
||||
snapshot_id = self.snapshot['id']
|
||||
self.admin_snapshots_client.reset_snapshot_status(snapshot_id,
|
||||
status)
|
||||
super(SnapshotsActionsV2Test, self).tearDown()
|
||||
super(SnapshotsActionsTest, self).tearDown()
|
||||
|
||||
def _create_reset_and_force_delete_temp_snapshot(self, status=None):
|
||||
# Create snapshot, reset snapshot status,
|
||||
|
@ -17,7 +17,7 @@ from tempest.api.volume import base
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class VolumeHostsAdminV2TestsJSON(base.BaseVolumeAdminTest):
|
||||
class VolumeHostsAdminTestsJSON(base.BaseVolumeAdminTest):
|
||||
|
||||
@decorators.idempotent_id('d5f3efa2-6684-4190-9ced-1c2f526352ad')
|
||||
def test_list_hosts(self):
|
||||
|
@ -21,14 +21,14 @@ QUOTA_KEYS = ['gigabytes', 'snapshots', 'volumes', 'backups']
|
||||
QUOTA_USAGE_KEYS = ['reserved', 'limit', 'in_use']
|
||||
|
||||
|
||||
class BaseVolumeQuotasAdminV2TestJSON(base.BaseVolumeAdminTest):
|
||||
class BaseVolumeQuotasAdminTestJSON(base.BaseVolumeAdminTest):
|
||||
force_tenant_isolation = True
|
||||
|
||||
credentials = ['primary', 'alt', 'admin']
|
||||
|
||||
@classmethod
|
||||
def setup_credentials(cls):
|
||||
super(BaseVolumeQuotasAdminV2TestJSON, cls).setup_credentials()
|
||||
super(BaseVolumeQuotasAdminTestJSON, cls).setup_credentials()
|
||||
cls.demo_tenant_id = cls.os.credentials.tenant_id
|
||||
cls.alt_client = cls.os_alt.volumes_client
|
||||
|
||||
|
@ -22,17 +22,17 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class BaseVolumeQuotasNegativeV2TestJSON(base.BaseVolumeAdminTest):
|
||||
class BaseVolumeQuotasNegativeTestJSON(base.BaseVolumeAdminTest):
|
||||
force_tenant_isolation = True
|
||||
|
||||
@classmethod
|
||||
def setup_credentials(cls):
|
||||
super(BaseVolumeQuotasNegativeV2TestJSON, cls).setup_credentials()
|
||||
super(BaseVolumeQuotasNegativeTestJSON, cls).setup_credentials()
|
||||
cls.demo_tenant_id = cls.os.credentials.tenant_id
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(BaseVolumeQuotasNegativeV2TestJSON, cls).resource_setup()
|
||||
super(BaseVolumeQuotasNegativeTestJSON, cls).resource_setup()
|
||||
cls.shared_quota_set = {'gigabytes': 2 * CONF.volume.volume_size,
|
||||
'volumes': 1}
|
||||
|
||||
|
@ -23,11 +23,11 @@ CONF = config.CONF
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class VolumeRetypeWithMigrationV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumeRetypeWithMigrationTest(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumeRetypeWithMigrationV2Test, cls).skip_checks()
|
||||
super(VolumeRetypeWithMigrationTest, cls).skip_checks()
|
||||
|
||||
if not CONF.volume_feature_enabled.multi_backend:
|
||||
raise cls.skipException("Cinder multi-backend feature disabled.")
|
||||
@ -38,7 +38,7 @@ class VolumeRetypeWithMigrationV2Test(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumeRetypeWithMigrationV2Test, cls).resource_setup()
|
||||
super(VolumeRetypeWithMigrationTest, cls).resource_setup()
|
||||
# read backend name from a list.
|
||||
backend_src = CONF.volume.backend_names[0]
|
||||
backend_dst = CONF.volume.backend_names[1]
|
||||
@ -73,7 +73,7 @@ class VolumeRetypeWithMigrationV2Test(base.BaseVolumeAdminTest):
|
||||
fetched_vol['id'])
|
||||
break
|
||||
|
||||
super(VolumeRetypeWithMigrationV2Test, cls).resource_cleanup()
|
||||
super(VolumeRetypeWithMigrationTest, cls).resource_cleanup()
|
||||
|
||||
@decorators.idempotent_id('a1a41f3f-9dad-493e-9f09-3ff197d477cd')
|
||||
def test_available_volume_retype_with_migration(self):
|
||||
|
@ -20,7 +20,7 @@ def _get_host(host):
|
||||
return host.split('@')[0]
|
||||
|
||||
|
||||
class VolumesServicesV2TestJSON(base.BaseVolumeAdminTest):
|
||||
class VolumesServicesTestJSON(base.BaseVolumeAdminTest):
|
||||
"""Tests Volume Services API.
|
||||
|
||||
volume service list requires admin privileges.
|
||||
@ -28,7 +28,7 @@ class VolumesServicesV2TestJSON(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesServicesV2TestJSON, cls).resource_setup()
|
||||
super(VolumesServicesTestJSON, cls).resource_setup()
|
||||
cls.services = (cls.admin_volume_services_client.list_services()
|
||||
['services'])
|
||||
# NOTE: Cinder service-list API returns the list contains
|
||||
|
@ -22,23 +22,23 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumeSnapshotQuotasNegativeV2TestJSON(base.BaseVolumeAdminTest):
|
||||
class VolumeSnapshotQuotasNegativeTestJSON(base.BaseVolumeAdminTest):
|
||||
force_tenant_isolation = True
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumeSnapshotQuotasNegativeV2TestJSON, cls).skip_checks()
|
||||
super(VolumeSnapshotQuotasNegativeTestJSON, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException('Cinder volume snapshots are disabled')
|
||||
|
||||
@classmethod
|
||||
def setup_credentials(cls):
|
||||
super(VolumeSnapshotQuotasNegativeV2TestJSON, cls).setup_credentials()
|
||||
super(VolumeSnapshotQuotasNegativeTestJSON, cls).setup_credentials()
|
||||
cls.demo_tenant_id = cls.os.credentials.tenant_id
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumeSnapshotQuotasNegativeV2TestJSON, cls).resource_setup()
|
||||
super(VolumeSnapshotQuotasNegativeTestJSON, cls).resource_setup()
|
||||
cls.default_volume_size = CONF.volume.volume_size
|
||||
cls.shared_quota_set = {'gigabytes': 3 * cls.default_volume_size,
|
||||
'volumes': 1, 'snapshots': 1}
|
||||
|
@ -22,7 +22,7 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumeTypesV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumeTypesTest(base.BaseVolumeAdminTest):
|
||||
|
||||
@decorators.idempotent_id('9d9b28e3-1b2e-4483-a2cc-24aa0ea1de54')
|
||||
def test_volume_type_list(self):
|
||||
|
@ -18,11 +18,11 @@ from tempest.lib import decorators
|
||||
from tempest.lib import exceptions as lib_exc
|
||||
|
||||
|
||||
class VolumeTypesExtraSpecsV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumeTypesExtraSpecsTest(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumeTypesExtraSpecsV2Test, cls).resource_setup()
|
||||
super(VolumeTypesExtraSpecsTest, cls).resource_setup()
|
||||
cls.volume_type = cls.create_volume_type()
|
||||
|
||||
@decorators.idempotent_id('b42923e9-0452-4945-be5b-d362ae533e60')
|
||||
|
@ -20,11 +20,11 @@ from tempest.lib import exceptions as lib_exc
|
||||
from tempest import test
|
||||
|
||||
|
||||
class ExtraSpecsNegativeV2Test(base.BaseVolumeAdminTest):
|
||||
class ExtraSpecsNegativeTest(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(ExtraSpecsNegativeV2Test, cls).resource_setup()
|
||||
super(ExtraSpecsNegativeTest, cls).resource_setup()
|
||||
extra_specs = {"spec1": "val1"}
|
||||
cls.volume_type = cls.create_volume_type(extra_specs=extra_specs)
|
||||
|
||||
|
@ -20,7 +20,7 @@ from tempest.lib import exceptions as lib_exc
|
||||
from tempest import test
|
||||
|
||||
|
||||
class VolumeTypesNegativeV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumeTypesNegativeTest(base.BaseVolumeAdminTest):
|
||||
|
||||
@test.attr(type=['negative'])
|
||||
@decorators.idempotent_id('b48c98f2-e662-4885-9b71-032256906314')
|
||||
|
@ -17,7 +17,7 @@ from tempest.api.volume import base
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class VolumesActionsV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumesActionsTest(base.BaseVolumeAdminTest):
|
||||
|
||||
def _create_reset_and_force_delete_temp_volume(self, status=None):
|
||||
# Create volume, reset volume status, and force delete temp volume
|
||||
|
@ -25,11 +25,11 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesBackupsAdminV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumesBackupsAdminTest(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesBackupsAdminV2Test, cls).skip_checks()
|
||||
super(VolumesBackupsAdminTest, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.backup:
|
||||
raise cls.skipException("Cinder backup feature disabled")
|
||||
|
||||
|
@ -19,7 +19,7 @@ from tempest.api.volume import base
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class BackendsCapabilitiesAdminV2TestsJSON(base.BaseVolumeAdminTest):
|
||||
class BackendsCapabilitiesAdminTestsJSON(base.BaseVolumeAdminTest):
|
||||
|
||||
CAPABILITIES = ('namespace',
|
||||
'vendor_name',
|
||||
@ -34,7 +34,7 @@ class BackendsCapabilitiesAdminV2TestsJSON(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(BackendsCapabilitiesAdminV2TestsJSON, cls).resource_setup()
|
||||
super(BackendsCapabilitiesAdminTestsJSON, cls).resource_setup()
|
||||
# Get host list, formation: host@backend-name
|
||||
cls.hosts = [
|
||||
pool['name'] for pool in
|
||||
|
@ -23,7 +23,7 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class SnapshotManageAdminV2Test(base.BaseVolumeAdminTest):
|
||||
class SnapshotManageAdminTest(base.BaseVolumeAdminTest):
|
||||
"""Unmanage & manage snapshots
|
||||
|
||||
This feature provides the ability to import/export volume snapshot
|
||||
|
@ -20,7 +20,7 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumePoolsAdminV2TestsJSON(base.BaseVolumeAdminTest):
|
||||
class VolumePoolsAdminTestsJSON(base.BaseVolumeAdminTest):
|
||||
def _assert_pools(self, with_detail=False):
|
||||
cinder_pools = self.admin_volume_client.show_pools(
|
||||
detail=with_detail)['pools']
|
||||
|
@ -23,13 +23,13 @@ from tempest.lib import exceptions as lib_exc
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumeTypesAccessV2Test(base.BaseVolumeAdminTest):
|
||||
class VolumeTypesAccessTest(base.BaseVolumeAdminTest):
|
||||
|
||||
credentials = ['primary', 'alt', 'admin']
|
||||
|
||||
@classmethod
|
||||
def setup_clients(cls):
|
||||
super(VolumeTypesAccessV2Test, cls).setup_clients()
|
||||
super(VolumeTypesAccessTest, cls).setup_clients()
|
||||
cls.alt_client = cls.os_alt.volumes_client
|
||||
|
||||
@decorators.idempotent_id('d4dd0027-835f-4554-a6e5-50903fb79184')
|
||||
|
@ -23,11 +23,11 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesListAdminV2TestJSON(base.BaseVolumeAdminTest):
|
||||
class VolumesListAdminTestJSON(base.BaseVolumeAdminTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesListAdminV2TestJSON, cls).resource_setup()
|
||||
super(VolumesListAdminTestJSON, cls).resource_setup()
|
||||
# Create 3 test volumes
|
||||
# NOTE(zhufl): When using pre-provisioned credentials, the project
|
||||
# may have volumes other than those created below.
|
||||
|
@ -17,12 +17,12 @@ from tempest.api.volume import base
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class AvailabilityZoneV2TestJSON(base.BaseVolumeTest):
|
||||
"""Tests Availability Zone V2 API List"""
|
||||
class AvailabilityZoneTestJSON(base.BaseVolumeTest):
|
||||
"""Tests Availability Zone API List"""
|
||||
|
||||
@classmethod
|
||||
def setup_clients(cls):
|
||||
super(AvailabilityZoneV2TestJSON, cls).setup_clients()
|
||||
super(AvailabilityZoneTestJSON, cls).setup_clients()
|
||||
cls.client = cls.availability_zone_client
|
||||
|
||||
@decorators.idempotent_id('01f1ae88-eba9-4c6b-a011-6f7ace06b725')
|
||||
|
@ -25,7 +25,7 @@ CONF = config.CONF
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class ExtensionsV2TestJSON(base.BaseVolumeTest):
|
||||
class ExtensionsTestJSON(base.BaseVolumeTest):
|
||||
|
||||
@decorators.idempotent_id('94607eb0-43a5-47ca-82aa-736b41bd2e2c')
|
||||
def test_list_extensions(self):
|
||||
|
@ -22,16 +22,16 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class SnapshotV2MetadataTestJSON(base.BaseVolumeTest):
|
||||
class SnapshotMetadataTestJSON(base.BaseVolumeTest):
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(SnapshotV2MetadataTestJSON, cls).skip_checks()
|
||||
super(SnapshotMetadataTestJSON, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException("Cinder snapshot feature disabled")
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(SnapshotV2MetadataTestJSON, cls).resource_setup()
|
||||
super(SnapshotMetadataTestJSON, cls).resource_setup()
|
||||
# Create a volume
|
||||
cls.volume = cls.create_volume()
|
||||
# Create a snapshot
|
||||
@ -41,7 +41,7 @@ class SnapshotV2MetadataTestJSON(base.BaseVolumeTest):
|
||||
# Update the metadata to {}
|
||||
self.snapshots_client.update_snapshot_metadata(
|
||||
self.snapshot['id'], metadata={})
|
||||
super(SnapshotV2MetadataTestJSON, self).tearDown()
|
||||
super(SnapshotMetadataTestJSON, self).tearDown()
|
||||
|
||||
@decorators.idempotent_id('a2f20f99-e363-4584-be97-bc33afb1a56c')
|
||||
def test_crud_snapshot_metadata(self):
|
||||
|
@ -21,14 +21,14 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class AbsoluteLimitsV2Tests(base.BaseVolumeTest):
|
||||
class AbsoluteLimitsTests(base.BaseVolumeTest):
|
||||
|
||||
# avoid existing volumes of pre-defined tenant
|
||||
force_tenant_isolation = True
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(AbsoluteLimitsV2Tests, cls).resource_setup()
|
||||
super(AbsoluteLimitsTests, cls).resource_setup()
|
||||
# Create a shared volume for tests
|
||||
cls.volume = cls.create_volume()
|
||||
|
||||
|
@ -19,18 +19,18 @@ from tempest.api.volume import base
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class VolumesV2MetadataTest(base.BaseVolumeTest):
|
||||
class VolumesMetadataTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2MetadataTest, cls).resource_setup()
|
||||
super(VolumesMetadataTest, cls).resource_setup()
|
||||
# Create a volume
|
||||
cls.volume = cls.create_volume()
|
||||
|
||||
def tearDown(self):
|
||||
# Update the metadata to {}
|
||||
self.volumes_client.update_volume_metadata(self.volume['id'], {})
|
||||
super(VolumesV2MetadataTest, self).tearDown()
|
||||
super(VolumesMetadataTest, self).tearDown()
|
||||
|
||||
@decorators.idempotent_id('6f5b125b-f664-44bf-910f-751591fe5769')
|
||||
def test_crud_volume_metadata(self):
|
||||
|
@ -20,13 +20,13 @@ from tempest.common import waiters
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class VolumesV2TransfersTest(base.BaseVolumeTest):
|
||||
class VolumesTransfersTest(base.BaseVolumeTest):
|
||||
|
||||
credentials = ['primary', 'alt', 'admin']
|
||||
|
||||
@classmethod
|
||||
def setup_clients(cls):
|
||||
super(VolumesV2TransfersTest, cls).setup_clients()
|
||||
super(VolumesTransfersTest, cls).setup_clients()
|
||||
|
||||
cls.client = cls.volumes_client
|
||||
cls.alt_client = cls.os_alt.volumes_client
|
||||
|
@ -25,11 +25,11 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2ActionsTest(base.BaseVolumeTest):
|
||||
class VolumesActionsTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def setup_clients(cls):
|
||||
super(VolumesV2ActionsTest, cls).setup_clients()
|
||||
super(VolumesActionsTest, cls).setup_clients()
|
||||
cls.client = cls.volumes_client
|
||||
if CONF.service_available.glance:
|
||||
# Check if glance v1 is available to determine which client to use.
|
||||
@ -44,7 +44,7 @@ class VolumesV2ActionsTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2ActionsTest, cls).resource_setup()
|
||||
super(VolumesActionsTest, cls).resource_setup()
|
||||
|
||||
# Create a test shared volume for attach/detach tests
|
||||
cls.volume = cls.create_volume()
|
||||
|
@ -26,11 +26,11 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesBackupsV2Test(base.BaseVolumeTest):
|
||||
class VolumesBackupsTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesBackupsV2Test, cls).skip_checks()
|
||||
super(VolumesBackupsTest, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.backup:
|
||||
raise cls.skipException("Cinder backup feature disabled")
|
||||
|
||||
|
@ -23,11 +23,11 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2CloneTest(base.BaseVolumeTest):
|
||||
class VolumesCloneTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2CloneTest, cls).skip_checks()
|
||||
super(VolumesCloneTest, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.clone:
|
||||
raise cls.skipException("Cinder volume clones are disabled")
|
||||
|
||||
|
@ -22,11 +22,11 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2CloneNegativeTest(base.BaseVolumeTest):
|
||||
class VolumesCloneNegativeTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2CloneNegativeTest, cls).skip_checks()
|
||||
super(VolumesCloneNegativeTest, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.clone:
|
||||
raise cls.skipException("Cinder volume clones are disabled")
|
||||
|
||||
|
@ -18,7 +18,7 @@ from tempest.common import waiters
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class VolumesV2ExtendTest(base.BaseVolumeTest):
|
||||
class VolumesExtendTest(base.BaseVolumeTest):
|
||||
|
||||
@decorators.idempotent_id('9a36df71-a257-43a5-9555-dc7c88e66e0e')
|
||||
def test_volume_extend(self):
|
||||
|
@ -26,7 +26,7 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2GetTest(base.BaseVolumeTest):
|
||||
class VolumesGetTest(base.BaseVolumeTest):
|
||||
|
||||
def _volume_create_get_update_delete(self, **kwargs):
|
||||
# Create a volume, Get it's details and Delete the volume
|
||||
|
@ -23,7 +23,7 @@ from tempest.lib import decorators
|
||||
from tempest import test
|
||||
|
||||
|
||||
class VolumesV2ListTestJSON(base.BaseVolumeTest):
|
||||
class VolumesListTestJSON(base.BaseVolumeTest):
|
||||
# NOTE: This test creates a number of 1G volumes. To run successfully,
|
||||
# ensure that the backing file for the volume group that Nova uses
|
||||
# has space for at least 3 1G volumes!
|
||||
@ -57,7 +57,7 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2ListTestJSON, cls).resource_setup()
|
||||
super(VolumesListTestJSON, cls).resource_setup()
|
||||
cls.name = cls.VOLUME_FIELDS[1]
|
||||
# Create 3 test volumes
|
||||
cls.volume_list = []
|
||||
|
@ -20,11 +20,11 @@ from tempest.lib import exceptions as lib_exc
|
||||
from tempest import test
|
||||
|
||||
|
||||
class VolumesV2NegativeTest(base.BaseVolumeTest):
|
||||
class VolumesNegativeTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2NegativeTest, cls).resource_setup()
|
||||
super(VolumesNegativeTest, cls).resource_setup()
|
||||
|
||||
# Create a test shared instance and volume for attach/detach tests
|
||||
cls.volume = cls.create_volume()
|
||||
|
@ -21,17 +21,17 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2SnapshotTestJSON(base.BaseVolumeTest):
|
||||
class VolumesSnapshotTestJSON(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2SnapshotTestJSON, cls).skip_checks()
|
||||
super(VolumesSnapshotTestJSON, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException("Cinder volume snapshots are disabled")
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2SnapshotTestJSON, cls).resource_setup()
|
||||
super(VolumesSnapshotTestJSON, cls).resource_setup()
|
||||
cls.volume_origin = cls.create_volume()
|
||||
|
||||
@decorators.idempotent_id('b467b54c-07a4-446d-a1cf-651dedcc3ff1')
|
||||
|
@ -17,17 +17,17 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2SnapshotListTestJSON(base.BaseVolumeTest):
|
||||
class VolumesSnapshotListTestJSON(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2SnapshotListTestJSON, cls).skip_checks()
|
||||
super(VolumesSnapshotListTestJSON, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException("Cinder volume snapshots are disabled")
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2SnapshotListTestJSON, cls).resource_setup()
|
||||
super(VolumesSnapshotListTestJSON, cls).resource_setup()
|
||||
volume_origin = cls.create_volume()
|
||||
# Create snapshots with params
|
||||
for _ in range(2):
|
||||
|
@ -20,11 +20,11 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2SnapshotNegativeTestJSON(base.BaseVolumeTest):
|
||||
class VolumesSnapshotNegativeTestJSON(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2SnapshotNegativeTestJSON, cls).skip_checks()
|
||||
super(VolumesSnapshotNegativeTestJSON, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException("Cinder volume snapshots are disabled")
|
||||
|
||||
|
@ -23,18 +23,18 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2ImageMetadata(base.BaseVolumeTest):
|
||||
class VolumesImageMetadata(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2ImageMetadata, cls).skip_checks()
|
||||
super(VolumesImageMetadata, cls).skip_checks()
|
||||
if not CONF.service_available.glance:
|
||||
skip_msg = ("%s skipped as Glance is not available" % cls.__name__)
|
||||
raise cls.skipException(skip_msg)
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2ImageMetadata, cls).resource_setup()
|
||||
super(VolumesImageMetadata, cls).resource_setup()
|
||||
# Create a volume from image ID
|
||||
cls.volume = cls.create_volume(imageRef=CONF.compute.image_ref)
|
||||
|
||||
|
@ -22,8 +22,8 @@ from tempest.api.volume import base
|
||||
from tempest.lib import decorators
|
||||
|
||||
|
||||
class VolumesV2ListTestJSON(base.BaseVolumeTest):
|
||||
"""volumes v2 specific tests.
|
||||
class VolumesListTestJSON(base.BaseVolumeTest):
|
||||
"""volumes tests.
|
||||
|
||||
This test creates a number of 1G volumes. To run successfully,
|
||||
ensure that the backing file for the volume group that Nova uses
|
||||
@ -34,7 +34,7 @@ class VolumesV2ListTestJSON(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2ListTestJSON, cls).resource_setup()
|
||||
super(VolumesListTestJSON, cls).resource_setup()
|
||||
|
||||
# Create 3 test volumes
|
||||
# NOTE(zhufl): When using pre-provisioned credentials, the project
|
||||
|
@ -20,17 +20,17 @@ from tempest.lib import decorators
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2SnapshotListTestJSON(base.BaseVolumeTest):
|
||||
class VolumesSnapshotListTestJSON(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2SnapshotListTestJSON, cls).skip_checks()
|
||||
super(VolumesSnapshotListTestJSON, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException("Cinder volume snapshots are disabled")
|
||||
|
||||
@classmethod
|
||||
def resource_setup(cls):
|
||||
super(VolumesV2SnapshotListTestJSON, cls).resource_setup()
|
||||
super(VolumesSnapshotListTestJSON, cls).resource_setup()
|
||||
cls.snapshot_id_list = []
|
||||
# Create a volume
|
||||
volume_origin = cls.create_volume()
|
||||
@ -46,7 +46,7 @@ class VolumesV2SnapshotListTestJSON(base.BaseVolumeTest):
|
||||
self.assertNotEmpty(snap_list)
|
||||
if sort_key is 'display_name':
|
||||
sort_key = 'name'
|
||||
# Note: On Cinder V2 API, 'display_name' works as a sort key
|
||||
# Note: On Cinder API, 'display_name' works as a sort key
|
||||
# on a request, a volume name appears as 'name' on the response.
|
||||
# So Tempest needs to change the key name here for this inconsistent
|
||||
# API behavior.
|
||||
|
@ -23,11 +23,11 @@ from tempest import test
|
||||
CONF = config.CONF
|
||||
|
||||
|
||||
class VolumesV2SnapshotNegativeTest(base.BaseVolumeTest):
|
||||
class VolumesSnapshotNegativeTest(base.BaseVolumeTest):
|
||||
|
||||
@classmethod
|
||||
def skip_checks(cls):
|
||||
super(VolumesV2SnapshotNegativeTest, cls).skip_checks()
|
||||
super(VolumesSnapshotNegativeTest, cls).skip_checks()
|
||||
if not CONF.volume_feature_enabled.snapshot:
|
||||
raise cls.skipException("Cinder volume snapshots are disabled")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user