|
60 | 60 | "volume_id": Representation{repType: Optional, create: `${oci_core_boot_volume.test_boot_volume.id}`}, |
61 | 61 | } |
62 | 62 | instanceConfigurationInstanceDetailsLaunchDetailsRepresentation = map[string]interface{}{ |
63 | | - "availability_domain": Representation{repType: Optional, create: `availabilityDomain`}, |
| 63 | + "availability_domain": Representation{repType: Optional, create: `${data.oci_identity_availability_domains.test_availability_domains.availability_domains.0.name}`}, |
64 | 64 | "compartment_id": Representation{repType: Optional, create: `${var.compartment_id}`}, |
65 | 65 | "create_vnic_details": RepresentationGroup{Optional, instanceConfigurationInstanceDetailsLaunchDetailsCreateVnicDetailsRepresentation}, |
66 | 66 | "defined_tags": Representation{repType: Optional, create: `${map("${oci_identity_tag_namespace.tag-namespace1.name}.${oci_identity_tag.tag1.name}", "value")}`, update: `${map("${oci_identity_tag_namespace.tag-namespace1.name}.${oci_identity_tag.tag1.name}", "updatedValue")}`}, |
|
84 | 84 | "use_chap": Representation{repType: Optional, create: `false`}, |
85 | 85 | } |
86 | 86 | instanceConfigurationInstanceDetailsBlockVolumesCreateDetailsRepresentation = map[string]interface{}{ |
87 | | - "availability_domain": Representation{repType: Optional, create: `availabilityDomain`}, |
88 | | - "backup_policy_id": Representation{repType: Optional, create: `${data.oci_core_volume_backup_policies.test_boot_volume_backup_policies.volume_backup_policies.0.id}`}, |
| 87 | + "availability_domain": Representation{repType: Optional, create: `${data.oci_identity_availability_domains.test_availability_domains.availability_domains.0.name}`}, |
| 88 | + "backup_policy_id": Representation{repType: Optional, create: `${data.oci_core_volume_backup_policies.test_volume_backup_policies.volume_backup_policies.0.id}`}, |
89 | 89 | "compartment_id": Representation{repType: Optional, create: `${var.compartment_id}`}, |
90 | 90 | "defined_tags": Representation{repType: Optional, create: `${map("${oci_identity_tag_namespace.tag-namespace1.name}.${oci_identity_tag.tag1.name}", "value")}`, update: `${map("${oci_identity_tag_namespace.tag-namespace1.name}.${oci_identity_tag.tag1.name}", "updatedValue")}`}, |
91 | 91 | "display_name": Representation{repType: Optional, create: `backend-servers`}, |
@@ -180,7 +180,7 @@ func TestCoreInstanceConfigurationResource_basic(t *testing.T) { |
180 | 180 | resource.TestCheckResourceAttr(resourceName, "instance_details.#", "1"), |
181 | 181 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.instance_type", "compute"), |
182 | 182 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.launch_details.#", "1"), |
183 | | - resource.TestCheckResourceAttr(resourceName, "instance_details.0.launch_details.0.availability_domain", "availabilityDomain"), |
| 183 | + resource.TestCheckResourceAttrSet(resourceName, "instance_details.0.launch_details.0.availability_domain"), |
184 | 184 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.launch_details.0.compartment_id", compartmentId), |
185 | 185 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.launch_details.0.create_vnic_details.#", "1"), |
186 | 186 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.launch_details.0.create_vnic_details.0.assign_public_ip", "false"), |
@@ -221,7 +221,7 @@ func TestCoreInstanceConfigurationResource_basic(t *testing.T) { |
221 | 221 | resource.TestCheckResourceAttr(resourceName, "instance_details.#", "1"), |
222 | 222 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.block_volumes.#", "1"), |
223 | 223 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.block_volumes.0.create_details.#", "1"), |
224 | | - resource.TestCheckResourceAttr(resourceName, "instance_details.0.block_volumes.0.create_details.0.availability_domain", "availabilityDomain"), |
| 224 | + resource.TestCheckResourceAttrSet(resourceName, "instance_details.0.block_volumes.0.create_details.0.availability_domain"), |
225 | 225 | resource.TestCheckResourceAttrSet(resourceName, "instance_details.0.block_volumes.0.create_details.0.backup_policy_id"), |
226 | 226 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.block_volumes.0.create_details.0.compartment_id", compartmentId), |
227 | 227 | resource.TestCheckResourceAttr(resourceName, "instance_details.0.block_volumes.0.create_details.0.defined_tags.%", "1"), |
|
0 commit comments