Skip to content

Commit 7f950eb

Browse files
author
Huseyin Unal
committed
Add Import test
1 parent 45b5e26 commit 7f950eb

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

gitlab/resource_gitlab_project_level_mr_approvals_test.go

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,27 @@ func testAccCheckGitlabProjectLevelMRApprovalsExists(n string, projectApprovals
109109
}
110110
}
111111

112+
func TestAccGitlabProjectLevelMRApprovals_import(t *testing.T) {
113+
rInt := acctest.RandInt()
114+
115+
resource.Test(t, resource.TestCase{
116+
PreCheck: func() { testAccPreCheck(t) },
117+
Providers: testAccProviders,
118+
CheckDestroy: testAccCheckGitlabProjectLevelMRApprovalsDestroy,
119+
Steps: []resource.TestStep{
120+
{
121+
SkipFunc: isRunningInCE,
122+
Config: testAccGitlabProjectLevelMRApprovalsUpdateConfig(rInt),
123+
},
124+
{
125+
ResourceName: "gitlab_project_level_mr_approvals.foo",
126+
ImportState: true,
127+
ImportStateVerify: true,
128+
},
129+
},
130+
})
131+
}
132+
112133
func testAccGitlabProjectLevelMRApprovalsUpdateConfig(rInt int) string {
113134
return fmt.Sprintf(`
114135
resource "gitlab_project" "foo" {

0 commit comments

Comments
 (0)