mirror of
https://github.com/opentofu/opentofu.git
synced 2025-01-08 23:23:59 -06:00
31 lines
699 B
Go
31 lines
699 B
Go
package newrelic
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"github.com/hashicorp/terraform/helper/acctest"
|
|
"github.com/hashicorp/terraform/helper/resource"
|
|
)
|
|
|
|
func TestAccNewRelicAlertPolicy_import(t *testing.T) {
|
|
resourceName := "newrelic_alert_policy.foo"
|
|
rName := acctest.RandString(5)
|
|
|
|
resource.Test(t, resource.TestCase{
|
|
PreCheck: func() { testAccPreCheck(t) },
|
|
Providers: testAccProviders,
|
|
CheckDestroy: testAccCheckNewRelicAlertPolicyDestroy,
|
|
Steps: []resource.TestStep{
|
|
resource.TestStep{
|
|
Config: testAccCheckNewRelicAlertPolicyConfig(rName),
|
|
},
|
|
|
|
resource.TestStep{
|
|
ResourceName: resourceName,
|
|
ImportState: true,
|
|
ImportStateVerify: true,
|
|
},
|
|
},
|
|
})
|
|
}
|