Skip to content

Commit 176ab64

Browse files
author
David Townshend
committed
Merge branch 'project-approval-rules'
2 parents 08bba6a + 6714197 commit 176ab64

8 files changed

+951
-29
lines changed

gitlab/helper_test.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,14 @@ func testAccCompareGitLabAttribute(attr string, expected, received *schema.Resou
2929
}
3030

3131
func testAccIsSkippedAttribute(needle string, haystack []string) bool {
32-
if needle == "" {
33-
return false
34-
}
35-
for _, hay := range haystack {
36-
if hay == needle {
37-
return true
32+
if needle != "" {
33+
for _, hay := range haystack {
34+
if hay == needle {
35+
return true
36+
}
3837
}
3938
}
39+
4040
return false
4141
}
4242

gitlab/provider.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ func Provider() terraform.ResourceProvider {
8888
"gitlab_project_share_group": resourceGitlabProjectShareGroup(),
8989
"gitlab_group_cluster": resourceGitlabGroupCluster(),
9090
"gitlab_group_ldap_link": resourceGitlabGroupLdapLink(),
91+
"gitlab_project_approval_rule": resourceGitlabProjectApprovalRule(),
9192
},
9293

9394
ConfigureFunc: providerConfigure,

gitlab/provider_test.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,9 @@ func testAccPreCheck(t *testing.T) {
3333
t.Fatal("GITLAB_TOKEN must be set for acceptance tests")
3434
}
3535
}
36+
37+
func testGitLabLicensePreCheck(t *testing.T) {
38+
if v := os.Getenv("GITLAB_LICENSE_FILE"); v == "" {
39+
t.Skipf("GITLAB_LICENSE_FILE must be set to run EE tests.")
40+
}
41+
}

0 commit comments

Comments
 (0)