@@ -35,7 +35,7 @@ func TestAccAwsVpnConnection(t *testing.T) {
3535 "aws_vpc.vpc" ,
3636 "aws_vpn_gateway.vpn_gateway" ,
3737 "aws_customer_gateway.customer_gateway" ,
38- "aws_vpn_connection.bar " ,
38+ "aws_vpn_connection.foo " ,
3939 ),
4040 ),
4141 },
@@ -85,18 +85,16 @@ func testAccAwsVpnConnection(
8585}
8686
8787const testAccAwsVpnConnectionConfig = `
88- resource "aws_vpc" "vpc" {
89- cidr_block = "10.0.0.0/16"
90- }
91-
9288resource "aws_vpn_gateway" "vpn_gateway" {
93- vpc_id = "${aws_vpc.vpc.id}"
89+ tags {
90+ Name = "vpn_gateway"
91+ }
9492}
9593
9694resource "aws_customer_gateway" "customer_gateway" {
9795 bgp_asn = 60000
98- ip_address = "172 .0.0.1"
99- type = ipsec.1
96+ ip_address = "178 .0.0.1"
97+ type = " ipsec.1"
10098}
10199
102100resource "aws_vpn_connection" "foo" {
@@ -107,29 +105,21 @@ resource "aws_vpn_connection" "foo" {
107105}
108106`
109107
108+ // Change static_routes_only to be false, forcing a refresh.
110109const testAccAwsVpnConnectionConfigUpdate = `
111- resource "aws_vpc" "vpc" {
112- cidr_block = "10.0.0.0/16"
113- }
114-
115110resource "aws_vpn_gateway" "vpn_gateway" {
116- vpc_id = "${aws_vpc.vpc.id}"
111+ tags {
112+ Name = "vpn_gateway"
113+ }
117114}
118115
119116resource "aws_customer_gateway" "customer_gateway" {
120117 bgp_asn = 60000
121- ip_address = "172.0.0.1"
122- type = ipsec.1
123- }
124-
125- resource "aws_vpn_connection" "foo" {
126- vpn_gateway_id = "${aws_vpn_gateway.vpn_gateway.id}"
127- customer_gateway_id = "${aws_customer_gateway.customer_gateway.id}"
118+ ip_address = "178.0.0.1"
128119 type = "ipsec.1"
129- static_routes_only = true
130120}
131121
132- resource "aws_vpn_connection" "bar " {
122+ resource "aws_vpn_connection" "foo " {
133123 vpn_gateway_id = "${aws_vpn_gateway.vpn_gateway.id}"
134124 customer_gateway_id = "${aws_customer_gateway.customer_gateway.id}"
135125 type = "ipsec.1"
0 commit comments