Skip to content

Commit

Permalink
update code
Browse files Browse the repository at this point in the history
  • Loading branch information
neil-yechenwei committed Apr 22, 2024
1 parent a7284af commit f01a77e
Showing 1 changed file with 32 additions and 31 deletions.
63 changes: 32 additions & 31 deletions internal/services/network/virtual_network_gateway_resource_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,21 +109,6 @@ func TestAccVirtualNetworkGateway_activeActiveZoneRedundantWithP2S(t *testing.T)
})
}

func TestAccVirtualNetworkGateway_standard(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_virtual_network_gateway", "test")
r := VirtualNetworkGatewayResource{}

data.ResourceTest(t, r, []acceptance.TestStep{
{
Config: r.sku(data, "Standard"),
Check: acceptance.ComposeTestCheckFunc(
check.That(data.ResourceName).ExistsInAzure(r),
check.That(data.ResourceName).Key("sku").HasValue("Standard"),
),
},
})
}

func TestAccVirtualNetworkGateway_vpnGw2(t *testing.T) {
data := acceptance.BuildTestData(t, "azurerm_virtual_network_gateway", "test")
r := VirtualNetworkGatewayResource{}
Expand Down Expand Up @@ -580,7 +565,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -635,15 +621,17 @@ resource "azurerm_public_ip" "first" {
name = "acctestpip1-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_public_ip" "second" {
name = "acctestpip2-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -825,7 +813,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -913,7 +902,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -972,7 +962,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1028,7 +1019,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1078,7 +1070,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip1-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1129,7 +1122,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip1-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1188,7 +1182,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip1-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1238,7 +1233,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1514,15 +1510,17 @@ resource "azurerm_public_ip" "first" {
name = "acctestpip1-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_public_ip" "second" {
name = "acctestpip2-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1600,7 +1598,8 @@ resource "azurerm_public_ip" "test" {
name = "acctestpip-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down Expand Up @@ -1725,15 +1724,17 @@ resource "azurerm_public_ip" "first" {
name = "acctestpip1-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_public_ip" "second" {
name = "acctestpip2-%d"
location = azurerm_resource_group.test.location
resource_group_name = azurerm_resource_group.test.name
allocation_method = "Dynamic"
allocation_method = "Static"
sku = "Standard"
}
resource "azurerm_virtual_network_gateway" "test" {
Expand Down

0 comments on commit f01a77e

Please sign in to comment.