mirror of
https://github.com/letic/terraform-provider-google.git
synced 2024-09-16 08:10:02 +00:00
ab68b06af5
* Upgrade iam client to latest version * Add new resource to support IAM custom roles. * Add documentation
30 lines
694 B
Go
30 lines
694 B
Go
package google
|
|
|
|
import (
|
|
"github.com/hashicorp/terraform/helper/acctest"
|
|
"github.com/hashicorp/terraform/helper/resource"
|
|
"testing"
|
|
)
|
|
|
|
func TestAccGoogleProjectIamCustomRole_import(t *testing.T) {
|
|
t.Parallel()
|
|
|
|
roleId := "tfIamRole" + acctest.RandString(10)
|
|
|
|
resource.Test(t, resource.TestCase{
|
|
PreCheck: func() { testAccPreCheck(t) },
|
|
Providers: testAccProviders,
|
|
CheckDestroy: testAccCheckGoogleProjectIamCustomRoleDestroy,
|
|
Steps: []resource.TestStep{
|
|
{
|
|
Config: testAccCheckGoogleProjectIamCustomRole_update(roleId),
|
|
},
|
|
{
|
|
ResourceName: "google_project_iam_custom_role.foo",
|
|
ImportState: true,
|
|
ImportStateVerify: true,
|
|
},
|
|
},
|
|
})
|
|
}
|