Skip to content

Commit

Permalink
Fix google_iam_deny_policy tests (#9321) (#6557)
Browse files Browse the repository at this point in the history
[upstream:6c5551f3d1e0cd9ab6c17ce003a4c0bd6f4f565b]

Signed-off-by: Modular Magician <magic-modules@google.com>
  • Loading branch information
modular-magician authored Oct 23, 2023
1 parent d9ebd9e commit 5899b9e
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
3 changes: 3 additions & 0 deletions .changelog/9321.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:none

```
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ resource "google_iam_deny_policy" "example" {
title = "Some expr"
expression = "!resource.matchTag('12345678/env', 'test')"
}
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.delete"]
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.update"]
}
}
rules {
Expand All @@ -90,7 +90,7 @@ resource "google_iam_deny_policy" "example" {
title = "Some expr"
expression = "!resource.matchTag('12345678/env', 'test')"
}
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.delete"]
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.update"]
exception_principals = ["principal://iam.googleapis.com/projects/-/serviceAccounts/${google_service_account.test-account.email}"]
}
}
Expand Down
6 changes: 3 additions & 3 deletions google-beta/services/iam2/resource_iam_deny_policy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ resource "google_iam_deny_policy" "example" {
title = "Some expr"
expression = "!resource.matchTag('12345678/env', 'test')"
}
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.delete"]
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.update"]
}
}
rules {
Expand All @@ -123,7 +123,7 @@ resource "google_iam_deny_policy" "example" {
title = "Some expr"
expression = "!resource.matchTag('12345678/env', 'test')"
}
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.delete"]
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.update"]
exception_principals = ["principal://iam.googleapis.com/projects/-/serviceAccounts/${google_service_account.test-account.email}"]
}
}
Expand Down Expand Up @@ -160,7 +160,7 @@ resource "google_iam_deny_policy" "example" {
location = "/some/file"
description = "A denial condition"
}
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.delete"]
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.update"]
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions website/docs/r/iam_deny_policy.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ resource "google_iam_deny_policy" "example" {
title = "Some expr"
expression = "!resource.matchTag('12345678/env', 'test')"
}
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.delete"]
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.update"]
}
}
rules {
Expand All @@ -62,7 +62,7 @@ resource "google_iam_deny_policy" "example" {
title = "Some expr"
expression = "!resource.matchTag('12345678/env', 'test')"
}
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.delete"]
denied_permissions = ["cloudresourcemanager.googleapis.com/projects.update"]
exception_principals = ["principal://iam.googleapis.com/projects/-/serviceAccounts/${google_service_account.test-account.email}"]
}
}
Expand Down

0 comments on commit 5899b9e

Please sign in to comment.