Skip to content

Commit 5159b21

Browse files
committed
re-enabled test because groups are no longer recreated
1 parent 713df8f commit 5159b21

File tree

1 file changed

+20
-21
lines changed

1 file changed

+20
-21
lines changed

internal/provider/resource_gitlab_group_test.go

Lines changed: 20 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -201,27 +201,26 @@ func TestAccGitlabGroup_nested(t *testing.T) {
201201
}),
202202
),
203203
},
204-
// TODO In EE version, re-creating on the same path where a previous group was soft-deleted doesn't work.
205-
// {
206-
// Config: testAccGitlabNestedGroupConfig(rInt),
207-
// Check: resource.ComposeTestCheckFunc(
208-
// testAccCheckGitlabGroupExists("gitlab_group.foo", &group),
209-
// testAccCheckGitlabGroupExists("gitlab_group.foo2", &group2),
210-
// testAccCheckGitlabGroupExists("gitlab_group.nested_foo", &nestedGroup),
211-
// testAccCheckGitlabGroupAttributes(&nestedGroup, &testAccGitlabGroupExpectedAttributes{
212-
// Name: fmt.Sprintf("nfoo-name-%d", rInt),
213-
// Path: fmt.Sprintf("nfoo-path-%d", rInt),
214-
// Description: "Terraform acceptance tests",
215-
// LFSEnabled: true,
216-
// Visibility: "public", // default value
217-
// ProjectCreationLevel: "maintainer", // default value
218-
// SubGroupCreationLevel: "owner", // default value
219-
// TwoFactorGracePeriod: 48, // default value
220-
// DefaultBranchProtection: 2, // default value
221-
// Parent: &group,
222-
// }),
223-
// ),
224-
// },
204+
{
205+
Config: testAccGitlabNestedGroupConfig(rInt),
206+
Check: resource.ComposeTestCheckFunc(
207+
testAccCheckGitlabGroupExists("gitlab_group.foo", &group),
208+
testAccCheckGitlabGroupExists("gitlab_group.foo2", &group2),
209+
testAccCheckGitlabGroupExists("gitlab_group.nested_foo", &nestedGroup),
210+
testAccCheckGitlabGroupAttributes(&nestedGroup, &testAccGitlabGroupExpectedAttributes{
211+
Name: fmt.Sprintf("nfoo-name-%d", rInt),
212+
Path: fmt.Sprintf("nfoo-path-%d", rInt),
213+
Description: "Terraform acceptance tests",
214+
LFSEnabled: true,
215+
Visibility: "public", // default value
216+
ProjectCreationLevel: "maintainer", // default value
217+
SubGroupCreationLevel: "owner", // default value
218+
TwoFactorGracePeriod: 48, // default value
219+
DefaultBranchProtection: 2, // default value
220+
Parent: &group,
221+
}),
222+
),
223+
},
225224
},
226225
})
227226
}

0 commit comments

Comments
 (0)