Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
alexhung committed Sep 20, 2024
1 parent d743567 commit 5bea64b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/xray/resource/resource_xray_security_policy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ func TestAccSecurityPolicy_UpgradeFromSDKv2(t *testing.T) {
testData["resource_name"] = resourceName
testData["policy_name"] = fmt.Sprintf("terraform-security-policy-4-%d", testutil.RandomInt())
testData["rule_name"] = fmt.Sprintf("test-security-rule-4-%d", testutil.RandomInt())
testData["applicable_cves_only"] = "false"

template := `
resource "xray_security_policy" "{{ .resource_name }}" {
Expand Down Expand Up @@ -416,6 +417,7 @@ func TestAccSecurityPolicy_createBlockDownloadTrueCVSS(t *testing.T) {
testData["resource_name"] = resourceName
testData["policy_name"] = fmt.Sprintf("terraform-security-policy-4-%d", testutil.RandomInt())
testData["rule_name"] = fmt.Sprintf("test-security-rule-4-%d", testutil.RandomInt())
testData["applicable_cves_only"] = "false"

resource.Test(t, resource.TestCase{
CheckDestroy: acctest.VerifyDeleted(fqrn, "", acctest.CheckPolicy),
Expand Down Expand Up @@ -443,6 +445,7 @@ func TestAccSecurityPolicy_createBlockDownloadFalseCVSS(t *testing.T) {
testData["resource_name"] = resourceName
testData["policy_name"] = fmt.Sprintf("terraform-security-policy-5-%d", testutil.RandomInt())
testData["rule_name"] = fmt.Sprintf("test-security-rule-5-%d", testutil.RandomInt())
testData["applicable_cves_only"] = "false"
testData["block_unscanned"] = "false"
testData["block_active"] = "false"

Expand Down

0 comments on commit 5bea64b

Please sign in to comment.