diff options
author | Kiall Mac Innes <kiall@macinnes.ie> | 2016-04-21 15:15:49 +0100 |
---|---|---|
committer | Kiall Mac Innes <kiall@macinnes.ie> | 2016-04-21 15:15:49 +0100 |
commit | 954a08e51b4a1d07ca67d7fbb7c454bc0ba88cfb (patch) | |
tree | 50164cd13de02e66c197fb08bd383a625a97e87f /contrib | |
parent | 0fa168520d3ebb9bf989b1cb127a9b7fe06516e4 (diff) | |
download | designate-954a08e51b4a1d07ca67d7fbb7c454bc0ba88cfb.tar.gz |
Remove contrib/tempest, as they have moved to the tempest plugin
Change-Id: Id553e2aff03617ebe8021894889ccf5a50c2e5bd
Depends-On: Idc31c00c95fde96087f4f222ae9c17e554e6b1fc
Diffstat (limited to 'contrib')
20 files changed, 0 insertions, 3889 deletions
diff --git a/contrib/tempest/README.rst b/contrib/tempest/README.rst deleted file mode 100644 index ad23aeb7..00000000 --- a/contrib/tempest/README.rst +++ /dev/null @@ -1,72 +0,0 @@ -Designate API Testing using Tempest Framework. -============================================== - -This is a set of Designate API tests written for Tempest Framework -to be run against a live OpenStack cluster with Designate service -enabled. - -Configuration -------------- - -Detailed configuration of Designate tests and configuration files is -the scope of this document. - -Added all the required parameters in etc/tempest.conf.sample -to enable Designate service. - -The sample config file is auto generated using the script -(based on parameters added in config.py): -tools/generate_sample.sh - -To run Tempest, you first need to create a configuration file that will -tell Tempest where to find the designate service. - -The easiest way to create a configuration file is to copy the sample -(tempest.conf.sample) one in the etc/ directory. - - $> cd $TEMPEST_ROOT_DIR - $> cp etc/tempest.conf.sample etc/tempest.conf - -After that, open up the etc/tempest.conf file and edit the configuration -variables to match valid data in your environment. This includes your -Keystone endpoint, a valid user and credentials, and reference -data to be used in testing. - -Tests and Clients for Designate feature ---------------------------------------- - - 1> Added tests for Domains, Records, Servers of Designate API - under dns_tests folder. - - 2> Added respective supporting functions for Json Interface - under dns_clients folder. - - 3> Modified respective clients.py and config.py files with respect - to Designate service and should be placed under'tempest' folder. - - 4> Implemented Schema validation for all the Designate operations as per - current Tempest framework under dns_schema. - -Steps to execute Designate API tests. -------------------------------------- - -In order to run Designate API tests against Tempest Suite, all the above -test scripts and client files has to be placed in paths as mentioned below. - - 1> Clone Tempest - git clone https://github.com/openstack/tempest.git - - 2> Add the following files - $> cp tempest.conf.sample $TEMPEST_ROOT_DIR/tempest/etc - $> cp config.py TEMPEST_ROOT_DIR/tempest - $> cp clients.py TEMPEST_ROOT_DIR/tempest - $> cp -r dns_clients TEMPEST_ROOT_DIR/tempest/services/dns - $> cp -r dns_schema TEMPEST_ROOT_DIR/tempest/api_schema/dns - $> cp -r dns_tests TEMPEST_ROOT_DIR/tempest/api/dns - -After setting up your configuration files, you can execute the set of -designate tests by using testr. - $> testr run --parallel - -To run one single test - $> testr run --parallel tempest.api.dns.test_domains.DnsDomainsTest.test_list_domains diff --git a/contrib/tempest/clients.py b/contrib/tempest/clients.py deleted file mode 100644 index 6963b47f..00000000 --- a/contrib/tempest/clients.py +++ /dev/null @@ -1,706 +0,0 @@ -# Copyright 2012 OpenStack Foundation -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import keystoneclient.exceptions -import keystoneclient.v2_0.client -from tempest import auth -from tempest.common import rest_client -from tempest import config -from tempest import exceptions -from tempest import manager -from tempest.openstack.common import log as logging -from tempest.services.baremetal.v1.client_json import BaremetalClientJSON -from tempest.services import botoclients -from tempest.services.compute.json.agents_client import \ - AgentsClientJSON -from tempest.services.compute.json.aggregates_client import \ - AggregatesClientJSON -from tempest.services.compute.json.availability_zone_client import \ - AvailabilityZoneClientJSON -from tempest.services.compute.json.certificates_client import \ - CertificatesClientJSON -from tempest.services.compute.json.extensions_client import \ - ExtensionsClientJSON -from tempest.services.compute.json.fixed_ips_client import FixedIPsClientJSON -from tempest.services.compute.json.flavors_client import FlavorsClientJSON -from tempest.services.compute.json.floating_ips_client import \ - FloatingIPsClientJSON -from tempest.services.compute.json.hosts_client import HostsClientJSON -from tempest.services.compute.json.hypervisor_client import \ - HypervisorClientJSON -from tempest.services.compute.json.images_client import ImagesClientJSON -from tempest.services.compute.json.instance_usage_audit_log_client import \ - InstanceUsagesAuditLogClientJSON -from tempest.services.compute.json.interfaces_client import \ - InterfacesClientJSON -from tempest.services.compute.json.keypairs_client import KeyPairsClientJSON -from tempest.services.compute.json.limits_client import LimitsClientJSON -from tempest.services.compute.json.migrations_client import \ - MigrationsClientJSON -from tempest.services.compute.json.quotas_client import QuotasClientJSON -from tempest.services.compute.json.security_groups_client import \ - SecurityGroupsClientJSON -from tempest.services.compute.json.servers_client import ServersClientJSON -from tempest.services.compute.json.services_client import ServicesClientJSON -from tempest.services.compute.json.tenant_usages_client import \ - TenantUsagesClientJSON -from tempest.services.compute.json.volumes_extensions_client import \ - VolumesExtensionsClientJSON -from tempest.services.compute.v3.json.agents_client import AgentsV3ClientJSON -from tempest.services.compute.v3.json.aggregates_client import \ - AggregatesV3ClientJSON -from tempest.services.compute.v3.json.availability_zone_client import \ - AvailabilityZoneV3ClientJSON -from tempest.services.compute.v3.json.certificates_client import \ - CertificatesV3ClientJSON -from tempest.services.compute.v3.json.extensions_client import \ - ExtensionsV3ClientJSON -from tempest.services.compute.v3.json.flavors_client import FlavorsV3ClientJSON -from tempest.services.compute.v3.json.hosts_client import HostsV3ClientJSON -from tempest.services.compute.v3.json.hypervisor_client import \ - HypervisorV3ClientJSON -from tempest.services.compute.v3.json.interfaces_client import \ - InterfacesV3ClientJSON -from tempest.services.compute.v3.json.keypairs_client import \ - KeyPairsV3ClientJSON -from tempest.services.compute.v3.json.migration_client import \ - MigrationsV3ClientJSON -from tempest.services.compute.v3.json.quotas_client import \ - QuotasV3ClientJSON -from tempest.services.compute.v3.json.servers_client import \ - ServersV3ClientJSON -from tempest.services.compute.v3.json.services_client import \ - ServicesV3ClientJSON -from tempest.services.compute.v3.json.version_client import \ - VersionV3ClientJSON -from tempest.services.compute.xml.aggregates_client import AggregatesClientXML -from tempest.services.compute.xml.availability_zone_client import \ - AvailabilityZoneClientXML -from tempest.services.compute.xml.certificates_client import \ - CertificatesClientXML -from tempest.services.compute.xml.extensions_client import ExtensionsClientXML -from tempest.services.compute.xml.fixed_ips_client import FixedIPsClientXML -from tempest.services.compute.xml.flavors_client import FlavorsClientXML -from tempest.services.compute.xml.floating_ips_client import \ - FloatingIPsClientXML -from tempest.services.compute.xml.hosts_client import HostsClientXML -from tempest.services.compute.xml.hypervisor_client import HypervisorClientXML -from tempest.services.compute.xml.images_client import ImagesClientXML -from tempest.services.compute.xml.instance_usage_audit_log_client import \ - InstanceUsagesAuditLogClientXML -from tempest.services.compute.xml.interfaces_client import \ - InterfacesClientXML -from tempest.services.compute.xml.keypairs_client import KeyPairsClientXML -from tempest.services.compute.xml.limits_client import LimitsClientXML -from tempest.services.compute.xml.quotas_client import QuotasClientXML -from tempest.services.compute.xml.security_groups_client \ - import SecurityGroupsClientXML -from tempest.services.compute.xml.servers_client import ServersClientXML -from tempest.services.compute.xml.services_client import ServicesClientXML -from tempest.services.compute.xml.tenant_usages_client import \ - TenantUsagesClientXML -from tempest.services.compute.xml.volumes_extensions_client import \ - VolumesExtensionsClientXML -from tempest.services.data_processing.v1_1.client import DataProcessingClient -from tempest.services.database.json.flavors_client import \ - DatabaseFlavorsClientJSON -from tempest.services.database.json.versions_client import \ - DatabaseVersionsClientJSON -from tempest.services.dns.json.domains_client import DomainsClientJSON -from tempest.services.dns.json.records_client import RecordsClientJSON -from tempest.services.dns.json.server_client import ServerClientJSON -from tempest.services.identity.json.identity_client import IdentityClientJSON -from tempest.services.identity.json.identity_client import TokenClientJSON -from tempest.services.identity.v3.json.credentials_client import \ - CredentialsClientJSON -from tempest.services.identity.v3.json.endpoints_client import \ - EndPointClientJSON -from tempest.services.identity.v3.json.identity_client import \ - IdentityV3ClientJSON -from tempest.services.identity.v3.json.identity_client import V3TokenClientJSON -from tempest.services.identity.v3.json.policy_client import PolicyClientJSON -from tempest.services.identity.v3.json.service_client import \ - ServiceClientJSON -from tempest.services.identity.v3.xml.credentials_client import \ - CredentialsClientXML -from tempest.services.identity.v3.xml.endpoints_client import EndPointClientXML -from tempest.services.identity.v3.xml.identity_client import \ - IdentityV3ClientXML -from tempest.services.identity.v3.xml.identity_client import V3TokenClientXML -from tempest.services.identity.v3.xml.policy_client import PolicyClientXML -from tempest.services.identity.v3.xml.service_client import \ - ServiceClientXML -from tempest.services.identity.xml.identity_client import IdentityClientXML -from tempest.services.identity.xml.identity_client import TokenClientXML -from tempest.services.image.v1.json.image_client import ImageClientJSON -from tempest.services.image.v2.json.image_client import ImageClientV2JSON -from tempest.services.network.json.network_client import NetworkClientJSON -from tempest.services.network.xml.network_client import NetworkClientXML -from tempest.services.object_storage.account_client import AccountClient -from tempest.services.object_storage.account_client import \ - AccountClientCustomizedHeader -from tempest.services.object_storage.container_client import ContainerClient -from tempest.services.object_storage.object_client import ObjectClient -from tempest.services.object_storage.object_client import \ - ObjectClientCustomizedHeader -from tempest.services.orchestration.json.orchestration_client import \ - OrchestrationClient -from tempest.services.queuing.json.queuing_client import QueuingClientJSON -from tempest.services.telemetry.json.telemetry_client import \ - TelemetryClientJSON -from tempest.services.telemetry.xml.telemetry_client import \ - TelemetryClientXML -from tempest.services.volume.json.admin.volume_hosts_client import \ - VolumeHostsClientJSON -from tempest.services.volume.json.admin.volume_quotas_client import \ - VolumeQuotasClientJSON -from tempest.services.volume.json.admin.volume_services_client import \ - VolumesServicesClientJSON -from tempest.services.volume.json.admin.volume_types_client import \ - VolumeTypesClientJSON -from tempest.services.volume.json.backups_client import BackupsClientJSON -from tempest.services.volume.json.extensions_client import \ - ExtensionsClientJSON as VolumeExtensionClientJSON -from tempest.services.volume.json.snapshots_client import SnapshotsClientJSON -from tempest.services.volume.json.volumes_client import VolumesClientJSON -from tempest.services.volume.v2.json.volumes_client import VolumesV2ClientJSON -from tempest.services.volume.v2.xml.volumes_client import VolumesV2ClientXML -from tempest.services.volume.xml.admin.volume_hosts_client import \ - VolumeHostsClientXML -from tempest.services.volume.xml.admin.volume_quotas_client import \ - VolumeQuotasClientXML -from tempest.services.volume.xml.admin.volume_services_client import \ - VolumesServicesClientXML -from tempest.services.volume.xml.admin.volume_types_client import \ - VolumeTypesClientXML -from tempest.services.volume.xml.backups_client import BackupsClientXML -from tempest.services.volume.xml.extensions_client import \ - ExtensionsClientXML as VolumeExtensionClientXML -from tempest.services.volume.xml.snapshots_client import SnapshotsClientXML -from tempest.services.volume.xml.volumes_client import VolumesClientXML - -CONF = config.CONF -LOG = logging.getLogger(__name__) - - -class Manager(manager.Manager): - - """ - Top level manager for OpenStack tempest clients - """ - - def __init__(self, credentials=None, interface='json', service=None): - # Set interface and client type first - self.interface = interface - self.client_type = 'tempest' - # super cares for credentials validation - super(Manager, self).__init__(credentials=credentials) - - if self.interface == 'xml': - self.certificates_client = CertificatesClientXML( - self.auth_provider) - self.servers_client = ServersClientXML(self.auth_provider) - self.limits_client = LimitsClientXML(self.auth_provider) - self.images_client = ImagesClientXML(self.auth_provider) - self.keypairs_client = KeyPairsClientXML(self.auth_provider) - self.quotas_client = QuotasClientXML(self.auth_provider) - self.flavors_client = FlavorsClientXML(self.auth_provider) - self.extensions_client = ExtensionsClientXML(self.auth_provider) - self.volumes_extensions_client = VolumesExtensionsClientXML( - self.auth_provider) - self.floating_ips_client = FloatingIPsClientXML( - self.auth_provider) - self.backups_client = BackupsClientXML(self.auth_provider) - self.snapshots_client = SnapshotsClientXML(self.auth_provider) - self.volumes_client = VolumesClientXML(self.auth_provider) - self.volumes_v2_client = VolumesV2ClientXML(self.auth_provider) - self.volume_types_client = VolumeTypesClientXML( - self.auth_provider) - self.identity_client = IdentityClientXML(self.auth_provider) - self.identity_v3_client = IdentityV3ClientXML( - self.auth_provider) - self.security_groups_client = SecurityGroupsClientXML( - self.auth_provider) - self.interfaces_client = InterfacesClientXML(self.auth_provider) - self.endpoints_client = EndPointClientXML(self.auth_provider) - self.fixed_ips_client = FixedIPsClientXML(self.auth_provider) - self.availability_zone_client = AvailabilityZoneClientXML( - self.auth_provider) - self.service_client = ServiceClientXML(self.auth_provider) - self.volume_services_client = VolumesServicesClientXML( - self.auth_provider) - self.aggregates_client = AggregatesClientXML(self.auth_provider) - self.services_client = ServicesClientXML(self.auth_provider) - self.tenant_usages_client = TenantUsagesClientXML( - self.auth_provider) - self.policy_client = PolicyClientXML(self.auth_provider) - self.hosts_client = HostsClientXML(self.auth_provider) - self.hypervisor_client = HypervisorClientXML(self.auth_provider) - self.network_client = NetworkClientXML(self.auth_provider) - self.credentials_client = CredentialsClientXML( - self.auth_provider) - self.instance_usages_audit_log_client = \ - InstanceUsagesAuditLogClientXML(self.auth_provider) - self.volume_hosts_client = VolumeHostsClientXML( - self.auth_provider) - self.volume_quotas_client = VolumeQuotasClientXML( - self.auth_provider) - self.volumes_extension_client = VolumeExtensionClientXML( - self.auth_provider) - if CONF.service_available.ceilometer: - self.telemetry_client = TelemetryClientXML( - self.auth_provider) - self.token_client = TokenClientXML() - self.token_v3_client = V3TokenClientXML() - - elif self.interface == 'json': - self.certificates_client = CertificatesClientJSON( - self.auth_provider) - self.certificates_v3_client = CertificatesV3ClientJSON( - self.auth_provider) - self.baremetal_client = BaremetalClientJSON(self.auth_provider) - self.servers_client = ServersClientJSON(self.auth_provider) - self.servers_v3_client = ServersV3ClientJSON(self.auth_provider) - self.limits_client = LimitsClientJSON(self.auth_provider) - self.images_client = ImagesClientJSON(self.auth_provider) - self.keypairs_v3_client = KeyPairsV3ClientJSON( - self.auth_provider) - self.keypairs_client = KeyPairsClientJSON(self.auth_provider) - self.keypairs_v3_client = KeyPairsV3ClientJSON( - self.auth_provider) - self.quotas_client = QuotasClientJSON(self.auth_provider) - self.quotas_v3_client = QuotasV3ClientJSON(self.auth_provider) - self.flavors_client = FlavorsClientJSON(self.auth_provider) - self.flavors_v3_client = FlavorsV3ClientJSON(self.auth_provider) - self.extensions_v3_client = ExtensionsV3ClientJSON( - self.auth_provider) - self.extensions_client = ExtensionsClientJSON( - self.auth_provider) - self.volumes_extensions_client = VolumesExtensionsClientJSON( - self.auth_provider) - self.floating_ips_client = FloatingIPsClientJSON( - self.auth_provider) - self.backups_client = BackupsClientJSON(self.auth_provider) - self.snapshots_client = SnapshotsClientJSON(self.auth_provider) - self.volumes_client = VolumesClientJSON(self.auth_provider) - self.volumes_v2_client = VolumesV2ClientJSON(self.auth_provider) - self.volume_types_client = VolumeTypesClientJSON( - self.auth_provider) - self.identity_client = IdentityClientJSON(self.auth_provider) - self.identity_v3_client = IdentityV3ClientJSON( - self.auth_provider) - self.security_groups_client = SecurityGroupsClientJSON( - self.auth_provider) - self.interfaces_v3_client = InterfacesV3ClientJSON( - self.auth_provider) - self.interfaces_client = InterfacesClientJSON( - self.auth_provider) - self.endpoints_client = EndPointClientJSON(self.auth_provider) - self.fixed_ips_client = FixedIPsClientJSON(self.auth_provider) - self.availability_zone_v3_client = AvailabilityZoneV3ClientJSON( - self.auth_provider) - self.availability_zone_client = AvailabilityZoneClientJSON( - self.auth_provider) - self.services_v3_client = ServicesV3ClientJSON( - self.auth_provider) - self.service_client = ServiceClientJSON(self.auth_provider) - self.volume_services_client = VolumesServicesClientJSON( - self.auth_provider) - self.agents_v3_client = AgentsV3ClientJSON(self.auth_provider) - self.aggregates_v3_client = AggregatesV3ClientJSON( - self.auth_provider) - self.aggregates_client = AggregatesClientJSON( - self.auth_provider) - self.services_client = ServicesClientJSON(self.auth_provider) - self.tenant_usages_client = TenantUsagesClientJSON( - self.auth_provider) - self.version_v3_client = VersionV3ClientJSON(self.auth_provider) - self.migrations_v3_client = MigrationsV3ClientJSON( - self.auth_provider) - self.policy_client = PolicyClientJSON(self.auth_provider) - self.hosts_client = HostsClientJSON(self.auth_provider) - self.hypervisor_v3_client = HypervisorV3ClientJSON( - self.auth_provider) - self.hypervisor_client = HypervisorClientJSON( - self.auth_provider) - self.network_client = NetworkClientJSON(self.auth_provider) - self.credentials_client = CredentialsClientJSON( - self.auth_provider) - self.instance_usages_audit_log_client = \ - InstanceUsagesAuditLogClientJSON(self.auth_provider) - self.volume_hosts_client = VolumeHostsClientJSON( - self.auth_provider) - self.volume_quotas_client = VolumeQuotasClientJSON( - self.auth_provider) - self.volumes_extension_client = VolumeExtensionClientJSON( - self.auth_provider) - self.hosts_v3_client = HostsV3ClientJSON(self.auth_provider) - self.database_flavors_client = DatabaseFlavorsClientJSON( - self.auth_provider) - self.database_versions_client = DatabaseVersionsClientJSON( - self.auth_provider) - self.dns_domains_client = DomainsClientJSON(self.auth_provider) - self.dns_servers_client = ServerClientJSON(self.auth_provider) - self.dns_records_client = RecordsClientJSON(self.auth_provider) - self.queuing_client = QueuingClientJSON(self.auth_provider) - if CONF.service_available.ceilometer: - self.telemetry_client = TelemetryClientJSON( - self.auth_provider) - self.token_client = TokenClientJSON() - self.token_v3_client = V3TokenClientJSON() - self.negative_client = rest_client.NegativeRestClient( - self.auth_provider) - self.negative_client.service = service - - else: - msg = "Unsupported interface type `%s'" % interface - raise exceptions.InvalidConfiguration(msg) - - # TODO(andreaf) EC2 client still do their auth, v2 only - ec2_client_args = (self.credentials.username, - self.credentials.password, - CONF.identity.uri, - self.credentials.tenant_name) - - # common clients - self.account_client = AccountClient(self.auth_provider) - self.agents_client = AgentsClientJSON(self.auth_provider) - if CONF.service_available.glance: - self.image_client = ImageClientJSON(self.auth_provider) - self.image_client_v2 = ImageClientV2JSON(self.auth_provider) - self.container_client = ContainerClient(self.auth_provider) - self.object_client = ObjectClient(self.auth_provider) - self.orchestration_client = OrchestrationClient( - self.auth_provider) - self.ec2api_client = botoclients.APIClientEC2(*ec2_client_args) - self.s3_client = botoclients.ObjectClientS3(*ec2_client_args) - self.custom_object_client = ObjectClientCustomizedHeader( - self.auth_provider) - self.custom_account_client = \ - AccountClientCustomizedHeader(self.auth_provider) - self.data_processing_client = DataProcessingClient( - self.auth_provider) - self.migrations_client = MigrationsClientJSON(self.auth_provider) - - -class AltManager(Manager): - - """ - Manager object that uses the alt_XXX credentials for its - managed client objects - """ - - def __init__(self, interface='json', service=None): - super(AltManager, self).__init__( - credentials=auth.get_default_credentials('alt_user'), - interface=interface, - service=service) - - -class AdminManager(Manager): - - """ - Manager object that uses the admin credentials for its - managed client objects - """ - - def __init__(self, interface='json', service=None): - super(AdminManager, self).__init__( - credentials=auth.get_default_credentials('identity_admin'), - interface=interface, - service=service) - - -class ComputeAdminManager(Manager): - - """ - Manager object that uses the compute_admin credentials for its - managed client objects - """ - - def __init__(self, interface='json', service=None): - base = super(ComputeAdminManager, self) - base.__init__( - credentials=auth.get_default_credentials('compute_admin'), - interface=interface, - service=service) - - -class DnsAdminManager(Manager): - - """ - Manager object that uses the dns_admin credentials for its - managed client objects - """ - - def __init__(self, interface='json', service=None): - base = super(DnsAdminManager, self) - base.__init__( - credentials=auth.get_default_credentials('dns_admin'), - interface=interface, - service=service) - - -class OfficialClientManager(manager.Manager): - """ - Manager that provides access to the official python clients for - calling various OpenStack APIs. - """ - - NOVACLIENT_VERSION = '2' - CINDERCLIENT_VERSION = '1' - HEATCLIENT_VERSION = '1' - IRONICCLIENT_VERSION = '1' - SAHARACLIENT_VERSION = '1.1' - - def __init__(self, credentials): - # FIXME(andreaf) Auth provider for client_type 'official' is - # not implemented yet, setting to 'tempest' for now. - self.client_type = 'tempest' - self.interface = None - # super cares for credentials validation - super(OfficialClientManager, self).__init__(credentials=credentials) - self.baremetal_client = self._get_baremetal_client() - self.compute_client = self._get_compute_client(credentials) - self.identity_client = self._get_identity_client(credentials) - self.image_client = self._get_image_client() - self.network_client = self._get_network_client() - self.volume_client = self._get_volume_client(credentials) - self.object_storage_client = self._get_object_storage_client( - credentials) - self.orchestration_client = self._get_orchestration_client( - credentials) - self.data_processing_client = self._get_data_processing_client( - credentials) - - def _get_roles(self): - admin_credentials = auth.get_default_credentials('identity_admin') - keystone_admin = self._get_identity_client(admin_credentials) - - username = self.credentials.username - tenant_name = self.credentials.tenant_name - user_id = keystone_admin.users.find(name=username).id - tenant_id = keystone_admin.tenants.find(name=tenant_name).id - - roles = keystone_admin.roles.roles_for_user( - user=user_id, tenant=tenant_id) - - return [r.name for r in roles] - - def _get_compute_client(self, credentials): - # Novaclient will not execute operations for anyone but the - # identified user, so a new client needs to be created for - # each user that operations need to be performed for. - if not CONF.service_available.nova: - return None - import novaclient.client - - auth_url = CONF.identity.uri - dscv = CONF.identity.disable_ssl_certificate_validation - region = CONF.identity.region - - client_args = (credentials.username, credentials.password, - credentials.tenant_name, auth_url) - - # Create our default Nova client to use in testing - service_type = CONF.compute.catalog_type - endpoint_type = CONF.compute.endpoint_type - return novaclient.client.Client(self.NOVACLIENT_VERSION, - *client_args, - service_type=service_type, - endpoint_type=endpoint_type, - region_name=region, - no_cache=True, - insecure=dscv, - http_log_debug=True) - - def _get_image_client(self): - if not CONF.service_available.glance: - return None - import glanceclient - token = self.identity_client.auth_token - region = CONF.identity.region - endpoint_type = CONF.image.endpoint_type - endpoint = self.identity_client.service_catalog.url_for( - attr='region', filter_value=region, - service_type=CONF.image.catalog_type, endpoint_type=endpoint_type) - dscv = CONF.identity.disable_ssl_certificate_validation - return glanceclient.Client('1', endpoint=endpoint, token=token, - insecure=dscv) - - def _get_volume_client(self, credentials): - if not CONF.service_available.cinder: - return None - import cinderclient.client - auth_url = CONF.identity.uri - region = CONF.identity.region - endpoint_type = CONF.volume.endpoint_type - dscv = CONF.identity.disable_ssl_certificate_validation - return cinderclient.client.Client(self.CINDERCLIENT_VERSION, - credentials.username, - credentials.password, - credentials.tenant_name, - auth_url, - region_name=region, - endpoint_type=endpoint_type, - insecure=dscv, - http_log_debug=True) - - def _get_object_storage_client(self, credentials): - if not CONF.service_available.swift: - return None - import swiftclient - auth_url = CONF.identity.uri - # add current tenant to swift operator role group. - admin_credentials = auth.get_default_credentials('identity_admin') - keystone_admin = self._get_identity_client(admin_credentials) - - # enable test user to operate swift by adding operator role to him. - roles = keystone_admin.roles.list() - operator_role = CONF.object_storage.operator_role - member_role = [role for role in roles if role.name == operator_role][0] - # NOTE(maurosr): This is surrounded in the try-except block cause - # neutron tests doesn't have tenant isolation. - try: - keystone_admin.roles.add_user_role(self.identity_client.user_id, - member_role.id, - self.identity_client.tenant_id) - except keystoneclient.exceptions.Conflict: - pass - - endpoint_type = CONF.object_storage.endpoint_type - os_options = {'endpoint_type': endpoint_type} - return swiftclient.Connection(auth_url, credentials.username, - credentials.password, - tenant_name=credentials.tenant_name, - auth_version='2', - os_options=os_options) - - def _get_orchestration_client(self, credentials): - if not CONF.service_available.heat: - return None - import heatclient.client - - keystone = self._get_identity_client(credentials) - region = CONF.identity.region - endpoint_type = CONF.orchestration.endpoint_type - token = keystone.auth_token - service_type = CONF.orchestration.catalog_type - try: - endpoint = keystone.service_catalog.url_for( - attr='region', - filter_value=region, - service_type=service_type, - endpoint_type=endpoint_type) - except keystoneclient.exceptions.EndpointNotFound: - return None - else: - return heatclient.client.Client(self.HEATCLIENT_VERSION, - endpoint, - token=token, - username=credentials.username, - password=credentials.password) - - def _get_identity_client(self, credentials): - # This identity client is not intended to check the security - # of the identity service, so use admin credentials by default. - - auth_url = CONF.identity.uri - dscv = CONF.identity.disable_ssl_certificate_validation - - return keystoneclient.v2_0.client.Client( - username=credentials.username, - password=credentials.password, - tenant_name=credentials.tenant_name, - auth_url=auth_url, - insecure=dscv) - - def _get_baremetal_client(self): - # ironic client is currently intended to by used by admin users - if not CONF.service_available.ironic: - return None - import ironicclient.client - roles = self._get_roles() - if CONF.identity.admin_role not in roles: - return None - - auth_url = CONF.identity.uri - api_version = self.IRONICCLIENT_VERSION - insecure = CONF.identity.disable_ssl_certificate_validation - service_type = CONF.baremetal.catalog_type - endpoint_type = CONF.baremetal.endpoint_type - creds = { - 'os_username': self.credentials.username, - 'os_password': self.credentials.password, - 'os_tenant_name': self.credentials.tenant_name - } - - try: - return ironicclient.client.get_client( - api_version=api_version, - os_auth_url=auth_url, - insecure=insecure, - os_service_type=service_type, - os_endpoint_type=endpoint_type, - **creds) - except keystoneclient.exceptions.EndpointNotFound: - return None - - def _get_network_client(self): - # The intended configuration is for the network client to have - # admin privileges and indicate for whom resources are being - # created via a 'tenant_id' parameter. This will often be - # preferable to authenticating as a specific user because - # working with certain resources (public routers and networks) - # often requires admin privileges anyway. - if not CONF.service_available.neutron: - return None - import neutronclient.v2_0.client - - credentials = auth.get_default_credentials('identity_admin') - - auth_url = CONF.identity.uri - dscv = CONF.identity.disable_ssl_certificate_validation - endpoint_type = CONF.network.endpoint_type - - return neutronclient.v2_0.client.Client( - username=credentials.username, - password=credentials.password, - tenant_name=credentials.tenant_name, - endpoint_type=endpoint_type, - auth_url=auth_url, - insecure=dscv) - - def _get_data_processing_client(self, credentials): - if not CONF.service_available.sahara: - # Sahara isn't available - return None - - import saharaclient.client - - endpoint_type = CONF.data_processing.endpoint_type - catalog_type = CONF.data_processing.catalog_type - auth_url = CONF.identity.uri - - client = saharaclient.client.Client( - self.SAHARACLIENT_VERSION, - credentials.username, - credentials.password, - project_name=credentials.tenant_name, - endpoint_type=endpoint_type, - service_type=catalog_type, - auth_url=auth_url) - - return client diff --git a/contrib/tempest/config.py b/contrib/tempest/config.py deleted file mode 100644 index d4df0d7e..00000000 --- a/contrib/tempest/config.py +++ /dev/null @@ -1,1076 +0,0 @@ -# Copyright 2012 OpenStack Foundation -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -from __future__ import print_function - -import logging as std_logging -import os - -from oslo_config import cfg -from tempest.openstack.common import log as logging - - -def register_opt_group(conf, opt_group, options): - conf.register_group(opt_group) - for opt in options: - conf.register_opt(opt, group=opt_group.name) - - -identity_group = cfg.OptGroup(name='identity', - title="Keystone Configuration Options") - -IdentityGroup = [ - cfg.StrOpt('catalog_type', - default='identity', - help="Catalog type of the Identity service."), - cfg.BoolOpt('disable_ssl_certificate_validation', - default=False, - help="Set to True if using self-signed SSL certificates."), - cfg.StrOpt('uri', - help="Full URI of the OpenStack Identity API (Keystone), v2"), - cfg.StrOpt('uri_v3', - help='Full URI of the OpenStack Identity API (Keystone), v3'), - cfg.StrOpt('auth_version', - default='v2', - help="Identity API version to be used for authentication " - "for API tests."), - cfg.StrOpt('region', - default='RegionOne', - help="The identity region name to use. Also used as the other " - "services' region name unless they are set explicitly. " - "If no such region is found in the service catalog, the " - "first found one is used."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the identity service."), - cfg.StrOpt('username', - help="Username to use for Nova API requests."), - cfg.StrOpt('tenant_name', - help="Tenant name to use for Nova API requests."), - cfg.StrOpt('admin_role', - default='admin', - help="Role required to administrate keystone."), - cfg.StrOpt('password', - help="API key to use when authenticating.", - secret=True), - cfg.StrOpt('domain_name', - help="Domain name for authentication (Keystone V3)." - "The same domain applies to user and project"), - cfg.StrOpt('alt_username', - help="Username of alternate user to use for Nova API " - "requests."), - cfg.StrOpt('alt_tenant_name', - help="Alternate user's Tenant name to use for Nova API " - "requests."), - cfg.StrOpt('alt_password', - help="API key to use when authenticating as alternate user.", - secret=True), - cfg.StrOpt('alt_domain_name', - help="Alternate domain name for authentication (Keystone V3)." - "The same domain applies to user and project"), - cfg.StrOpt('admin_username', - help="Administrative Username to use for " - "Keystone API requests."), - cfg.StrOpt('admin_tenant_name', - help="Administrative Tenant name to use for Keystone API " - "requests."), - cfg.StrOpt('admin_password', - help="API key to use when authenticating as admin.", - secret=True), - cfg.StrOpt('admin_domain_name', - help="Admin domain name for authentication (Keystone V3)." - "The same domain applies to user and project"), -] - -identity_feature_group = cfg.OptGroup(name='identity-feature-enabled', - title='Enabled Identity Features') - -IdentityFeatureGroup = [ - cfg.BoolOpt('trust', - default=True, - help='Does the identity service have delegation and ' - 'impersonation enabled'), - cfg.BoolOpt('api_v2', - default=True, - help='Is the v2 identity API enabled'), - cfg.BoolOpt('api_v3', - default=True, - help='Is the v3 identity API enabled'), -] - -compute_group = cfg.OptGroup(name='compute', - title='Compute Service Options') - -ComputeGroup = [ - cfg.BoolOpt('allow_tenant_isolation', - default=False, - help="Allows test cases to create/destroy tenants and " - "users. This option enables isolated test cases and " - "better parallel execution, but also requires that " - "OpenStack Identity API admin credentials are known."), - cfg.StrOpt('image_ref', - default="{$IMAGE_ID}", - help="Valid primary image reference to be used in tests."), - cfg.StrOpt('image_ref_alt', - default="{$IMAGE_ID_ALT}", - help="Valid secondary image reference to be used in tests."), - cfg.StrOpt('flavor_ref', - default="1", - help="Valid primary flavor to use in tests."), - cfg.StrOpt('flavor_ref_alt', - default="2", - help='Valid secondary flavor to be used in tests.'), - cfg.StrOpt('image_ssh_user', - default="root", - help="User name used to authenticate to an instance."), - cfg.StrOpt('image_ssh_password', - default="password", - help="Password used to authenticate to an instance."), - cfg.StrOpt('image_alt_ssh_user', - default="root", - help="User name used to authenticate to an instance using " - "the alternate image."), - cfg.StrOpt('image_alt_ssh_password', - default="password", - help="Password used to authenticate to an instance using " - "the alternate image."), - cfg.IntOpt('build_interval', - default=10, - help="Time in seconds between build status checks."), - cfg.IntOpt('build_timeout', - default=300, - help="Timeout in seconds to wait for an instance to build."), - cfg.BoolOpt('run_ssh', - default=False, - help="Should the tests ssh to instances?"), - cfg.StrOpt('ssh_auth_method', - default='keypair', - help="Auth method used for authenticate to the instance. " - "Valid choices are: keypair, configured, adminpass. " - "keypair: start the servers with an ssh keypair. " - "configured: use the configured user and password. " - "adminpass: use the injected adminPass. " - "disabled: avoid using ssh when it is an option."), - cfg.StrOpt('ssh_connect_method', - default='fixed', - help="How to connect to the instance? " - "fixed: using the first ip belongs the fixed network " - "floating: creating and using a floating ip"), - cfg.StrOpt('ssh_user', - default='root', - help="User name used to authenticate to an instance."), - cfg.IntOpt('ping_timeout', - default=120, - help="Timeout in seconds to wait for ping to " - "succeed."), - cfg.IntOpt('ssh_timeout', - default=300, - help="Timeout in seconds to wait for authentication to " - "succeed."), - cfg.IntOpt('ready_wait', - default=0, - help="Additional wait time for clean state, when there is " - "no OS-EXT-STS extension available"), - cfg.IntOpt('ssh_channel_timeout', - default=60, - help="Timeout in seconds to wait for output from ssh " - "channel."), - cfg.StrOpt('fixed_network_name', - default='private', - help="Visible fixed network name "), - cfg.StrOpt('network_for_ssh', - default='public', - help="Network used for SSH connections."), - cfg.IntOpt('ip_version_for_ssh', - default=4, - help="IP version used for SSH connections."), - cfg.BoolOpt('use_floatingip_for_ssh', - default=True, - help="Does SSH use Floating IPs?"), - cfg.StrOpt('catalog_type', - default='compute', - help="Catalog type of the Compute service."), - cfg.StrOpt('region', - default='', - help="The compute region name to use. If empty, the value " - "of identity.region is used instead. If no such region " - "is found in the service catalog, the first found one is " - "used."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the compute service."), - cfg.StrOpt('catalog_v3_type', - default='computev3', - help="Catalog type of the Compute v3 service."), - cfg.StrOpt('path_to_private_key', - help="Path to a private key file for SSH access to remote " - "hosts"), - cfg.StrOpt('volume_device_name', - default='vdb', - help="Expected device name when a volume is attached to " - "an instance"), - cfg.IntOpt('shelved_offload_time', - default=0, - help='Time in seconds before a shelved instance is eligible ' - 'for removing from a host. -1 never offload, 0 offload ' - 'when shelved. This time should be the same as the time ' - 'of nova.conf, and some tests will run for as long as the ' - 'time.') -] - -compute_features_group = cfg.OptGroup(name='compute-feature-enabled', - title="Enabled Compute Service Features") - -ComputeFeaturesGroup = [ - cfg.BoolOpt('api_v3', - default=True, - help="If false, skip all nova v3 tests."), - cfg.BoolOpt('disk_config', - default=True, - help="If false, skip disk config tests"), - cfg.ListOpt('api_extensions', - default=['all'], - help='A list of enabled compute extensions with a special ' - 'entry all which indicates every extension is enabled'), - cfg.ListOpt('api_v3_extensions', - default=['all'], - help='A list of enabled v3 extensions with a special entry all' - ' which indicates every extension is enabled'), - cfg.BoolOpt('change_password', - default=False, - help="Does the test environment support changing the admin " - "password?"), - cfg.BoolOpt('resize', - default=False, - help="Does the test environment support resizing?"), - cfg.BoolOpt('pause', - default=True, - help="Does the test environment support pausing?"), - cfg.BoolOpt('suspend', - default=True, - help="Does the test environment support suspend/resume?"), - cfg.BoolOpt('live_migration', - default=False, - help="Does the test environment support live migration " - "available?"), - cfg.BoolOpt('block_migration_for_live_migration', - default=False, - help="Does the test environment use block devices for live " - "migration"), - cfg.BoolOpt('block_migrate_cinder_iscsi', - default=False, - help="Does the test environment block migration support " - "cinder iSCSI volumes"), - cfg.BoolOpt('vnc_console', - default=False, - help='Enable VNC console. This configuration value should ' - 'be same as [nova.vnc]->vnc_enabled in nova.conf'), - cfg.BoolOpt('spice_console', - default=False, - help='Enable Spice console. This configuration value should ' - 'be same as [nova.spice]->enabled in nova.conf'), - cfg.BoolOpt('rdp_console', - default=False, - help='Enable RDP console. This configuration value should ' - 'be same as [nova.rdp]->enabled in nova.conf') -] - - -compute_admin_group = cfg.OptGroup(name='compute-admin', - title="Compute Admin Options") - -ComputeAdminGroup = [ - cfg.StrOpt('username', - help="Administrative Username to use for Nova API requests."), - cfg.StrOpt('tenant_name', - help="Administrative Tenant name to use for Nova API " - "requests."), - cfg.StrOpt('password', - help="API key to use when authenticating as admin.", - secret=True), - cfg.StrOpt('domain_name', - help="Zone name for authentication as admin (Keystone V3)." - "The same domain applies to user and project"), -] - -image_group = cfg.OptGroup(name='image', - title="Image Service Options") - -ImageGroup = [ - cfg.StrOpt('catalog_type', - default='image', - help='Catalog type of the Image service.'), - cfg.StrOpt('region', - default='', - help="The image region name to use. If empty, the value " - "of identity.region is used instead. If no such region " - "is found in the service catalog, the first found one is " - "used."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the image service."), - cfg.StrOpt('http_image', - default='http://download.cirros-cloud.net/0.3.1/' - 'cirros-0.3.1-x86_64-uec.tar.gz', - help='http accessible image') -] - -image_feature_group = cfg.OptGroup(name='image-feature-enabled', - title='Enabled image service features') - -ImageFeaturesGroup = [ - cfg.BoolOpt('api_v2', - default=True, - help="Is the v2 image API enabled"), - cfg.BoolOpt('api_v1', - default=True, - help="Is the v1 image API enabled"), -] - -network_group = cfg.OptGroup(name='network', - title='Network Service Options') - -NetworkGroup = [ - cfg.StrOpt('catalog_type', - default='network', - help='Catalog type of the Neutron service.'), - cfg.StrOpt('region', - default='', - help="The network region name to use. If empty, the value " - "of identity.region is used instead. If no such region " - "is found in the service catalog, the first found one is " - "used."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the network service."), - cfg.StrOpt('tenant_network_cidr', - default="10.100.0.0/16", - help="The cidr block to allocate tenant ipv4 subnets from"), - cfg.IntOpt('tenant_network_mask_bits', - default=28, - help="The mask bits for tenant ipv4 subnets"), - cfg.StrOpt('tenant_network_v6_cidr', - default="2003::/64", - help="The cidr block to allocate tenant ipv6 subnets from"), - cfg.IntOpt('tenant_network_v6_mask_bits', - default=96, - help="The mask bits for tenant ipv6 subnets"), - cfg.BoolOpt('tenant_networks_reachable', - default=False, - help="Whether tenant network connectivity should be " - "evaluated directly"), - cfg.StrOpt('public_network_id', - default="", - help="Id of the public network that provides external " - "connectivity"), - cfg.StrOpt('public_router_id', - default="", - help="Id of the public router that provides external " - "connectivity"), - cfg.IntOpt('build_timeout', - default=300, - help="Timeout in seconds to wait for network operation to " - "complete."), - cfg.IntOpt('build_interval', - default=10, - help="Time in seconds between network operation status " - "checks."), -] - -network_feature_group = cfg.OptGroup(name='network-feature-enabled', - title='Enabled network service features') - -NetworkFeaturesGroup = [ - cfg.BoolOpt('ipv6', - default=True, - help="Allow the execution of IPv6 tests"), - cfg.ListOpt('api_extensions', - default=['all'], - help='A list of enabled network extensions with a special ' - 'entry all which indicates every extension is enabled'), -] - -queuing_group = cfg.OptGroup(name='queuing', - title='Queuing Service') - -QueuingGroup = [ - cfg.StrOpt('catalog_type', - default='queuing', - help='Catalog type of the Queuing service.'), -] - -volume_group = cfg.OptGroup(name='volume', - title='Block Storage Options') - -VolumeGroup = [ - cfg.IntOpt('build_interval', - default=10, - help='Time in seconds between volume availability checks.'), - cfg.IntOpt('build_timeout', - default=300, - help='Timeout in seconds to wait for a volume to become' - 'available.'), - cfg.StrOpt('catalog_type', - default='volume', - help="Catalog type of the Volume Service"), - cfg.StrOpt('region', - default='', - help="The volume region name to use. If empty, the value " - "of identity.region is used instead. If no such region " - "is found in the service catalog, the first found one is " - "used."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the volume service."), - cfg.StrOpt('backend1_name', - default='BACKEND_1', - help="Name of the backend1 (must be declared in cinder.conf)"), - cfg.StrOpt('backend2_name', - default='BACKEND_2', - help="Name of the backend2 (must be declared in cinder.conf)"), - cfg.StrOpt('storage_protocol', - default='iSCSI', - help='Backend protocol to target when creating volume types'), - cfg.StrOpt('vendor_name', - default='Open Source', - help='Backend vendor to target when creating volume types'), - cfg.StrOpt('disk_format', - default='raw', - help='Disk format to use when copying a volume to image'), - cfg.IntOpt('volume_size', - default=1, - help='Default size in GB for volumes created by volumes tests'), -] - -volume_feature_group = cfg.OptGroup(name='volume-feature-enabled', - title='Enabled Cinder Features') - -VolumeFeaturesGroup = [ - cfg.BoolOpt('multi_backend', - default=False, - help="Runs Cinder multi-backend test (requires 2 backends)"), - cfg.BoolOpt('backup', - default=True, - help='Runs Cinder volumes backup test'), - cfg.BoolOpt('snapshot', - default=True, - help='Runs Cinder volume snapshot test'), - cfg.ListOpt('api_extensions', - default=['all'], - help='A list of enabled volume extensions with a special ' - 'entry all which indicates every extension is enabled'), - cfg.BoolOpt('api_v1', - default=True, - help="Is the v1 volume API enabled"), - cfg.BoolOpt('api_v2', - default=True, - help="Is the v2 volume API enabled"), -] - - -object_storage_group = cfg.OptGroup(name='object-storage', - title='Object Storage Service Options') - -ObjectStoreGroup = [ - cfg.StrOpt('catalog_type', - default='object-store', - help="Catalog type of the Object-Storage service."), - cfg.StrOpt('region', - default='', - help="The object-storage region name to use. If empty, the " - "value of identity.region is used instead. If no such " - "region is found in the service catalog, the first found " - "one is used."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the object-store service."), - cfg.IntOpt('container_sync_timeout', - default=120, - help="Number of seconds to time on waiting for a container " - "to container synchronization complete."), - cfg.IntOpt('container_sync_interval', - default=5, - help="Number of seconds to wait while looping to check the " - "status of a container to container synchronization"), - cfg.StrOpt('operator_role', - default='Member', - help="Role to add to users created for swift tests to " - "enable creating containers"), - cfg.StrOpt('reseller_admin_role', - default='ResellerAdmin', - help="User role that has reseller admin"), -] - -object_storage_feature_group = cfg.OptGroup( - name='object-storage-feature-enabled', - title='Enabled object-storage features') - -ObjectStoreFeaturesGroup = [ - cfg.ListOpt('discoverable_apis', - default=['all'], - help="A list of the enabled optional discoverable apis. " - "A single entry, all, indicates that all of these " - "features are expected to be enabled"), -] - -database_group = cfg.OptGroup(name='database', - title='Database Service Options') - -DatabaseGroup = [ - cfg.StrOpt('catalog_type', - default='database', - help="Catalog type of the Database service."), - cfg.StrOpt('db_flavor_ref', - default="1", - help="Valid primary flavor to use in database tests."), - cfg.StrOpt('db_current_version', - default="v1.0", - help="Current database version to use in database tests."), -] - -dns_group = cfg.OptGroup(name='dns', - title='Dns Service Options') - -DnsGroup = [ - cfg.StrOpt('catalog_type', - default='dns', - help="Catalog type of the Dns service."), -] - -dns_admin_group = cfg.OptGroup(name='dns-admin', - title="Dns Admin Options") - -DnsAdminGroup = [ - cfg.StrOpt('username', - help="Administrative Username to use for " - "Designate API requests."), - cfg.StrOpt('tenant_name', - help="Administrative Tenant name to use for Designate API " - "requests."), - cfg.StrOpt('password', - help="API key to use when authenticating as admin.", - secret=True), -] - -orchestration_group = cfg.OptGroup(name='orchestration', - title='Orchestration Service Options') - -OrchestrationGroup = [ - cfg.StrOpt('catalog_type', - default='orchestration', - help="Catalog type of the Orchestration service."), - cfg.StrOpt('region', - default='', - help="The orchestration region name to use. If empty, the " - "value of identity.region is used instead. If no such " - "region is found in the service catalog, the first found " - "one is used."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the orchestration service."), - cfg.BoolOpt('allow_tenant_isolation', - default=False, - help="Allows test cases to create/destroy tenants and " - "users. This option enables isolated test cases and " - "better parallel execution, but also requires that " - "OpenStack Identity API admin credentials are known."), - cfg.IntOpt('build_interval', - default=1, - help="Time in seconds between build status checks."), - cfg.IntOpt('build_timeout', - default=1200, - help="Timeout in seconds to wait for a stack to build."), - cfg.StrOpt('instance_type', - default='m1.micro', - help="Instance type for tests. Needs to be big enough for a " - "full OS plus the test workload"), - cfg.StrOpt('image_ref', - help="Name of heat-cfntools enabled image to use when " - "launching test instances."), - cfg.StrOpt('keypair_name', - help="Name of existing keypair to launch servers with."), - cfg.IntOpt('max_template_size', - default=524288, - help="Value must match heat configuration of the same name."), - cfg.IntOpt('max_resources_per_stack', - default=1000, - help="Value must match heat configuration of the same name."), -] - - -telemetry_group = cfg.OptGroup(name='telemetry', - title='Telemetry Service Options') - -TelemetryGroup = [ - cfg.StrOpt('catalog_type', - default='metering', - help="Catalog type of the Telemetry service."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the telemetry service."), -] - - -dashboard_group = cfg.OptGroup(name="dashboard", - title="Dashboard options") - -DashboardGroup = [ - cfg.StrOpt('dashboard_url', - default='http://localhost/', - help="Where the dashboard can be found"), - cfg.StrOpt('login_url', - default='http://localhost/auth/login/', - help="Login page for the dashboard"), -] - - -data_processing_group = cfg.OptGroup(name="data_processing", - title="Data Processing options") - -DataProcessingGroup = [ - cfg.StrOpt('catalog_type', - default='data_processing', - help="Catalog type of the data processing service."), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the data processing " - "service."), -] - - -boto_group = cfg.OptGroup(name='boto', - title='EC2/S3 options') -BotoGroup = [ - cfg.StrOpt('ec2_url', - default="http://localhost:8773/services/Cloud", - help="EC2 URL"), - cfg.StrOpt('s3_url', - default="http://localhost:8080", - help="S3 URL"), - cfg.StrOpt('aws_secret', - help="AWS Secret Key", - secret=True), - cfg.StrOpt('aws_access', - help="AWS Access Key"), - cfg.StrOpt('aws_zone', - default="nova", - help="AWS Zone for EC2 tests"), - cfg.StrOpt('s3_materials_path', - default="/opt/stack/devstack/files/images/" - "s3-materials/cirros-0.3.0", - help="S3 Materials Path"), - cfg.StrOpt('ari_manifest', - default="cirros-0.3.0-x86_64-initrd.manifest.xml", - help="ARI Ramdisk Image manifest"), - cfg.StrOpt('ami_manifest', - default="cirros-0.3.0-x86_64-blank.img.manifest.xml", - help="AMI Machine Image manifest"), - cfg.StrOpt('aki_manifest', - default="cirros-0.3.0-x86_64-vmlinuz.manifest.xml", - help="AKI Kernel Image manifest"), - cfg.StrOpt('instance_type', - default="m1.tiny", - help="Instance type"), - cfg.IntOpt('http_socket_timeout', - default=3, - help="boto Http socket timeout"), - cfg.IntOpt('num_retries', - default=1, - help="boto num_retries on error"), - cfg.IntOpt('build_timeout', - default=60, - help="Status Change Timeout"), - cfg.IntOpt('build_interval', - default=1, - help="Status Change Test Interval"), -] - -stress_group = cfg.OptGroup(name='stress', title='Stress Test Options') - -StressGroup = [ - cfg.StrOpt('nova_logdir', - help='Directory containing log files on the compute nodes'), - cfg.IntOpt('max_instances', - default=16, - help='Maximum number of instances to create during test.'), - cfg.StrOpt('controller', - help='Controller host.'), - # new stress options - cfg.StrOpt('target_controller', - help='Controller host.'), - cfg.StrOpt('target_ssh_user', - help='ssh user.'), - cfg.StrOpt('target_private_key_path', - help='Path to private key.'), - cfg.StrOpt('target_logfiles', - help='regexp for list of log files.'), - cfg.IntOpt('log_check_interval', - default=60, - help='time (in seconds) between log file error checks.'), - cfg.IntOpt('default_thread_number_per_action', - default=4, - help='The number of threads created while stress test.'), - cfg.BoolOpt('leave_dirty_stack', - default=False, - help='Prevent the cleaning (tearDownClass()) between' - ' each stress test run if an exception occurs' - ' during this run.'), - cfg.BoolOpt('full_clean_stack', - default=False, - help='Allows a full cleaning process after a stress test.' - ' Caution : this cleanup will remove every objects of' - ' every tenant.') -] - - -scenario_group = cfg.OptGroup(name='scenario', title='Scenario Test Options') - -ScenarioGroup = [ - cfg.StrOpt('img_dir', - default='/opt/stack/new/devstack/files/images/' - 'cirros-0.3.1-x86_64-uec', - help='Directory containing image files'), - cfg.StrOpt('qcow2_img_file', - default='cirros-0.3.1-x86_64-disk.img', - help='QCOW2 image file name'), - cfg.StrOpt('ami_img_file', - default='cirros-0.3.1-x86_64-blank.img', - help='AMI image file name'), - cfg.StrOpt('ari_img_file', - default='cirros-0.3.1-x86_64-initrd', - help='ARI image file name'), - cfg.StrOpt('aki_img_file', - default='cirros-0.3.1-x86_64-vmlinuz', - help='AKI image file name'), - cfg.StrOpt('ssh_user', - default='cirros', - help='ssh username for the image file'), - cfg.IntOpt( - 'large_ops_number', - default=0, - help="specifies how many resources to request at once. Used " - "for large operations testing.") -] - - -service_available_group = cfg.OptGroup(name="service_available", - title="Available OpenStack Services") - -ServiceAvailableGroup = [ - cfg.BoolOpt('cinder', - default=True, - help="Whether or not cinder is expected to be available"), - cfg.BoolOpt('neutron', - default=False, - help="Whether or not neutron is expected to be available"), - cfg.BoolOpt('glance', - default=True, - help="Whether or not glance is expected to be available"), - cfg.BoolOpt('swift', - default=True, - help="Whether or not swift is expected to be available"), - cfg.BoolOpt('nova', - default=True, - help="Whether or not nova is expected to be available"), - cfg.BoolOpt('heat', - default=False, - help="Whether or not Heat is expected to be available"), - cfg.BoolOpt('ceilometer', - default=True, - help="Whether or not Ceilometer is expected to be available"), - cfg.BoolOpt('horizon', - default=True, - help="Whether or not Horizon is expected to be available"), - cfg.BoolOpt('sahara', - default=False, - help="Whether or not Sahara is expected to be available"), - cfg.BoolOpt('ironic', - default=False, - help="Whether or not Ironic is expected to be available"), - cfg.BoolOpt('trove', - default=False, - help="Whether or not Trove is expected to be available"), - cfg.BoolOpt('designate', - default=False, - help="Whether or not Designate is expected to be available"), - cfg.BoolOpt('marconi', - default=False, - help="Whether or not Marconi is expected to be available"), -] - -debug_group = cfg.OptGroup(name="debug", - title="Debug System") - -DebugGroup = [ - cfg.BoolOpt('enable', - default=True, - help="Enable diagnostic commands"), - cfg.StrOpt('trace_requests', - default='', - help="""A regex to determine which requests should be traced. - -This is a regex to match the caller for rest client requests to be able to -selectively trace calls out of specific classes and methods. It largely -exists for test development, and is not expected to be used in a real deploy -of tempest. This will be matched against the discovered ClassName:method -in the test environment. - -Expected values for this field are: - - * ClassName:test_method_name - traces one test_method - * ClassName:setUp(Class) - traces specific setup functions - * ClassName:tearDown(Class) - traces specific teardown functions - * ClassName:_run_cleanups - traces the cleanup functions - -If nothing is specified, this feature is not enabled. To trace everything -specify .* as the regex. -""") -] - -input_scenario_group = cfg.OptGroup(name="input-scenario", - title="Filters and values for" - " input scenarios") - -InputScenarioGroup = [ - cfg.StrOpt('image_regex', - default='^cirros-0.3.1-x86_64-uec$', - help="Matching images become parameters for scenario tests"), - cfg.StrOpt('flavor_regex', - default='^m1.nano$', - help="Matching flavors become parameters for scenario tests"), - cfg.StrOpt('non_ssh_image_regex', - default='^.*[Ww]in.*$', - help="SSH verification in tests is skipped" - "for matching images"), - cfg.StrOpt('ssh_user_regex', - default="[[\"^.*[Cc]irros.*$\", \"root\"]]", - help="List of user mapped to regex " - "to matching image names."), -] - - -baremetal_group = cfg.OptGroup(name='baremetal', - title='Baremetal provisioning service options') - -BaremetalGroup = [ - cfg.StrOpt('catalog_type', - default='baremetal', - help="Catalog type of the baremetal provisioning service"), - cfg.BoolOpt('driver_enabled', - default=False, - help="Whether the Ironic nova-compute driver is enabled"), - cfg.StrOpt('endpoint_type', - default='publicURL', - choices=['public', 'admin', 'internal', - 'publicURL', 'adminURL', 'internalURL'], - help="The endpoint type to use for the baremetal provisioning " - "service"), - cfg.IntOpt('active_timeout', - default=300, - help="Timeout for Ironic node to completely provision"), - cfg.IntOpt('association_timeout', - default=10, - help="Timeout for association of Nova instance and Ironic " - "node"), - cfg.IntOpt('power_timeout', - default=20, - help="Timeout for Ironic power transitions."), - cfg.IntOpt('unprovision_timeout', - default=20, - help="Timeout for unprovisioning an Ironic node.") -] - -cli_group = cfg.OptGroup(name='cli', title="cli Configuration Options") - -CLIGroup = [ - cfg.BoolOpt('enabled', - default=True, - help="enable cli tests"), - cfg.StrOpt('cli_dir', - default='/usr/local/bin', - help="directory where python client binaries are located"), - cfg.BoolOpt('has_manage', - default=True, - help=("Whether the tempest run location has access to the " - "*-manage commands. In a pure blackbox environment " - "it will not.")), - cfg.IntOpt('timeout', - default=15, - help="Number of seconds to wait on a CLI timeout"), -] - -negative_group = cfg.OptGroup(name='negative', title="Negative Test Options") - -NegativeGroup = [ - cfg.StrOpt('test_generator', - default='tempest.common.' + - 'generator.negative_generator.NegativeTestGenerator', - help="Test generator class for all negative tests"), -] - - -def register_opts(): - register_opt_group(cfg.CONF, compute_group, ComputeGroup) - register_opt_group(cfg.CONF, compute_features_group, - ComputeFeaturesGroup) - register_opt_group(cfg.CONF, identity_group, IdentityGroup) - register_opt_group(cfg.CONF, identity_feature_group, - IdentityFeatureGroup) - register_opt_group(cfg.CONF, image_group, ImageGroup) - register_opt_group(cfg.CONF, image_feature_group, ImageFeaturesGroup) - register_opt_group(cfg.CONF, network_group, NetworkGroup) - register_opt_group(cfg.CONF, network_feature_group, - NetworkFeaturesGroup) - register_opt_group(cfg.CONF, queuing_group, QueuingGroup) - register_opt_group(cfg.CONF, volume_group, VolumeGroup) - register_opt_group(cfg.CONF, volume_feature_group, - VolumeFeaturesGroup) - register_opt_group(cfg.CONF, object_storage_group, ObjectStoreGroup) - register_opt_group(cfg.CONF, object_storage_feature_group, - ObjectStoreFeaturesGroup) - register_opt_group(cfg.CONF, database_group, DatabaseGroup) - register_opt_group(cfg.CONF, dns_group, DnsGroup) - register_opt_group(cfg.CONF, dns_admin_group, DnsAdminGroup) - register_opt_group(cfg.CONF, orchestration_group, OrchestrationGroup) - register_opt_group(cfg.CONF, telemetry_group, TelemetryGroup) - register_opt_group(cfg.CONF, dashboard_group, DashboardGroup) - register_opt_group(cfg.CONF, data_processing_group, - DataProcessingGroup) - register_opt_group(cfg.CONF, boto_group, BotoGroup) - register_opt_group(cfg.CONF, compute_admin_group, ComputeAdminGroup) - register_opt_group(cfg.CONF, stress_group, StressGroup) - register_opt_group(cfg.CONF, scenario_group, ScenarioGroup) - register_opt_group(cfg.CONF, service_available_group, - ServiceAvailableGroup) - register_opt_group(cfg.CONF, debug_group, DebugGroup) - register_opt_group(cfg.CONF, baremetal_group, BaremetalGroup) - register_opt_group(cfg.CONF, input_scenario_group, InputScenarioGroup) - register_opt_group(cfg.CONF, cli_group, CLIGroup) - register_opt_group(cfg.CONF, negative_group, NegativeGroup) - - -class TempestConfigPrivate(object): - """Provides OpenStack configuration information.""" - - DEFAULT_CONFIG_DIR = os.path.join( - os.path.abspath(os.path.dirname(os.path.dirname(__file__))), - "etc") - - DEFAULT_CONFIG_FILE = "tempest.conf" - - def _set_attrs(self): - self.compute = cfg.CONF.compute - self.compute_feature_enabled = cfg.CONF['compute-feature-enabled'] - self.identity = cfg.CONF.identity - self.identity_feature_enabled = cfg.CONF['identity-feature-enabled'] - self.image = cfg.CONF.image - self.image_feature_enabled = cfg.CONF['image-feature-enabled'] - self.network = cfg.CONF.network - self.network_feature_enabled = cfg.CONF['network-feature-enabled'] - self.volume = cfg.CONF.volume - self.volume_feature_enabled = cfg.CONF['volume-feature-enabled'] - self.object_storage = cfg.CONF['object-storage'] - self.object_storage_feature_enabled = cfg.CONF[ - 'object-storage-feature-enabled'] - self.database = cfg.CONF.database - self.dns = cfg.CONF.dns - self.orchestration = cfg.CONF.orchestration - self.queuing = cfg.CONF.queuing - self.telemetry = cfg.CONF.telemetry - self.dashboard = cfg.CONF.dashboard - self.data_processing = cfg.CONF.data_processing - self.boto = cfg.CONF.boto - self.compute_admin = cfg.CONF['compute-admin'] - self.dns_admin = cfg.CONF['dns-admin'] - self.stress = cfg.CONF.stress - self.scenario = cfg.CONF.scenario - self.service_available = cfg.CONF.service_available - self.debug = cfg.CONF.debug - self.baremetal = cfg.CONF.baremetal - self.input_scenario = cfg.CONF['input-scenario'] - self.cli = cfg.CONF.cli - self.negative = cfg.CONF.negative - if not self.compute_admin.username: - self.compute_admin.username = self.identity.admin_username - self.compute_admin.password = self.identity.admin_password - self.compute_admin.tenant_name = self.identity.admin_tenant_name - cfg.CONF.set_default('domain_name', self.identity.admin_domain_name, - group='identity') - cfg.CONF.set_default('alt_domain_name', - self.identity.admin_domain_name, - group='identity') - cfg.CONF.set_default('domain_name', self.identity.admin_domain_name, - group='compute-admin') - - def __init__(self, parse_conf=True): - """Initialize a configuration from a conf directory and conf file.""" - super(TempestConfigPrivate, self).__init__() - config_files = [] - failsafe_path = "/etc/tempest/" + self.DEFAULT_CONFIG_FILE - - # Environment variables override defaults... - conf_dir = os.environ.get('TEMPEST_CONFIG_DIR', - self.DEFAULT_CONFIG_DIR) - conf_file = os.environ.get('TEMPEST_CONFIG', self.DEFAULT_CONFIG_FILE) - - path = os.path.join(conf_dir, conf_file) - - if not os.path.isfile(path): - path = failsafe_path - - # only parse the config file if we expect one to exist. This is needed - # to remove an issue with the config file up to date checker. - if parse_conf: - config_files.append(path) - - cfg.CONF([], project='tempest', default_config_files=config_files) - logging.setup('tempest') - LOG = logging.getLogger('tempest') - # LOG.info("Using tempest config file %s", path) - register_opts() - self._set_attrs() - if parse_conf: - cfg.CONF.log_opt_values(LOG, std_logging.DEBUG) - - -class TempestConfigProxy(object): - _config = None - - def __getattr__(self, attr): - if not self._config: - self._config = TempestConfigPrivate() - - return getattr(self._config, attr) - - -CONF = TempestConfigProxy() diff --git a/contrib/tempest/dns_clients/__init__.py b/contrib/tempest/dns_clients/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/contrib/tempest/dns_clients/__init__.py +++ /dev/null diff --git a/contrib/tempest/dns_clients/json/__init__.py b/contrib/tempest/dns_clients/json/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/contrib/tempest/dns_clients/json/__init__.py +++ /dev/null diff --git a/contrib/tempest/dns_clients/json/domains_client.py b/contrib/tempest/dns_clients/json/domains_client.py deleted file mode 100644 index ab304fa1..00000000 --- a/contrib/tempest/dns_clients/json/domains_client.py +++ /dev/null @@ -1,79 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import json - -from tempest.api_schema.dns import domains as schema -from tempest.common import rest_client -from tempest import config - -CONF = config.CONF - - -class DomainsClientJSON(rest_client.RestClient): - - def __init__(self, auth_provider): - super(DomainsClientJSON, self).__init__(auth_provider) - self.service = CONF.dns.catalog_type - - def list_domains(self, params=None): - """List all domains.""" - resp, body = self.get("v1/domains") - body = json.loads(body) - self.validate_response(schema.list_domains, resp, body) - return resp, body['domains'] - - def get_domain(self, domain_id): - """Get the details of a domain.""" - resp, body = self.get("v1/domains/%s" % str(domain_id)) - body = json.loads(body) - self.validate_response(schema.get_zone, resp, body) - return resp, body - - def delete_domain(self, domain_id): - """Delete the given domain.""" - resp, body = self.delete("v1/domains/%s" % str(domain_id)) - self.validate_response(schema.delete_zone, resp, body) - return resp, body - - def create_domain(self, name, email, **kwargs): - """Creates a domain.""" - post_body = { - "name": name, - "email": email - } - for option in ['ttl', 'description']: - post_param = option - value = kwargs.get(option) - if value is not None: - post_body[post_param] = value - resp, body = self.post('v1/domains', json.dumps(post_body)) - body = json.loads(body) - self.validate_response(schema.create_zone, resp, body) - return resp, body - - def update_domain(self, domain_id, **kwargs): - """Updates a domain.""" - post_body = {} - for option in ['email', 'name', 'ttl', 'description']: - post_param = option - value = kwargs.get(option) - if value is not None: - post_body[post_param] = value - resp, body = self.put('v1/domains/%s' % domain_id, - json.dumps(post_body)) - body = json.loads(body) - self.validate_response(schema.update_zone, resp, body) - return resp, body diff --git a/contrib/tempest/dns_clients/json/records_client.py b/contrib/tempest/dns_clients/json/records_client.py deleted file mode 100644 index 2ca6a233..00000000 --- a/contrib/tempest/dns_clients/json/records_client.py +++ /dev/null @@ -1,84 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import json - -from tempest.api_schema.dns import records as schema -from tempest.common import rest_client -from tempest import config - -CONF = config.CONF - - -class RecordsClientJSON(rest_client.RestClient): - - def __init__(self, auth_provider): - super(RecordsClientJSON, self).__init__(auth_provider) - self.service = CONF.dns.catalog_type - - def list_records(self, domain_id): - """List all records.""" - resp, body = self.get("v1/domains/%s/records" % (domain_id)) - body = json.loads(body) - self.validate_response(schema.list_records, resp, body) - return resp, body['records'] - - def get_record(self, domain_id, record_id): - """Get the details of a record.""" - resp, body = self.get("v1/domains/%s/records/%s" % (domain_id, - record_id)) - body = json.loads(body) - self.validate_response(schema.get_record, resp, body) - return resp, body - - def delete_record(self, domain_id, record_id): - """Delete the given record.""" - resp, body = self.delete("v1/domains/%s/records/%s" % (domain_id, - record_id)) - self.validate_response(schema.delete_record, resp, body) - return resp, body - - def create_record(self, domain_id, name, type, data, **kwargs): - """Creates a record.""" - post_body = { - "name": name, - "type": type, - "data": data - } - for option in ['ttl', 'priority', 'description']: - post_param = option - value = kwargs.get(option) - if value is not None: - post_body[post_param] = value - uri = "v1/domains/%s/records" % (domain_id) - resp, body = self.post(uri, json.dumps(post_body)) - body = json.loads(body) - self.validate_response(schema.create_record, resp, body) - return resp, body - - def update_record(self, domain_id, record_id, **kwargs): - """Updates a record.""" - post_body = {} - for option in ['name', 'type', 'data', 'ttl', 'priority', - 'description']: - post_param = option - value = kwargs.get(option) - if value is not None: - post_body[post_param] = value - resp, body = self.put('v1/domains/%s/records/%s' % (domain_id, - record_id), json.dumps(post_body)) - body = json.loads(body) - self.validate_response(schema.update_record, resp, body) - return resp, body diff --git a/contrib/tempest/dns_clients/json/server_client.py b/contrib/tempest/dns_clients/json/server_client.py deleted file mode 100644 index 64709135..00000000 --- a/contrib/tempest/dns_clients/json/server_client.py +++ /dev/null @@ -1,76 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import json - -from tempest.api_schema.dns import servers as schema -from tempest.common import rest_client -from tempest import config - -CONF = config.CONF - - -class ServersClientJSON(rest_client.RestClient): - - def __init__(self, auth_provider): - super(ServersClientJSON, self).__init__(auth_provider) - self.service = CONF.dns.catalog_type - - def list_servers(self, params=None): - """List all servers.""" - resp, body = self.get("v1/servers") - body = json.loads(body) - self.validate_response(schema.list_servers, resp, body) - return resp, body['servers'] - - def get_server(self, server_id): - """Get the details of a server.""" - resp, body = self.get("v1/servers/%s" % str(server_id)) - body = json.loads(body) - self.validate_response(schema.get_server, resp, body) - return resp, body - - def delete_server(self, server_id): - """Delete the given server.""" - resp, body = self.delete("v1/servers/%s" % str(server_id)) - self.validate_response(schema.delete_server, resp, body) - return resp, body - - def create_server(self, name, **kwargs): - """Creates a server.""" - post_body = { - "name": name, - } - for option in ['max-width', 'variable', 'prefix']: - value = kwargs.get(option) - post_param = option - if value is not None: - post_body[post_param] = value - resp, body = self.post('v1/servers', json.dumps(post_body)) - body = json.loads(body) - self.validate_response(schema.create_server, resp, body) - return resp, body - - def update_server(self, server_id, **kwargs): - """Updates a server.""" - name = kwargs.get('name') - post_body = { - 'name': name - } - resp, body = self.put('v1/servers/%s' % server_id, - json.dumps(post_body)) - body = json.loads(body) - self.validate_response(schema.update_server, resp, body) - return resp, body diff --git a/contrib/tempest/dns_schema/__init__.py b/contrib/tempest/dns_schema/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/contrib/tempest/dns_schema/__init__.py +++ /dev/null diff --git a/contrib/tempest/dns_schema/domains.py b/contrib/tempest/dns_schema/domains.py deleted file mode 100644 index 50247e87..00000000 --- a/contrib/tempest/dns_schema/domains.py +++ /dev/null @@ -1,123 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -list_domains = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "domains": { - "type": "array", - "items": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "description": { - "anyOf": [{'type': 'string'}, {"type": "null"}]}, - "email": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "serial": {"type": "number"}, - "ttl": {"type": "number"}, - "updated_at": { - "anyOf": [{'type': 'string'}, {"type": "null"}]} - }, - 'required': ['id', 'name', 'email', 'ttl'] - } - } - }, - 'required': ['domains'] - } -} - -create_domain = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "domain": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "description": { - "anyOf": [{'type': 'string'}, {"type": "null"}]}, - "email": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "serial": {"type": "number"}, - "ttl": {"type": "number"}, - "updated_at": {"type": "null"} - }, - "required": ['id', 'name', 'email', 'ttl'] - } - } - }, - "required": ['domain'] -} - -update_domain = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "domain": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "description": { - "anyOf": [{'type': 'string'}, {"type": "null"}]}, - "email": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "serial": {"type": "number"}, - "ttl": {"type": "number"}, - "updated_at": { - "anyOf": [{'type': 'string'}, {"type": "null"}]} - }, - "required": ['id', 'name', 'email', 'ttl'] - } - } - }, - "required": ['domain'] -} - -get_domain = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "domain": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "description": { - "anyOf": [{'type': 'string'}, {"type": "null"}]}, - "email": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "serial": {"type": "number"}, - "ttl": {"type": "number"}, - "updated_at": { - "anyOf": [{'type': 'string'}, {"type": "null"}]} - }, - "required": ['id', 'name', 'email', 'ttl'] - } - } - }, - "required": ['domain'] -} - -delete_domain = { - 'status_code': [200], -} diff --git a/contrib/tempest/dns_schema/parameter_types.py b/contrib/tempest/dns_schema/parameter_types.py deleted file mode 100644 index 5753ef89..00000000 --- a/contrib/tempest/dns_schema/parameter_types.py +++ /dev/null @@ -1,23 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -access_ip_v4 = { - 'type': 'string', - 'anyOf': [{'format': 'ipv4'}, {'enum': ['']}] -} - -access_ip_v6 = { - 'type': 'string', - 'anyOf': [{'format': 'ipv6'}, {'enum': ['']}] -} diff --git a/contrib/tempest/dns_schema/records.py b/contrib/tempest/dns_schema/records.py deleted file mode 100644 index 919985b8..00000000 --- a/contrib/tempest/dns_schema/records.py +++ /dev/null @@ -1,136 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -from tempest.api_schema.dns import parameter_types - -list_records = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "records": { - "type": "array", - "items": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "data": { - "anyOf": [parameter_types.access_ip_v4, - parameter_types.access_ip_v6]}, - "description": {"type": "null"}, - "domain_id": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "priority": {"type": "null"}, - "ttl": {"type": "null"}, - "type": {"type": "string"}, - "updated_at": { - "anyOf": [{'type': 'string'}, {"type": "null"}]} - }, - 'required': ['id', 'name', 'type', 'data'] - } - } - }, - 'required': ['records'] - } -} - -create_record = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "record": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "data": { - "anyOf": [parameter_types.access_ip_v4, - parameter_types.access_ip_v6]}, - "description": {"type": "null"}, - "domain_id": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "priority": {"type": "null"}, - "ttl": {"type": "null"}, - "type": {"type": "string"}, - "updated_at": {"type": "null"} - }, - "required": ['id', 'name', 'type', 'domain_id'] - } - } - }, - "required": ['record'] -} - -update_record = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "record": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "data": { - "anyOf": [parameter_types.access_ip_v4, - parameter_types.access_ip_v6]}, - "description": {"type": "null"}, - "domain_id": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "priority": {"type": "null"}, - "ttl": {"type": "null"}, - "type": {"type": "string"}, - "updated_at": {"type": "string"} - }, - "required": ['id', 'name', 'type', 'domain_id'] - } - } - }, - "required": ['record'] -} - -get_record = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "record": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "data": { - "anyOf": [parameter_types.access_ip_v4, - parameter_types.access_ip_v6]}, - "description": {"type": "null"}, - "domain_id": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "priority": {"type": "null"}, - "ttl": {"type": "null"}, - "type": {"type": "string"}, - "updated_at": { - "anyOf": [{'type': 'string'}, {"type": "null"}]} - }, - "required": ['id', 'name', 'type', 'domain_id'] - } - } - }, - "required": ['record'] -} - -delete_record = { - 'status_code': [200], -} diff --git a/contrib/tempest/dns_schema/servers.py b/contrib/tempest/dns_schema/servers.py deleted file mode 100644 index 934917d0..00000000 --- a/contrib/tempest/dns_schema/servers.py +++ /dev/null @@ -1,103 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - - -list_servers = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "servers": { - "type": "array", - "items": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "updated_at": { - "anyOf": [{'type': 'string'}, {"type": "null"}]} - }, - 'required': ['id', 'name'] - } - } - }, - 'required': ['servers'] - } -} - -create_server = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "server": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "updated_at": {"type": "null"} - }, - "required": ['id', 'name'] - } - } - }, - "required": ['server'] -} - -update_server = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "server": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "updated_at": {"type": "string"} - }, - "required": ['id', 'name'] - } - } - }, - "required": ['server'] -} - -get_server = { - "status_code": [200], - "response_body": { - "type": "object", - "properties": { - "server": { - "type": "object", - "properties": { - "created_at": {"type": "string"}, - "id": {"type": "string"}, - "name": {"type": "string"}, - "updated_at": { - "anyOf": [{'type': 'string'}, {"type": "null"}]} - }, - "required": ['id', 'name'] - } - } - }, - "required": ['server'] -} - -delete_server = { - 'status_code': [200], -} diff --git a/contrib/tempest/dns_tests/__init__.py b/contrib/tempest/dns_tests/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/contrib/tempest/dns_tests/__init__.py +++ /dev/null diff --git a/contrib/tempest/dns_tests/admin/__init__.py b/contrib/tempest/dns_tests/admin/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/contrib/tempest/dns_tests/admin/__init__.py +++ /dev/null diff --git a/contrib/tempest/dns_tests/admin/test_servers.py b/contrib/tempest/dns_tests/admin/test_servers.py deleted file mode 100644 index 42c44ebb..00000000 --- a/contrib/tempest/dns_tests/admin/test_servers.py +++ /dev/null @@ -1,73 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import six -from tempest.api.dns import base -from tempest.common.utils import data_utils -from tempest import exceptions -from tempest import test - - -class ServersAdminTestJSON(base.BaseDnsAdminTest): - """ - Tests Servers API Create, Get, List and Delete - that require admin privileges - """ - - @classmethod - def setUpClass(cls): - super(ServersAdminTestJSON, cls).setUpClass() - cls.client = cls.os_adm.dns_servers_client - cls.setup_servers = list() - for i in range(2): - name = data_utils.rand_name('dns-server') + '.com.' - _, server = cls.client.create_server(name) - cls.setup_servers.append(server) - - @classmethod - def tearDownClass(cls): - for server in cls.setup_servers: - cls.client.delete_server(server['id']) - super(ServersAdminTestJSON, cls).tearDownClass() - - def _delete_server(self, server_id): - self.client.delete_server(server_id) - self.assertRaises(exceptions.NotFound, - self.client.get_server, server_id) - - @test.attr(type='gate') - def test_list_servers(self): - # Get a list of servers - _, servers = self.client.list_servers() - # Verify servers created in setup class are in the list - for server in self.setup_servers: - self.assertIn(server['id'], - six.moves.map(lambda x: x['id'], servers)) - - @test.attr(type='smoke') - def test_create_update_get_delete_server(self): - # Create Dns Server - s_name1 = data_utils.rand_name('dns-server') + '.com.' - _, server = self.client.create_server(s_name1) - self.addCleanup(self._delete_server, server['id']) - self.assertEqual(s_name1, server['name']) - self.assertIsNotNone(server['id']) - # Update Dns Server - s_name2 = data_utils.rand_name('update-dns-server') + '.com.' - _, update_server = self.client.update_server(server['id'], - name=s_name2) - self.assertEqual(s_name2, update_server['name']) - # Get the details of Server - _, get_server = self.client.get_server(server['id']) - self.assertEqual(update_server['name'], get_server['name']) diff --git a/contrib/tempest/dns_tests/base.py b/contrib/tempest/dns_tests/base.py deleted file mode 100644 index 9d2af51f..00000000 --- a/contrib/tempest/dns_tests/base.py +++ /dev/null @@ -1,64 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -from tempest import clients -from tempest import config -from tempest import exceptions -from tempest.openstack.common import log as logging -import tempest.test - -CONF = config.CONF -LOG = logging.getLogger(__name__) - - -class BaseDnsTest(tempest.test.BaseTestCase): - """Base test case class for all Dns API tests.""" - - _interface = 'json' - force_tenant_isolation = False - - @classmethod - def setUpClass(cls): - super(BaseDnsTest, cls).setUpClass() - if not CONF.service_available.designate: - skip_msg = ("%s skipped as designate is not available" - % cls.__name__) - raise cls.skipException(skip_msg) - os = cls.get_client_manager() - cls.os = os - cls.dns_domains_client = cls.os.dns_domains_client - cls.dns_records_client = cls.os.dns_records_client - - -class BaseDnsAdminTest(BaseDnsTest): - """Base test case class for Dns Admin API tests.""" - _interface = "json" - - @classmethod - def setUpClass(cls): - super(BaseDnsAdminTest, cls).setUpClass() - if (CONF.compute.allow_tenant_isolation or - cls.force_tenant_isolation is True): - creds = cls.isolated_creds.get_admin_creds() - cls.os_adm = clients.Manager(credentials=creds, - interface=cls._interface) - else: - try: - cls.os_adm = clients.DnsAdminManager( - interface=cls._interface) - except exceptions.InvalidCredentials: - msg = ("Missing Dns Admin API credentials " - "in configuration.") - raise cls.skipException(msg) diff --git a/contrib/tempest/dns_tests/test_domains.py b/contrib/tempest/dns_tests/test_domains.py deleted file mode 100644 index f4c42ed6..00000000 --- a/contrib/tempest/dns_tests/test_domains.py +++ /dev/null @@ -1,75 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import six -from tempest.api.dns import base -from tempest.common.utils import data_utils -from tempest import exceptions -from tempest import test - - -class DnsDomainsTest(base.BaseDnsTest): - _interface = 'json' - - @classmethod - def setUpClass(cls): - super(DnsDomainsTest, cls).setUpClass() - cls.client = cls.dns_domains_client - cls.setup_domains = list() - for i in range(2): - name = data_utils.rand_name('domain') + '.com.' - email = data_utils.rand_name('dns') + '@testmail.com' - _, domain = cls.client.create_zone(name, email) - cls.setup_domains.append(domain) - - @classmethod - def tearDownClass(cls): - for domain in cls.setup_domains: - cls.client.delete_zone(domain['id']) - super(DnsDomainsTest, cls).tearDownClass() - - def _delete_domain(self, domain_id): - self.client.delete_zone(domain_id) - self.assertRaises(exceptions.NotFound, - self.client.get_zone, domain_id) - - @test.attr(type='gate') - def test_list_domains(self): - # Get a list of domains - _, domains = self.client.list_domains() - # Verify domains created in setup class are in the list - for domain in self.setup_domains: - self.assertIn(domain['id'], - six.moves.map(lambda x: x['id'], domains)) - - @test.attr(type='smoke') - def test_create_update_get_domain(self): - # Create Zone - d_name = data_utils.rand_name('domain') + '.com.' - d_email = data_utils.rand_name('dns') + '@testmail.com' - _, domain = self.client.create_zone(name=d_name, email=d_email) - self.addCleanup(self._delete_domain, domain['id']) - self.assertEqual(d_name, domain['name']) - self.assertEqual(d_email, domain['email']) - # Update Zone with ttl - d_ttl = 3600 - _, update_domain = self.client.update_zone(domain['id'], - ttl=d_ttl) - self.assertEqual(d_ttl, update_domain['ttl']) - # Get the details of Zone - _, get_domain = self.client.get_zone(domain['id']) - self.assertEqual(update_domain['name'], get_domain['name']) - self.assertEqual(update_domain['email'], get_domain['email']) - self.assertEqual(update_domain['ttl'], get_domain['ttl']) diff --git a/contrib/tempest/dns_tests/test_records.py b/contrib/tempest/dns_tests/test_records.py deleted file mode 100644 index 052e1feb..00000000 --- a/contrib/tempest/dns_tests/test_records.py +++ /dev/null @@ -1,104 +0,0 @@ -# Copyright 2014 Hewlett-Packard Development Company, L.P -# All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - -import six -from tempest.api.dns import base -from tempest.common.utils import data_utils -from tempest import exceptions -from tempest import test - - -class RecordsTest(base.BaseDnsTest): - _interface = 'json' - - @classmethod - def setUpClass(cls): - super(RecordsTest, cls).setUpClass() - cls.client = cls.dns_records_client - # Creates domains and Records for testcase - cls.setup_records = list() - name = data_utils.rand_name('domain') + '.com.' - email = data_utils.rand_name('dns') + '@testmail.com' - _, cls.domain = cls.dns_domains_client.create_zone(name, email) - # Creates a record with type as A - r_name = 'www.' + name - data1 = "192.0.2.3" - _, record = cls.client.create_record( - domain_id=cls.domain['id'], name=r_name, data=data1, - type='A') - cls.setup_records.append(record) - # Creates a record with type AAAA - data2 = "2001:db8:0:1234:0:5678:9:12" - _, record = cls.client.create_record( - domain_id=cls.domain['id'], name=r_name, - data=data2, type='AAAA') - cls.setup_records.append(record) - - @classmethod - def tearDownClass(cls): - for record in cls.setup_records: - cls.client.delete_record(cls.domain['id'], record['id']) - cls.dns_domains_client.delete_zone(cls.domain['id']) - - def _delete_record(self, domain_id, record_id): - self.client.delete_record(domain_id, record_id) - self.assertRaises(exceptions.NotFound, - self.client.get_record, domain_id, record_id) - - @test.attr(type='gate') - def test_list_records_for_domain(self): - # Get a list of records for a domain - _, records = self.client.list_records(self.domain['id']) - # Verify records created in setup class are in the list - for record in self.setup_records: - self.assertIn(record['id'], - six.moves.map(lambda x: x['id'], records)) - - @test.attr(type='smoke') - def test_create_update_get_delete_record(self): - # Create Zone - name = data_utils.rand_name('domain') + '.com.' - email = data_utils.rand_name('dns') + '@testmail.com' - _, domain = self.dns_domains_client.create_zone(name, email) - self.addCleanup(self.dns_domains_client.delete_zone, domain['id']) - # Create Record - r_name = 'www.' + name - r_data = "192.0.2.4" - _, record = self.client.create_record(domain_id=domain['id'], - name=r_name, data=r_data, - type='A') - self.addCleanup(self._delete_record, domain['id'], record['id']) - self.assertIsNotNone(record['id']) - self.assertEqual(domain['id'], record['domain_id']) - self.assertEqual(r_name, record['name']) - self.assertEqual(r_data, record['data']) - self.assertEqual('A', record['type']) - # Update Record with data and ttl - r_data1 = "192.0.2.5" - r_ttl = 3600 - _, update_record = self.client.update_record(domain_id=domain['id'], - record_id=record['id'], - name=r_name, type='A', - data=r_data1, ttl=r_ttl) - self.assertEqual(r_data1, update_record['data']) - self.assertEqual(r_ttl, update_record['ttl']) - # GET record - _, get_record = self.client.get_record(domain_id=domain['id'], - record_id=record['id']) - self.assertEqual(update_record['data'], get_record['data']) - self.assertEqual(update_record['name'], get_record['name']) - self.assertEqual(update_record['type'], get_record['type']) - self.assertEqual(update_record['ttl'], get_record['ttl']) - self.assertEqual(update_record['domain_id'], get_record['domain_id']) diff --git a/contrib/tempest/tempest.conf.sample b/contrib/tempest/tempest.conf.sample deleted file mode 100644 index 1cf8bb8d..00000000 --- a/contrib/tempest/tempest.conf.sample +++ /dev/null @@ -1,1095 +0,0 @@ -[DEFAULT] - -# -# Options defined in tempest.openstack.common.lockutils -# - -# Whether to disable inter-process locks (boolean value) -#disable_process_locking=false - -# Directory to use for lock files. (string value) -#lock_path=<None> - - -# -# Options defined in tempest.openstack.common.log -# - -# Print debugging output (set logging level to DEBUG instead -# of default WARNING level). (boolean value) -#debug=false - -# Print more verbose output (set logging level to INFO instead -# of default WARNING level). (boolean value) -#verbose=false - -# Log output to standard error. (boolean value) -#use_stderr=true - -# Format string to use for log messages with context. (string -# value) -#logging_context_format_string=%(asctime)s.%(msecs)03d %(process)d %(levelname)s %(name)s [%(request_id)s %(user_identity)s] %(instance)s%(message)s - -# Format string to use for log messages without context. -# (string value) -#logging_default_format_string=%(asctime)s.%(msecs)03d %(process)d %(levelname)s %(name)s [-] %(instance)s%(message)s - -# Data to append to log format when level is DEBUG. (string -# value) -#logging_debug_format_suffix=%(funcName)s %(pathname)s:%(lineno)d - -# Prefix each line of exception output with this format. -# (string value) -#logging_exception_prefix=%(asctime)s.%(msecs)03d %(process)d TRACE %(name)s %(instance)s - -# List of logger=LEVEL pairs. (list value) -#default_log_levels=amqp=WARN,amqplib=WARN,boto=WARN,qpid=WARN,sqlalchemy=WARN,suds=INFO,oslo.messaging=INFO,iso8601=WARN,requests.packages.urllib3.connectionpool=WARN,urllib3.connectionpool=WARN - -# Enables or disables publication of error events. (boolean -# value) -#publish_errors=false - -# Enables or disables fatal status of deprecations. (boolean -# value) -#fatal_deprecations=false - -# The format for an instance that is passed with the log -# message. (string value) -#instance_format="[instance: %(uuid)s] " - -# The format for an instance UUID that is passed with the log -# message. (string value) -#instance_uuid_format="[instance: %(uuid)s] " - -# The name of a logging configuration file. This file is -# appended to any existing logging configuration files. For -# details about logging configuration files, see the Python -# logging module documentation. (string value) -# Deprecated group/name - [DEFAULT]/log_config -#log_config_append=<None> - -# DEPRECATED. A logging.Formatter log message format string -# which may use any of the available logging.LogRecord -# attributes. This option is deprecated. Please use -# logging_context_format_string and -# logging_default_format_string instead. (string value) -#log_format=<None> - -# Format string for %%(asctime)s in log records. Default: -# %(default)s . (string value) -#log_date_format=%Y-%m-%d %H:%M:%S - -# (Optional) Name of log file to output to. If no default is -# set, logging will go to stdout. (string value) -# Deprecated group/name - [DEFAULT]/logfile -#log_file=<None> - -# (Optional) The base directory used for relative --log-file -# paths. (string value) -# Deprecated group/name - [DEFAULT]/logdir -#log_dir=<None> - -# Use syslog for logging. Existing syslog format is DEPRECATED -# during I, and will change in J to honor RFC5424. (boolean -# value) -#use_syslog=false - -# (Optional) Enables or disables syslog rfc5424 format for -# logging. If enabled, prefixes the MSG part of the syslog -# message with APP-NAME (RFC5424). The format without the APP- -# NAME is deprecated in I, and will be removed in J. (boolean -# value) -#use_syslog_rfc_format=false - -# Syslog facility to receive log lines. (string value) -#syslog_log_facility=LOG_USER - - -[baremetal] - -# -# Options defined in tempest.config -# - -# Catalog type of the baremetal provisioning service (string -# value) -#catalog_type=baremetal - -# Whether the Ironic nova-compute driver is enabled (boolean -# value) -#driver_enabled=false - -# The endpoint type to use for the baremetal provisioning -# service (string value) -#endpoint_type=publicURL - -# Timeout for Ironic node to completely provision (integer -# value) -#active_timeout=300 - -# Timeout for association of Nova instance and Ironic node -# (integer value) -#association_timeout=10 - -# Timeout for Ironic power transitions. (integer value) -#power_timeout=20 - -# Timeout for unprovisioning an Ironic node. (integer value) -#unprovision_timeout=20 - - -[boto] - -# -# Options defined in tempest.config -# - -# EC2 URL (string value) -#ec2_url=http://localhost:8773/services/Cloud - -# S3 URL (string value) -#s3_url=http://localhost:8080 - -# AWS Secret Key (string value) -#aws_secret=<None> - -# AWS Access Key (string value) -#aws_access=<None> - -# AWS Zone for EC2 tests (string value) -#aws_zone=nova - -# S3 Materials Path (string value) -#s3_materials_path=/opt/stack/devstack/files/images/s3-materials/cirros-0.3.0 - -# ARI Ramdisk Image manifest (string value) -#ari_manifest=cirros-0.3.0-x86_64-initrd.manifest.xml - -# AMI Machine Image manifest (string value) -#ami_manifest=cirros-0.3.0-x86_64-blank.img.manifest.xml - -# AKI Kernel Image manifest (string value) -#aki_manifest=cirros-0.3.0-x86_64-vmlinuz.manifest.xml - -# Instance type (string value) -#instance_type=m1.tiny - -# boto Http socket timeout (integer value) -#http_socket_timeout=3 - -# boto num_retries on error (integer value) -#num_retries=1 - -# Status Change Timeout (integer value) -#build_timeout=60 - -# Status Change Test Interval (integer value) -#build_interval=1 - - -[cli] - -# -# Options defined in tempest.config -# - -# enable cli tests (boolean value) -#enabled=true - -# directory where python client binaries are located (string -# value) -#cli_dir=/usr/local/bin - -# Whether the tempest run location has access to the *-manage -# commands. In a pure blackbox environment it will not. -# (boolean value) -#has_manage=true - -# Number of seconds to wait on a CLI timeout (integer value) -#timeout=15 - - -[compute] - -# -# Options defined in tempest.config -# - -# Allows test cases to create/destroy tenants and users. This -# option enables isolated test cases and better parallel -# execution, but also requires that OpenStack Identity API -# admin credentials are known. (boolean value) -#allow_tenant_isolation=false - -# Valid primary image reference to be used in tests. (string -# value) -#image_ref={$IMAGE_ID} - -# Valid secondary image reference to be used in tests. (string -# value) -#image_ref_alt={$IMAGE_ID_ALT} - -# Valid primary flavor to use in tests. (string value) -#flavor_ref=1 - -# Valid secondary flavor to be used in tests. (string value) -#flavor_ref_alt=2 - -# User name used to authenticate to an instance. (string -# value) -#image_ssh_user=root - -# Password used to authenticate to an instance. (string value) -#image_ssh_password=password - -# User name used to authenticate to an instance using the -# alternate image. (string value) -#image_alt_ssh_user=root - -# Password used to authenticate to an instance using the -# alternate image. (string value) -#image_alt_ssh_password=password - -# Time in seconds between build status checks. (integer value) -#build_interval=10 - -# Timeout in seconds to wait for an instance to build. -# (integer value) -#build_timeout=300 - -# Should the tests ssh to instances? (boolean value) -#run_ssh=false - -# Auth method used for authenticate to the instance. Valid -# choices are: keypair, configured, adminpass. keypair: start -# the servers with an ssh keypair. configured: use the -# configured user and password. adminpass: use the injected -# adminPass. disabled: avoid using ssh when it is an option. -# (string value) -#ssh_auth_method=keypair - -# How to connect to the instance? fixed: using the first ip -# belongs the fixed network floating: creating and using a -# floating ip (string value) -#ssh_connect_method=fixed - -# User name used to authenticate to an instance. (string -# value) -#ssh_user=root - -# Timeout in seconds to wait for ping to succeed. (integer -# value) -#ping_timeout=120 - -# Timeout in seconds to wait for authentication to succeed. -# (integer value) -#ssh_timeout=300 - -# Additional wait time for clean state, when there is no OS- -# EXT-STS extension available (integer value) -#ready_wait=0 - -# Timeout in seconds to wait for output from ssh channel. -# (integer value) -#ssh_channel_timeout=60 - -# Visible fixed network name (string value) -#fixed_network_name=private - -# Network used for SSH connections. (string value) -#network_for_ssh=public - -# IP version used for SSH connections. (integer value) -#ip_version_for_ssh=4 - -# Does SSH use Floating IPs? (boolean value) -#use_floatingip_for_ssh=true - -# Catalog type of the Compute service. (string value) -#catalog_type=compute - -# The compute region name to use. If empty, the value of -# identity.region is used instead. If no such region is found -# in the service catalog, the first found one is used. (string -# value) -#region= - -# The endpoint type to use for the compute service. (string -# value) -#endpoint_type=publicURL - -# Catalog type of the Compute v3 service. (string value) -#catalog_v3_type=computev3 - -# Path to a private key file for SSH access to remote hosts -# (string value) -#path_to_private_key=<None> - -# Expected device name when a volume is attached to an -# instance (string value) -#volume_device_name=vdb - -# Time in seconds before a shelved instance is eligible for -# removing from a host. -1 never offload, 0 offload when -# shelved. This time should be the same as the time of -# nova.conf, and some tests will run for as long as the time. -# (integer value) -#shelved_offload_time=0 - -# Allows test cases to create/destroy tenants and users. This -# option enables isolated test cases and better parallel -# execution, but also requires that OpenStack Identity API -# admin credentials are known. (boolean value) -#allow_tenant_isolation=false - - -[compute-admin] - -# -# Options defined in tempest.config -# - -# Administrative Username to use for Nova API requests. -# (string value) -#username=<None> - -# Administrative Tenant name to use for Nova API requests. -# (string value) -#tenant_name=<None> - -# Domain name for authentication as admin (Keystone V3).The -# same domain applies to user and project (string value) -#domain_name=<None> - - -[compute-feature-enabled] - -# -# Options defined in tempest.config -# - -# If false, skip all nova v3 tests. (boolean value) -#api_v3=true - -# If false, skip disk config tests (boolean value) -#disk_config=true - -# A list of enabled compute extensions with a special entry -# all which indicates every extension is enabled (list value) -#api_extensions=all - -# A list of enabled v3 extensions with a special entry all -# which indicates every extension is enabled (list value) -#api_v3_extensions=all - -# Does the test environment support changing the admin -# password? (boolean value) -#change_password=false - -# Does the test environment support resizing? (boolean value) -#resize=false - -# Does the test environment support pausing? (boolean value) -#pause=true - -# Does the test environment support suspend/resume? (boolean -# value) -#suspend=true - -# Does the test environment support live migration available? -# (boolean value) -#live_migration=false - -# Does the test environment use block devices for live -# migration (boolean value) -#block_migration_for_live_migration=false - -# Does the test environment block migration support cinder -# iSCSI volumes (boolean value) -#block_migrate_cinder_iscsi=false - -# Enable VNC console. This configuration value should be same -# as [nova.vnc]->vnc_enabled in nova.conf (boolean value) -#vnc_console=false - -# Enable Spice console. This configuration value should be -# same as [nova.spice]->enabled in nova.conf (boolean value) -#spice_console=false - -# Enable RDP console. This configuration value should be same -# as [nova.rdp]->enabled in nova.conf (boolean value) -#rdp_console=false - - -[dashboard] - -# -# Options defined in tempest.config -# - -# Where the dashboard can be found (string value) -#dashboard_url=http://localhost/ - -# Login page for the dashboard (string value) -#login_url=http://localhost/auth/login/ - - -[data_processing] - -# -# Options defined in tempest.config -# - -# Catalog type of the data processing service. (string value) -#catalog_type=data_processing - -# The endpoint type to use for the data processing service. -# (string value) -#endpoint_type=publicURL - - -[database] - -# -# Options defined in tempest.config -# - -# Catalog type of the Database service. (string value) -#catalog_type=database - -# Valid primary flavor to use in database tests. (string -# value) -#db_flavor_ref=1 - -# Current database version to use in database tests. (string -# value) -#db_current_version=v1.0 - - -[debug] - -# -# Options defined in tempest.config -# - -# Enable diagnostic commands (boolean value) -#enable=true - -# A regex to determine which requests should be traced. This -# is a regex to match the caller for rest client requests to -# be able to selectively trace calls out of specific classes -# and methods. It largely exists for test development, and is -# not expected to be used in a real deploy of tempest. This -# will be matched against the discovered ClassName:method in -# the test environment. Expected values for this field are: -# * ClassName:test_method_name - traces one test_method * -# ClassName:setUp(Class) - traces specific setup functions * -# ClassName:tearDown(Class) - traces specific teardown -# functions * ClassName:_run_cleanups - traces the cleanup -# functions If nothing is specified, this feature is not -# enabled. To trace everything specify .* as the regex. -# (string value) -#trace_requests= - - -[dns] - -# -# Options defined in tempest.config -# - -# Catalog type of the Dns service. (string value) -#catalog_type=dns - - -[dns-admin] - -# -# Options defined in tempest.config -# - -# API key to use when authenticating as admin. (string value) -#password=<None> - -# Administrative Username to use for Designate API requests. -# (string value) -#username=<None> - -# Administrative Tenant name to use for Designate API -# requests. (string value) -#tenant_name=<None> - -# API key to use when authenticating as admin. (string value) -#password=<None> - - -[identity] - -# -# Options defined in tempest.config -# - -# Catalog type of the Identity service. (string value) -#catalog_type=identity - -# Set to True if using self-signed SSL certificates. (boolean -# value) -#disable_ssl_certificate_validation=false - -# Full URI of the OpenStack Identity API (Keystone), v2 -# (string value) -#uri=<None> - -# Full URI of the OpenStack Identity API (Keystone), v3 -# (string value) -#uri_v3=<None> - -# Identity API version to be used for authentication for API -# tests. (string value) -#auth_version=v2 - -# The identity region name to use. Also used as the other -# services' region name unless they are set explicitly. If no -# such region is found in the service catalog, the first found -# one is used. (string value) -#region=RegionOne - -# The endpoint type to use for the identity service. (string -# value) -#endpoint_type=publicURL - -# Username to use for Nova API requests. (string value) -#username=<None> - -# Tenant name to use for Nova API requests. (string value) -#tenant_name=<None> - -# Role required to administrate keystone. (string value) -#admin_role=admin - -# API key to use when authenticating. (string value) -#password=<None> - -# Domain name for authentication (Keystone V3).The same domain -# applies to user and project (string value) -#domain_name=<None> - -# Username of alternate user to use for Nova API requests. -# (string value) -#alt_username=<None> - -# Alternate user's Tenant name to use for Nova API requests. -# (string value) -#alt_tenant_name=<None> - -# API key to use when authenticating as alternate user. -# (string value) -#alt_password=<None> - -# Alternate domain name for authentication (Keystone V3).The -# same domain applies to user and project (string value) -#alt_domain_name=<None> - -# Administrative Username to use for Keystone API requests. -# (string value) -#admin_username=<None> - -# Administrative Tenant name to use for Keystone API requests. -# (string value) -#admin_tenant_name=<None> - -# API key to use when authenticating as admin. (string value) -#admin_password=<None> - -# Admin domain name for authentication (Keystone V3).The same -# domain applies to user and project (string value) -#admin_domain_name=<None> - - -[identity-feature-enabled] - -# -# Options defined in tempest.config -# - -# Does the identity service have delegation and impersonation -# enabled (boolean value) -#trust=true - -# Is the v2 identity API enabled (boolean value) -#api_v2=true - -# Is the v3 identity API enabled (boolean value) -#api_v3=true - - -[image] - -# -# Options defined in tempest.config -# - -# Catalog type of the Image service. (string value) -#catalog_type=image - -# The image region name to use. If empty, the value of -# identity.region is used instead. If no such region is found -# in the service catalog, the first found one is used. (string -# value) -#region= - -# The endpoint type to use for the image service. (string -# value) -#endpoint_type=publicURL - -# http accessible image (string value) -#http_image=http://download.cirros-cloud.net/0.3.1/cirros-0.3.1-x86_64-uec.tar.gz - - -[image-feature-enabled] - -# -# Options defined in tempest.config -# - -# Is the v2 image API enabled (boolean value) -#api_v2=true - -# Is the v1 image API enabled (boolean value) -#api_v1=true - - -[input-scenario] - -# -# Options defined in tempest.config -# - -# Matching images become parameters for scenario tests (string -# value) -#image_regex=^cirros-0.3.1-x86_64-uec$ - -# Matching flavors become parameters for scenario tests -# (string value) -#flavor_regex=^m1.nano$ - -# SSH verification in tests is skippedfor matching images -# (string value) -#non_ssh_image_regex=^.*[Ww]in.*$ - -# List of user mapped to regex to matching image names. -# (string value) -#ssh_user_regex=[["^.*[Cc]irros.*$", "root"]] - - -[negative] - -# -# Options defined in tempest.config -# - -# Test generator class for all negative tests (string value) -#test_generator=tempest.common.generator.negative_generator.NegativeTestGenerator - - -[network] - -# -# Options defined in tempest.config -# - -# Catalog type of the Neutron service. (string value) -#catalog_type=network - -# The network region name to use. If empty, the value of -# identity.region is used instead. If no such region is found -# in the service catalog, the first found one is used. (string -# value) -#region= - -# The endpoint type to use for the network service. (string -# value) -#endpoint_type=publicURL - -# The cidr block to allocate tenant ipv4 subnets from (string -# value) -#tenant_network_cidr=10.100.0.0/16 - -# The mask bits for tenant ipv4 subnets (integer value) -#tenant_network_mask_bits=28 - -# The cidr block to allocate tenant ipv6 subnets from (string -# value) -#tenant_network_v6_cidr=2003::/64 - -# The mask bits for tenant ipv6 subnets (integer value) -#tenant_network_v6_mask_bits=96 - -# Whether tenant network connectivity should be evaluated -# directly (boolean value) -#tenant_networks_reachable=false - -# Id of the public network that provides external connectivity -# (string value) -#public_network_id= - -# Id of the public router that provides external connectivity -# (string value) -#public_router_id= - -# Timeout in seconds to wait for network operation to -# complete. (integer value) -#build_timeout=300 - -# Time in seconds between network operation status checks. -# (integer value) -#build_interval=10 - - -[network-feature-enabled] - -# -# Options defined in tempest.config -# - -# Allow the execution of IPv6 tests (boolean value) -#ipv6=true - -# A list of enabled network extensions with a special entry -# all which indicates every extension is enabled (list value) -#api_extensions=all - - -[object-storage] - -# -# Options defined in tempest.config -# - -# Catalog type of the Object-Storage service. (string value) -#catalog_type=object-store - -# The object-storage region name to use. If empty, the value -# of identity.region is used instead. If no such region is -# found in the service catalog, the first found one is used. -# (string value) -#region= - -# The endpoint type to use for the object-store service. -# (string value) -#endpoint_type=publicURL - -# Number of seconds to time on waiting for a container to -# container synchronization complete. (integer value) -#container_sync_timeout=120 - -# Number of seconds to wait while looping to check the status -# of a container to container synchronization (integer value) -#container_sync_interval=5 - -# Role to add to users created for swift tests to enable -# creating containers (string value) -#operator_role=Member - -# User role that has reseller admin (string value) -#reseller_admin_role=ResellerAdmin - - -[object-storage-feature-enabled] - -# -# Options defined in tempest.config -# - -# A list of the enabled optional discoverable apis. A single -# entry, all, indicates that all of these features are -# expected to be enabled (list value) -#discoverable_apis=all - - -[orchestration] - -# -# Options defined in tempest.config -# - -# Catalog type of the Orchestration service. (string value) -#catalog_type=orchestration - -# The orchestration region name to use. If empty, the value of -# identity.region is used instead. If no such region is found -# in the service catalog, the first found one is used. (string -# value) -#region= - -# The endpoint type to use for the orchestration service. -# (string value) -#endpoint_type=publicURL - -# Time in seconds between build status checks. (integer value) -#build_interval=1 - -# Timeout in seconds to wait for a stack to build. (integer -# value) -#build_timeout=1200 - -# Instance type for tests. Needs to be big enough for a full -# OS plus the test workload (string value) -#instance_type=m1.micro - -# Name of heat-cfntools enabled image to use when launching -# test instances. (string value) -#image_ref=<None> - -# Name of existing keypair to launch servers with. (string -# value) -#keypair_name=<None> - -# Value must match heat configuration of the same name. -# (integer value) -#max_template_size=524288 - -# Value must match heat configuration of the same name. -# (integer value) -#max_resources_per_stack=1000 - - -[queuing] - -# -# Options defined in tempest.config -# - -# Catalog type of the Queuing service. (string value) -#catalog_type=queuing - - -[scenario] - -# -# Options defined in tempest.config -# - -# Directory containing image files (string value) -#img_dir=/opt/stack/new/devstack/files/images/cirros-0.3.1-x86_64-uec - -# QCOW2 image file name (string value) -#qcow2_img_file=cirros-0.3.1-x86_64-disk.img - -# AMI image file name (string value) -#ami_img_file=cirros-0.3.1-x86_64-blank.img - -# ARI image file name (string value) -#ari_img_file=cirros-0.3.1-x86_64-initrd - -# AKI image file name (string value) -#aki_img_file=cirros-0.3.1-x86_64-vmlinuz - -# ssh username for the image file (string value) -#ssh_user=cirros - -# specifies how many resources to request at once. Used for -# large operations testing. (integer value) -#large_ops_number=0 - - -[service_available] - -# -# Options defined in tempest.config -# - -# Whether or not cinder is expected to be available (boolean -# value) -#cinder=true - -# Whether or not neutron is expected to be available (boolean -# value) -#neutron=false - -# Whether or not glance is expected to be available (boolean -# value) -#glance=true - -# Whether or not swift is expected to be available (boolean -# value) -#swift=true - -# Whether or not nova is expected to be available (boolean -# value) -#nova=true - -# Whether or not Heat is expected to be available (boolean -# value) -#heat=false - -# Whether or not Ceilometer is expected to be available -# (boolean value) -#ceilometer=true - -# Whether or not Horizon is expected to be available (boolean -# value) -#horizon=true - -# Whether or not Sahara is expected to be available (boolean -# value) -#sahara=false - -# Whether or not Ironic is expected to be available (boolean -# value) -#ironic=false - -# Whether or not Trove is expected to be available (boolean -# value) -#trove=false - -# Whether or not Designate is expected to be available -# (boolean value) -#designate=false - -# Whether or not Marconi is expected to be available (boolean -# value) -#marconi=false - - -[stress] - -# -# Options defined in tempest.config -# - -# Directory containing log files on the compute nodes (string -# value) -#nova_logdir=<None> - -# Maximum number of instances to create during test. (integer -# value) -#max_instances=16 - -# Controller host. (string value) -#controller=<None> - -# Controller host. (string value) -#target_controller=<None> - -# ssh user. (string value) -#target_ssh_user=<None> - -# Path to private key. (string value) -#target_private_key_path=<None> - -# regexp for list of log files. (string value) -#target_logfiles=<None> - -# time (in seconds) between log file error checks. (integer -# value) -#log_check_interval=60 - -# The number of threads created while stress test. (integer -# value) -#default_thread_number_per_action=4 - -# Prevent the cleaning (tearDownClass()) between each stress -# test run if an exception occurs during this run. (boolean -# value) -#leave_dirty_stack=false - -# Allows a full cleaning process after a stress test. Caution -# : this cleanup will remove every objects of every tenant. -# (boolean value) -#full_clean_stack=false - - -[telemetry] - -# -# Options defined in tempest.config -# - -# Catalog type of the Telemetry service. (string value) -#catalog_type=metering - -# The endpoint type to use for the telemetry service. (string -# value) -#endpoint_type=publicURL - - -[volume] - -# -# Options defined in tempest.config -# - -# Time in seconds between volume availability checks. (integer -# value) -#build_interval=10 - -# Timeout in seconds to wait for a volume to becomeavailable. -# (integer value) -#build_timeout=300 - -# Catalog type of the Volume Service (string value) -#catalog_type=volume - -# The volume region name to use. If empty, the value of -# identity.region is used instead. If no such region is found -# in the service catalog, the first found one is used. (string -# value) -#region= - -# The endpoint type to use for the volume service. (string -# value) -#endpoint_type=publicURL - -# Name of the backend1 (must be declared in cinder.conf) -# (string value) -#backend1_name=BACKEND_1 - -# Name of the backend2 (must be declared in cinder.conf) -# (string value) -#backend2_name=BACKEND_2 - -# Backend protocol to target when creating volume types -# (string value) -#storage_protocol=iSCSI - -# Backend vendor to target when creating volume types (string -# value) -#vendor_name=Open Source - -# Disk format to use when copying a volume to image (string -# value) -#disk_format=raw - -# Default size in GB for volumes created by volumes tests -# (integer value) -#volume_size=1 - - -[volume-feature-enabled] - -# -# Options defined in tempest.config -# - -# Runs Cinder multi-backend test (requires 2 backends) -# (boolean value) -#multi_backend=false - -# Runs Cinder volumes backup test (boolean value) -#backup=true - -# Runs Cinder volume snapshot test (boolean value) -#snapshot=true - -# A list of enabled volume extensions with a special entry all -# which indicates every extension is enabled (list value) -#api_extensions=all - -# Is the v1 volume API enabled (boolean value) -#api_v1=true - -# Is the v2 volume API enabled (boolean value) -#api_v2=true - - |