diff --git a/builtin/providers/aws/resource_aws_subnet_test.go b/builtin/providers/aws/resource_aws_subnet_test.go index 5b80b8489..2a4e3259d 100644 --- a/builtin/providers/aws/resource_aws_subnet_test.go +++ b/builtin/providers/aws/resource_aws_subnet_test.go @@ -27,9 +27,10 @@ func TestAccAWSSubnet_basic(t *testing.T) { } resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - Providers: testAccProviders, - CheckDestroy: testAccCheckSubnetDestroy, + PreCheck: func() { testAccPreCheck(t) }, + IDRefreshName: "aws_subnet.foo", + Providers: testAccProviders, + CheckDestroy: testAccCheckSubnetDestroy, Steps: []resource.TestStep{ resource.TestStep{ Config: testAccSubnetConfig, diff --git a/builtin/providers/aws/resource_aws_vpc_dhcp_options_association_test.go b/builtin/providers/aws/resource_aws_vpc_dhcp_options_association_test.go index 84b58029a..9cdd46766 100644 --- a/builtin/providers/aws/resource_aws_vpc_dhcp_options_association_test.go +++ b/builtin/providers/aws/resource_aws_vpc_dhcp_options_association_test.go @@ -14,7 +14,11 @@ func TestAccAWSDHCPOptionsAssociation_basic(t *testing.T) { var d ec2.DhcpOptions resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, + PreCheck: func() { testAccPreCheck(t) }, + + DisableIDRefresh: true, + IDRefreshName: "aws_vpc_dhcp_options_association.foo", + Providers: testAccProviders, CheckDestroy: testAccCheckDHCPOptionsAssociationDestroy, Steps: []resource.TestStep{ diff --git a/builtin/providers/aws/resource_aws_vpc_endpoint_test.go b/builtin/providers/aws/resource_aws_vpc_endpoint_test.go index 4a081b69c..c39162588 100644 --- a/builtin/providers/aws/resource_aws_vpc_endpoint_test.go +++ b/builtin/providers/aws/resource_aws_vpc_endpoint_test.go @@ -16,9 +16,10 @@ func TestAccAWSVpcEndpoint_basic(t *testing.T) { var endpoint ec2.VpcEndpoint resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - Providers: testAccProviders, - CheckDestroy: testAccCheckVpcEndpointDestroy, + PreCheck: func() { testAccPreCheck(t) }, + IDRefreshName: "aws_vpc_endpoint.second-private-s3", + Providers: testAccProviders, + CheckDestroy: testAccCheckVpcEndpointDestroy, Steps: []resource.TestStep{ resource.TestStep{ Config: testAccVpcEndpointWithRouteTableAndPolicyConfig, @@ -35,9 +36,10 @@ func TestAccAWSVpcEndpoint_withRouteTableAndPolicy(t *testing.T) { var routeTable ec2.RouteTable resource.Test(t, resource.TestCase{ - PreCheck: func() { testAccPreCheck(t) }, - Providers: testAccProviders, - CheckDestroy: testAccCheckVpcEndpointDestroy, + PreCheck: func() { testAccPreCheck(t) }, + IDRefreshName: "aws_vpc_endpoint.second-private-s3", + Providers: testAccProviders, + CheckDestroy: testAccCheckVpcEndpointDestroy, Steps: []resource.TestStep{ resource.TestStep{ Config: testAccVpcEndpointWithRouteTableAndPolicyConfig,