@@ -26,6 +26,7 @@ func TestAccGitlabProject_basic(t *testing.T) {
26
26
testAccCheckGitlabProjectExists ("gitlab_project.foo" , & project ),
27
27
testAccCheckGitlabProjectAttributes (& project , & testAccGitlabProjectExpectedAttributes {
28
28
Name : fmt .Sprintf ("foo-%d" , rInt ),
29
+ Path : fmt .Sprintf ("foo.%d" , rInt ),
29
30
Description : "Terraform acceptance tests" ,
30
31
IssuesEnabled : true ,
31
32
MergeRequestsEnabled : true ,
@@ -42,6 +43,7 @@ func TestAccGitlabProject_basic(t *testing.T) {
42
43
testAccCheckGitlabProjectExists ("gitlab_project.foo" , & project ),
43
44
testAccCheckGitlabProjectAttributes (& project , & testAccGitlabProjectExpectedAttributes {
44
45
Name : fmt .Sprintf ("foo-%d" , rInt ),
46
+ Path : fmt .Sprintf ("foo.%d" , rInt ),
45
47
Description : "Terraform acceptance tests!" ,
46
48
Visibility : gitlab .PublicVisibility ,
47
49
}),
@@ -54,6 +56,7 @@ func TestAccGitlabProject_basic(t *testing.T) {
54
56
testAccCheckGitlabProjectExists ("gitlab_project.foo" , & project ),
55
57
testAccCheckGitlabProjectAttributes (& project , & testAccGitlabProjectExpectedAttributes {
56
58
Name : fmt .Sprintf ("foo-%d" , rInt ),
59
+ Path : fmt .Sprintf ("foo.%d" , rInt ),
57
60
Description : "Terraform acceptance tests" ,
58
61
IssuesEnabled : true ,
59
62
MergeRequestsEnabled : true ,
@@ -91,6 +94,7 @@ func testAccCheckGitlabProjectExists(n string, project *gitlab.Project) resource
91
94
92
95
type testAccGitlabProjectExpectedAttributes struct {
93
96
Name string
97
+ Path string
94
98
Description string
95
99
DefaultBranch string
96
100
IssuesEnabled bool
@@ -105,6 +109,9 @@ func testAccCheckGitlabProjectAttributes(project *gitlab.Project, want *testAccG
105
109
if project .Name != want .Name {
106
110
return fmt .Errorf ("got repo %q; want %q" , project .Name , want .Name )
107
111
}
112
+ if project .Path != want .Path {
113
+ return fmt .Errorf ("got repo %q; want %q" , project .Path , want .Path )
114
+ }
108
115
if project .Description != want .Description {
109
116
return fmt .Errorf ("got description %q; want %q" , project .Description , want .Description )
110
117
}
@@ -163,19 +170,21 @@ func testAccGitlabProjectConfig(rInt int) string {
163
170
return fmt .Sprintf (`
164
171
resource "gitlab_project" "foo" {
165
172
name = "foo-%d"
173
+ path = "foo.%d"
166
174
description = "Terraform acceptance tests"
167
175
168
176
# So that acceptance tests can be run in a gitlab organization
169
177
# with no billing
170
178
visibility_level = "public"
171
179
}
172
- ` , rInt )
180
+ ` , rInt , rInt )
173
181
}
174
182
175
183
func testAccGitlabProjectUpdateConfig (rInt int ) string {
176
184
return fmt .Sprintf (`
177
185
resource "gitlab_project" "foo" {
178
186
name = "foo-%d"
187
+ path = "foo.%d"
179
188
description = "Terraform acceptance tests!"
180
189
181
190
# So that acceptance tests can be run in a gitlab organization
@@ -187,5 +196,5 @@ resource "gitlab_project" "foo" {
187
196
wiki_enabled = false
188
197
snippets_enabled = false
189
198
}
190
- ` , rInt )
199
+ ` , rInt , rInt )
191
200
}
0 commit comments