Skip to content

Commit

Permalink
add import test
Browse files Browse the repository at this point in the history
  • Loading branch information
mgyucht committed Dec 12, 2024
1 parent 66fe1b9 commit 59e16d5
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions internal/providers/pluginfw/products/app/app_acc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,19 +93,19 @@ var templateWithInvalidResource = `
resource "databricks_app" "this" {
name = "{var.STICKY_RANDOM}"
description = "My app"
resources {
resources = [{
name = "invalid resource"
description = "invalid resource for app"
secret {
secret = {
permission = "CAN_MANAGE"
key = "test"
scope = "test"
}
sql_warehouse {
sql_warehouse = {
id = "123"
permission = "CAN_MANAGE"
}
}
}]
}`

func TestAccApp_InvalidResource(t *testing.T) {
Expand All @@ -126,5 +126,11 @@ func TestAccApp(t *testing.T) {
Template: makeTemplate("My app"),
}, acceptance.Step{
Template: makeTemplate("My new app"),
}, acceptance.Step{
ImportState: true,
ResourceName: "databricks_app.this",
ImportStateIdFunc: acceptance.BuildImportStateIdFunc("databricks_app.this", "name"),
ImportStateVerify: true,
ImportStateVerifyIdentifierAttribute: "name",
})
}

0 comments on commit 59e16d5

Please sign in to comment.