Skip to content

Commit c6ecc62

Browse files
committed
fix: use template location in radius profile tests
1 parent d773b1a commit c6ecc62

File tree

1 file changed

+15
-12
lines changed

1 file changed

+15
-12
lines changed

assets/terraform/test/resource_radius_profile_test.go

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ func TestAccServerRadiusProfile_Basic(t *testing.T) {
2020
prefix := fmt.Sprintf("test-acc-%s", nameSuffix)
2121

2222
location := config.ObjectVariable(map[string]config.Variable{
23-
"device_group": config.ObjectVariable(map[string]config.Variable{
23+
"template": config.ObjectVariable(map[string]config.Variable{
2424
"name": config.StringVariable(prefix),
2525
}),
2626
})
@@ -109,7 +109,7 @@ func TestAccServerRadiusProfile_Chap(t *testing.T) {
109109
prefix := fmt.Sprintf("test-acc-%s", nameSuffix)
110110

111111
location := config.ObjectVariable(map[string]config.Variable{
112-
"device_group": config.ObjectVariable(map[string]config.Variable{
112+
"template": config.ObjectVariable(map[string]config.Variable{
113113
"name": config.StringVariable(prefix),
114114
}),
115115
})
@@ -173,12 +173,13 @@ const panosServerRadiusProfile_EAP_TTLS_with_PAP_Tmpl = `
173173
variable "location" { type = any }
174174
variable "prefix" { type = string }
175175
176-
resource "panos_device_group" "example" {
177-
name = var.prefix
176+
resource "panos_template" "example" {
177+
location = { panorama = {} }
178+
name = var.prefix
178179
}
179180
180181
resource "panos_certificate_profile" "cert_prof" {
181-
depends_on = [panos_device_group.example]
182+
depends_on = [panos_template.example]
182183
location = var.location
183184
name = "test-cert-profile"
184185
}
@@ -214,7 +215,7 @@ func TestAccServerRadiusProfile_EAP_TTLS_with_PAP(t *testing.T) {
214215
prefix := fmt.Sprintf("test-acc-%s", nameSuffix)
215216

216217
location := config.ObjectVariable(map[string]config.Variable{
217-
"device_group": config.ObjectVariable(map[string]config.Variable{
218+
"template": config.ObjectVariable(map[string]config.Variable{
218219
"name": config.StringVariable(prefix),
219220
}),
220221
})
@@ -335,12 +336,13 @@ const panosServerRadiusProfile_PEAP_MSCHAPv2_Tmpl = `
335336
variable "location" { type = any }
336337
variable "prefix" { type = string }
337338
338-
resource "panos_device_group" "example" {
339-
name = var.prefix
339+
resource "panos_template" "example" {
340+
location = { panorama = {} }
341+
name = var.prefix
340342
}
341343
342344
resource "panos_certificate_profile" "cert_prof" {
343-
depends_on = [panos_device_group.example]
345+
depends_on = [panos_template.example]
344346
location = var.location
345347
name = "test-cert-profile"
346348
}
@@ -407,12 +409,13 @@ const panosServerRadiusProfile_PEAP_with_GTC_Tmpl = `
407409
variable "location" { type = any }
408410
variable "prefix" { type = string }
409411
410-
resource "panos_device_group" "example" {
411-
name = var.prefix
412+
resource "panos_template" "example" {
413+
location = { panorama = {} }
414+
name = var.prefix
412415
}
413416
414417
resource "panos_certificate_profile" "cert_prof" {
415-
depends_on = [panos_device_group.example]
418+
depends_on = [panos_template.example]
416419
location = var.location
417420
name = "test-cert-profile"
418421
}

0 commit comments

Comments
 (0)