From 0a960a04d4bfbcc8b6ac8dbaa9cc1cfecd78ef08 Mon Sep 17 00:00:00 2001 From: SunithaGudisagar Date: Mon, 2 Dec 2024 11:39:20 +0530 Subject: [PATCH] Added acceptance test and maturity --- .../github.com/IBM/vpc-go-sdk/vpcv1/vpc_v1.go | 42 ++++----- ibm/provider/provider.go | 92 ++++++++++--------- .../vpc/data_source_ibm_is_image_test.go | 4 + .../vpc/data_source_ibm_is_images_test.go | 4 + .../vpc/data_source_ibm_is_snapshot_test.go | 4 + .../vpc/data_source_ibm_is_snapshots_test.go | 4 + .../vpc/data_source_ibm_is_volume_test.go | 8 ++ .../vpc/data_source_ibm_is_volumes_test.go | 8 ++ 8 files changed, 101 insertions(+), 65 deletions(-) diff --git a/common/github.com/IBM/vpc-go-sdk/vpcv1/vpc_v1.go b/common/github.com/IBM/vpc-go-sdk/vpcv1/vpc_v1.go index a8c43ad657..965c92c203 100644 --- a/common/github.com/IBM/vpc-go-sdk/vpcv1/vpc_v1.go +++ b/common/github.com/IBM/vpc-go-sdk/vpcv1/vpc_v1.go @@ -4243,7 +4243,7 @@ func (vpc *VpcV1) CreateImageWithContext(ctx context.Context, createImageOptions } builder.AddHeader("Accept", "application/json") builder.AddHeader("Content-Type", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -4416,7 +4416,7 @@ func (vpc *VpcV1) DeleteImageWithContext(ctx context.Context, deleteImageOptions for headerName, headerValue := range sdkHeaders { builder.AddHeader(headerName, headerValue) } - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -4617,7 +4617,7 @@ func (vpc *VpcV1) GetImageWithContext(ctx context.Context, getImageOptions *GetI builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -4836,7 +4836,7 @@ func (vpc *VpcV1) ListImageBareMetalServerProfilesWithContext(ctx context.Contex builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listImageBareMetalServerProfilesOptions.Start != nil { @@ -4996,7 +4996,7 @@ func (vpc *VpcV1) ListImageInstanceProfilesWithContext(ctx context.Context, list builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listImageInstanceProfilesOptions.Start != nil { @@ -5066,7 +5066,7 @@ func (vpc *VpcV1) ListImagesWithContext(ctx context.Context, listImagesOptions * builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listImagesOptions.Start != nil { @@ -5302,7 +5302,7 @@ func (vpc *VpcV1) UpdateImageWithContext(ctx context.Context, updateImageOptions } builder.AddHeader("Accept", "application/json") builder.AddHeader("Content-Type", "application/merge-patch+json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -6011,7 +6011,7 @@ func (vpc *VpcV1) CreateInstanceWithContext(ctx context.Context, createInstanceO } builder.AddHeader("Accept", "application/json") builder.AddHeader("Content-Type", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -7033,7 +7033,7 @@ func (vpc *VpcV1) GetInstanceWithContext(ctx context.Context, getInstanceOptions builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -8499,7 +8499,7 @@ func (vpc *VpcV1) ListInstancesWithContext(ctx context.Context, listInstancesOpt builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listInstancesOptions.Start != nil { @@ -8700,7 +8700,7 @@ func (vpc *VpcV1) UpdateInstanceWithContext(ctx context.Context, updateInstanceO if updateInstanceOptions.IfMatch != nil { builder.AddHeader("If-Match", fmt.Sprint(*updateInstanceOptions.IfMatch)) } - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -15688,7 +15688,7 @@ func (vpc *VpcV1) CreateVolumeWithContext(ctx context.Context, createVolumeOptio } builder.AddHeader("Accept", "application/json") builder.AddHeader("Content-Type", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -15832,7 +15832,7 @@ func (vpc *VpcV1) GetVolumeWithContext(ctx context.Context, getVolumeOptions *Ge builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -15978,7 +15978,7 @@ func (vpc *VpcV1) ListVolumeInstanceProfilesWithContext(ctx context.Context, lis builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listVolumeInstanceProfilesOptions.Start != nil { @@ -16118,7 +16118,7 @@ func (vpc *VpcV1) ListVolumesWithContext(ctx context.Context, listVolumesOptions builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listVolumesOptions.Start != nil { @@ -16222,7 +16222,7 @@ func (vpc *VpcV1) UpdateVolumeWithContext(ctx context.Context, updateVolumeOptio if updateVolumeOptions.IfMatch != nil { builder.AddHeader("If-Match", fmt.Sprint(*updateVolumeOptions.IfMatch)) } - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -16298,7 +16298,7 @@ func (vpc *VpcV1) CreateSnapshotWithContext(ctx context.Context, createSnapshotO } builder.AddHeader("Accept", "application/json") builder.AddHeader("Content-Type", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -16529,7 +16529,7 @@ func (vpc *VpcV1) DeleteSnapshotWithContext(ctx context.Context, deleteSnapshotO if deleteSnapshotOptions.IfMatch != nil { builder.AddHeader("If-Match", fmt.Sprint(*deleteSnapshotOptions.IfMatch)) } - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -16788,7 +16788,7 @@ func (vpc *VpcV1) GetSnapshotWithContext(ctx context.Context, getSnapshotOptions builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) @@ -17161,7 +17161,7 @@ func (vpc *VpcV1) ListSnapshotInstanceProfilesWithContext(ctx context.Context, l builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listSnapshotInstanceProfilesOptions.Start != nil { @@ -17231,7 +17231,7 @@ func (vpc *VpcV1) ListSnapshotsWithContext(ctx context.Context, listSnapshotsOpt builder.AddHeader(headerName, headerValue) } builder.AddHeader("Accept", "application/json") - + builder.AddQuery("maturity", fmt.Sprint("development")) builder.AddQuery("version", fmt.Sprint(*vpc.Version)) builder.AddQuery("generation", fmt.Sprint(*vpc.Generation)) if listSnapshotsOptions.Start != nil { diff --git a/ibm/provider/provider.go b/ibm/provider/provider.go index eab13bce4b..f2f64b64a3 100644 --- a/ibm/provider/provider.go +++ b/ibm/provider/provider.go @@ -442,50 +442,52 @@ func Provider() *schema.Provider { "ibm_is_instance_cluster_network_attachment": vpc.DataSourceIBMIsInstanceClusterNetworkAttachment(), "ibm_is_instance_cluster_network_attachments": vpc.DataSourceIBMIsInstanceClusterNetworkAttachments(), - "ibm_is_dedicated_host": vpc.DataSourceIbmIsDedicatedHost(), - "ibm_is_dedicated_hosts": vpc.DataSourceIbmIsDedicatedHosts(), - "ibm_is_dedicated_host_profile": vpc.DataSourceIbmIsDedicatedHostProfile(), - "ibm_is_dedicated_host_profiles": vpc.DataSourceIbmIsDedicatedHostProfiles(), - "ibm_is_dedicated_host_group": vpc.DataSourceIbmIsDedicatedHostGroup(), - "ibm_is_dedicated_host_groups": vpc.DataSourceIbmIsDedicatedHostGroups(), - "ibm_is_dedicated_host_disk": vpc.DataSourceIbmIsDedicatedHostDisk(), - "ibm_is_dedicated_host_disks": vpc.DataSourceIbmIsDedicatedHostDisks(), - "ibm_is_placement_group": vpc.DataSourceIbmIsPlacementGroup(), - "ibm_is_placement_groups": vpc.DataSourceIbmIsPlacementGroups(), - "ibm_is_floating_ip": vpc.DataSourceIBMISFloatingIP(), - "ibm_is_floating_ips": vpc.DataSourceIBMIsFloatingIps(), - "ibm_is_flow_log": vpc.DataSourceIBMIsFlowLog(), - "ibm_is_flow_logs": vpc.DataSourceIBMISFlowLogs(), - "ibm_is_image": vpc.DataSourceIBMISImage(), - "ibm_is_images": vpc.DataSourceIBMISImages(), - "ibm_is_image_export_job": vpc.DataSourceIBMIsImageExport(), - "ibm_is_image_export_jobs": vpc.DataSourceIBMIsImageExports(), - "ibm_is_endpoint_gateway_targets": vpc.DataSourceIBMISEndpointGatewayTargets(), - "ibm_is_instance_group": vpc.DataSourceIBMISInstanceGroup(), - "ibm_is_instance_groups": vpc.DataSourceIBMISInstanceGroups(), - "ibm_is_instance_group_memberships": vpc.DataSourceIBMISInstanceGroupMemberships(), - "ibm_is_instance_group_membership": vpc.DataSourceIBMISInstanceGroupMembership(), - "ibm_is_instance_group_manager": vpc.DataSourceIBMISInstanceGroupManager(), - "ibm_is_instance_group_managers": vpc.DataSourceIBMISInstanceGroupManagers(), - "ibm_is_instance_group_manager_policies": vpc.DataSourceIBMISInstanceGroupManagerPolicies(), - "ibm_is_instance_group_manager_policy": vpc.DataSourceIBMISInstanceGroupManagerPolicy(), - "ibm_is_instance_group_manager_action": vpc.DataSourceIBMISInstanceGroupManagerAction(), - "ibm_is_instance_group_manager_actions": vpc.DataSourceIBMISInstanceGroupManagerActions(), - "ibm_is_virtual_endpoint_gateways": vpc.DataSourceIBMISEndpointGateways(), - "ibm_is_virtual_endpoint_gateway_ips": vpc.DataSourceIBMISEndpointGatewayIPs(), - "ibm_is_virtual_endpoint_gateway": vpc.DataSourceIBMISEndpointGateway(), - "ibm_is_instance_template": vpc.DataSourceIBMISInstanceTemplate(), - "ibm_is_instance_templates": vpc.DataSourceIBMISInstanceTemplates(), - "ibm_is_instance_profile": vpc.DataSourceIBMISInstanceProfile(), - "ibm_is_instance_profiles": vpc.DataSourceIBMISInstanceProfiles(), - "ibm_is_instance": vpc.DataSourceIBMISInstance(), - "ibm_is_instances": vpc.DataSourceIBMISInstances(), - "ibm_is_instance_network_attachment": vpc.DataSourceIBMIsInstanceNetworkAttachment(), - "ibm_is_instance_network_attachments": vpc.DataSourceIBMIsInstanceNetworkAttachments(), - "ibm_is_instance_network_interface": vpc.DataSourceIBMIsInstanceNetworkInterface(), - "ibm_is_instance_network_interfaces": vpc.DataSourceIBMIsInstanceNetworkInterfaces(), - "ibm_is_instance_disk": vpc.DataSourceIbmIsInstanceDisk(), - "ibm_is_instance_disks": vpc.DataSourceIbmIsInstanceDisks(), + "ibm_is_dedicated_host": vpc.DataSourceIbmIsDedicatedHost(), + "ibm_is_dedicated_hosts": vpc.DataSourceIbmIsDedicatedHosts(), + "ibm_is_dedicated_host_profile": vpc.DataSourceIbmIsDedicatedHostProfile(), + "ibm_is_dedicated_host_profiles": vpc.DataSourceIbmIsDedicatedHostProfiles(), + "ibm_is_dedicated_host_group": vpc.DataSourceIbmIsDedicatedHostGroup(), + "ibm_is_dedicated_host_groups": vpc.DataSourceIbmIsDedicatedHostGroups(), + "ibm_is_dedicated_host_disk": vpc.DataSourceIbmIsDedicatedHostDisk(), + "ibm_is_dedicated_host_disks": vpc.DataSourceIbmIsDedicatedHostDisks(), + "ibm_is_placement_group": vpc.DataSourceIbmIsPlacementGroup(), + "ibm_is_placement_groups": vpc.DataSourceIbmIsPlacementGroups(), + "ibm_is_floating_ip": vpc.DataSourceIBMISFloatingIP(), + "ibm_is_floating_ips": vpc.DataSourceIBMIsFloatingIps(), + "ibm_is_flow_log": vpc.DataSourceIBMIsFlowLog(), + "ibm_is_flow_logs": vpc.DataSourceIBMISFlowLogs(), + "ibm_is_image": vpc.DataSourceIBMISImage(), + "ibm_is_images": vpc.DataSourceIBMISImages(), + "ibm_is_image_bare_metal_server_profiles": vpc.DataSourceIBMIsImageBareMetalServerProfiles(), + "ibm_is_image_instance_profiles": vpc.DataSourceIBMIsImageInstanceProfiles(), + "ibm_is_image_export_job": vpc.DataSourceIBMIsImageExport(), + "ibm_is_image_export_jobs": vpc.DataSourceIBMIsImageExports(), + "ibm_is_endpoint_gateway_targets": vpc.DataSourceIBMISEndpointGatewayTargets(), + "ibm_is_instance_group": vpc.DataSourceIBMISInstanceGroup(), + "ibm_is_instance_groups": vpc.DataSourceIBMISInstanceGroups(), + "ibm_is_instance_group_memberships": vpc.DataSourceIBMISInstanceGroupMemberships(), + "ibm_is_instance_group_membership": vpc.DataSourceIBMISInstanceGroupMembership(), + "ibm_is_instance_group_manager": vpc.DataSourceIBMISInstanceGroupManager(), + "ibm_is_instance_group_managers": vpc.DataSourceIBMISInstanceGroupManagers(), + "ibm_is_instance_group_manager_policies": vpc.DataSourceIBMISInstanceGroupManagerPolicies(), + "ibm_is_instance_group_manager_policy": vpc.DataSourceIBMISInstanceGroupManagerPolicy(), + "ibm_is_instance_group_manager_action": vpc.DataSourceIBMISInstanceGroupManagerAction(), + "ibm_is_instance_group_manager_actions": vpc.DataSourceIBMISInstanceGroupManagerActions(), + "ibm_is_virtual_endpoint_gateways": vpc.DataSourceIBMISEndpointGateways(), + "ibm_is_virtual_endpoint_gateway_ips": vpc.DataSourceIBMISEndpointGatewayIPs(), + "ibm_is_virtual_endpoint_gateway": vpc.DataSourceIBMISEndpointGateway(), + "ibm_is_instance_template": vpc.DataSourceIBMISInstanceTemplate(), + "ibm_is_instance_templates": vpc.DataSourceIBMISInstanceTemplates(), + "ibm_is_instance_profile": vpc.DataSourceIBMISInstanceProfile(), + "ibm_is_instance_profiles": vpc.DataSourceIBMISInstanceProfiles(), + "ibm_is_instance": vpc.DataSourceIBMISInstance(), + "ibm_is_instances": vpc.DataSourceIBMISInstances(), + "ibm_is_instance_network_attachment": vpc.DataSourceIBMIsInstanceNetworkAttachment(), + "ibm_is_instance_network_attachments": vpc.DataSourceIBMIsInstanceNetworkAttachments(), + "ibm_is_instance_network_interface": vpc.DataSourceIBMIsInstanceNetworkInterface(), + "ibm_is_instance_network_interfaces": vpc.DataSourceIBMIsInstanceNetworkInterfaces(), + "ibm_is_instance_disk": vpc.DataSourceIbmIsInstanceDisk(), + "ibm_is_instance_disks": vpc.DataSourceIbmIsInstanceDisks(), // reserved ips "ibm_is_instance_network_interface_reserved_ip": vpc.DataSourceIBMISInstanceNICReservedIP(), @@ -541,6 +543,7 @@ func Provider() *schema.Provider { "ibm_is_snapshot_consistency_group": vpc.DataSourceIBMIsSnapshotConsistencyGroup(), "ibm_is_snapshot_consistency_groups": vpc.DataSourceIBMIsSnapshotConsistencyGroups(), "ibm_is_snapshots": vpc.DataSourceSnapshots(), + "ibm_is_snapshot_instance_profiles": vpc.DataSourceIBMIsSnapshotInstanceProfiles(), "ibm_is_share": vpc.DataSourceIbmIsShare(), "ibm_is_source_share": vpc.DataSourceIbmIsSourceShare(), "ibm_is_shares": vpc.DataSourceIbmIsShares(), @@ -564,6 +567,7 @@ func Provider() *schema.Provider { "ibm_is_volumes": vpc.DataSourceIBMIsVolumes(), "ibm_is_volume_profile": vpc.DataSourceIBMISVolumeProfile(), "ibm_is_volume_profiles": vpc.DataSourceIBMISVolumeProfiles(), + "ibm_is_volume_instance_profiles": vpc.DataSourceIBMIsVolumeInstanceProfiles(), "ibm_is_vpc": vpc.DataSourceIBMISVPC(), "ibm_is_vpc_dns_resolution_binding": vpc.DataSourceIBMIsVPCDnsResolutionBinding(), "ibm_is_vpc_dns_resolution_bindings": vpc.DataSourceIBMIsVPCDnsResolutionBindings(), diff --git a/ibm/service/vpc/data_source_ibm_is_image_test.go b/ibm/service/vpc/data_source_ibm_is_image_test.go index 552d7f0e81..b36312dbaf 100644 --- a/ibm/service/vpc/data_source_ibm_is_image_test.go +++ b/ibm/service/vpc/data_source_ibm_is_image_test.go @@ -30,6 +30,10 @@ func TestAccIBMISImageDataSource_basic(t *testing.T) { resource.TestCheckResourceAttrSet(resName, "architecture"), resource.TestCheckResourceAttrSet(resName, "visibility"), resource.TestCheckResourceAttrSet(resName, "status"), + resource.TestCheckResourceAttrSet(resName, "allowed_use.#"), + resource.TestCheckResourceAttrSet(resName, "allowed_use.0.api_version"), + resource.TestCheckResourceAttrSet(resName, "allowed_use.0.bare_metal_server"), + resource.TestCheckResourceAttrSet(resName, "allowed_use.0.instance"), ), }, }, diff --git a/ibm/service/vpc/data_source_ibm_is_images_test.go b/ibm/service/vpc/data_source_ibm_is_images_test.go index 08c30998de..428a2bc9fd 100644 --- a/ibm/service/vpc/data_source_ibm_is_images_test.go +++ b/ibm/service/vpc/data_source_ibm_is_images_test.go @@ -53,6 +53,10 @@ func TestAccIBMISImagesDataSource_All(t *testing.T) { resource.TestCheckResourceAttrSet(resName, "images.0.status"), resource.TestCheckResourceAttrSet(resName, "images.0.resource_group.0.id"), resource.TestCheckResourceAttrSet(resName, "images.0.resource_group.0.name"), + resource.TestCheckResourceAttrSet(resName, "images.0.allowed_use.#"), + resource.TestCheckResourceAttrSet(resName, "images.0.allowed_use.0.api_version"), + resource.TestCheckResourceAttrSet(resName, "images.0.allowed_use.0.bare_metal_server"), + resource.TestCheckResourceAttrSet(resName, "images.0.allowed_use.0.instance"), ), }, }, diff --git a/ibm/service/vpc/data_source_ibm_is_snapshot_test.go b/ibm/service/vpc/data_source_ibm_is_snapshot_test.go index 7d3febec0e..ec6a8b3493 100644 --- a/ibm/service/vpc/data_source_ibm_is_snapshot_test.go +++ b/ibm/service/vpc/data_source_ibm_is_snapshot_test.go @@ -162,6 +162,10 @@ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCKVmnMOlHKcZK8tpt3MP1lqOLAcqcJzhsvJcjscgVE resource.TestCheckResourceAttrSet(snpName, "catalog_offering.#"), resource.TestCheckResourceAttrSet(snpName, "catalog_offering.0.version_crn"), resource.TestCheckResourceAttrSet(snpName, "catalog_offering.0.plan_crn"), + resource.TestCheckResourceAttrSet(snpName, "allowed_use.#"), + resource.TestCheckResourceAttrSet(snpName, "allowed_use.0.bare_metal_server"), + resource.TestCheckResourceAttrSet(snpName, "allowed_use.0.instance"), + resource.TestCheckResourceAttrSet(snpName, "allowed_use.0.api_version"), ), }, }, diff --git a/ibm/service/vpc/data_source_ibm_is_snapshots_test.go b/ibm/service/vpc/data_source_ibm_is_snapshots_test.go index 59e7dc95a6..e652a708be 100644 --- a/ibm/service/vpc/data_source_ibm_is_snapshots_test.go +++ b/ibm/service/vpc/data_source_ibm_is_snapshots_test.go @@ -119,6 +119,10 @@ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCKVmnMOlHKcZK8tpt3MP1lqOLAcqcJzhsvJcjscgVE resource.TestCheckResourceAttrSet(snpName, "snapshots.0.catalog_offering.#"), resource.TestCheckResourceAttrSet(snpName, "snapshots.0.catalog_offering.0.plan_crn"), resource.TestCheckResourceAttrSet(snpName, "snapshots.0.catalog_offering.0.version_crn"), + resource.TestCheckResourceAttrSet(snpName, "snapshots.0.allowed_use.#"), + resource.TestCheckResourceAttrSet(snpName, "snapshots.0.allowed_use.0.bare_metal_server"), + resource.TestCheckResourceAttrSet(snpName, "snapshots.0.allowed_use.0.instance"), + resource.TestCheckResourceAttrSet(snpName, "snapshots.0.allowed_use.0.api_version"), ), }, }, diff --git a/ibm/service/vpc/data_source_ibm_is_volume_test.go b/ibm/service/vpc/data_source_ibm_is_volume_test.go index ffbf25c412..17ee45bb24 100644 --- a/ibm/service/vpc/data_source_ibm_is_volume_test.go +++ b/ibm/service/vpc/data_source_ibm_is_volume_test.go @@ -223,6 +223,14 @@ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCKVmnMOlHKcZK8tpt3MP1lqOLAcqcJzhsvJcjscgVE resName, "catalog_offering.0.plan_crn"), resource.TestCheckResourceAttrSet( resName, "catalog_offering.0.version_crn"), + resource.TestCheckResourceAttrSet( + resName, "allowed_use.#"), + resource.TestCheckResourceAttrSet( + resName, "allowed_use.0.bare_metal_server"), + resource.TestCheckResourceAttrSet( + resName, "allowed_use.0.instance"), + resource.TestCheckResourceAttrSet( + resName, "allowed_use.0.api_version"), ), }, }, diff --git a/ibm/service/vpc/data_source_ibm_is_volumes_test.go b/ibm/service/vpc/data_source_ibm_is_volumes_test.go index 82b1339725..93aaffc751 100644 --- a/ibm/service/vpc/data_source_ibm_is_volumes_test.go +++ b/ibm/service/vpc/data_source_ibm_is_volumes_test.go @@ -142,6 +142,14 @@ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCKVmnMOlHKcZK8tpt3MP1lqOLAcqcJzhsvJcjscgVE resName, "volumes.0.catalog_offering.0.plan_crn"), resource.TestCheckResourceAttrSet( resName, "volumes.0.catalog_offering.0.version_crn"), + resource.TestCheckResourceAttrSet( + resName, "volumes.0.allowed_use.#"), + resource.TestCheckResourceAttrSet( + resName, "volumes.0.allowed_use.0.bare_metal_server"), + resource.TestCheckResourceAttrSet( + resName, "volumes.0.allowed_use.0.instance"), + resource.TestCheckResourceAttrSet( + resName, "volumes.0.allowed_use.0.api_version"), ), }, },