Skip to content

Commit

Permalink
test fix
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-jcieslak committed Apr 8, 2024
1 parent 99653b6 commit 8927b15
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 17 deletions.
7 changes: 4 additions & 3 deletions docs/resources/grant_ownership.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,9 +206,10 @@ provider "snowflake" {
## With ownership on the database, the secondary provider is able to create schema on it without any additional privileges.
resource "snowflake_schema" "test" {
provider = snowflake.secondary
database = snowflake_database.test.name
name = "schema"
depends_on = [snowflake_grant_ownership.test, snowflake_grant_account_role.test]
provider = snowflake.secondary
database = snowflake_database.test.name
name = "schema"
}
```

Expand Down
7 changes: 4 additions & 3 deletions examples/resources/snowflake_grant_ownership/resource.tf
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,8 @@ provider "snowflake" {

## With ownership on the database, the secondary provider is able to create schema on it without any additional privileges.
resource "snowflake_schema" "test" {
provider = snowflake.secondary
database = snowflake_database.test.name
name = "schema"
depends_on = [snowflake_grant_ownership.test, snowflake_grant_account_role.test]
provider = snowflake.secondary
database = snowflake_database.test.name
name = "schema"
}
12 changes: 1 addition & 11 deletions pkg/resources/grant_ownership_acceptance_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -715,16 +715,6 @@ func TestAcc_GrantOwnership_OnMaterializedView(t *testing.T) {
})
}

func TestAcc_GrantOwnership_OnTasks(t *testing.T) {
t.Skip("will be unskipped in the following grant ownership prs")
// - Tasks on bulk
}

func TestAcc_GrantOwnership_OnAllTasks(t *testing.T) {
t.Skip("will be unskipped in the following grant ownership prs")
// - Tasks on bulk
}

func TestAcc_GrantOwnership_RoleBasedAccessControlUseCase(t *testing.T) {
accountRoleName := strings.ToUpper(acctest.RandStringFromCharSet(10, acctest.CharSetAlpha))
databaseName := strings.ToUpper(acctest.RandStringFromCharSet(10, acctest.CharSetAlpha))
Expand Down Expand Up @@ -788,7 +778,7 @@ provider "snowflake" {
}
resource "snowflake_schema" "test" {
depends_on = [snowflake_role.test]
depends_on = [snowflake_grant_ownership.test, snowflake_grant_account_role.test]
provider = snowflake.secondary
database = snowflake_database.test.name
name = "%s"
Expand Down

0 comments on commit 8927b15

Please sign in to comment.