@@ -77,7 +77,6 @@ func TestAccGitlabProject_basic(t *testing.T) {
77
77
PackagesEnabled : true ,
78
78
PrintingMergeRequestLinkEnabled : true ,
79
79
PagesAccessLevel : gitlab .PublicAccessControl ,
80
- BuildCoverageRegex : "foo" ,
81
80
IssuesTemplate : "" ,
82
81
MergeRequestsTemplate : "" ,
83
82
CIConfigPath : ".gitlab-ci.yml@mynamespace/myproject" ,
@@ -158,7 +157,6 @@ func TestAccGitlabProject_basic(t *testing.T) {
158
157
Archived : true ,
159
158
PackagesEnabled : false ,
160
159
PagesAccessLevel : gitlab .DisabledAccessControl ,
161
- BuildCoverageRegex : "bar" ,
162
160
CIForwardDeploymentEnabled : false ,
163
161
ResolveOutdatedDiffDiscussions : false ,
164
162
AnalyticsAccessLevel : gitlab .DisabledAccessControl ,
@@ -736,7 +734,6 @@ func TestAccGitlabProject_transfer(t *testing.T) {
736
734
PackagesEnabled : true ,
737
735
PrintingMergeRequestLinkEnabled : true ,
738
736
PagesAccessLevel : gitlab .PrivateAccessControl ,
739
- BuildCoverageRegex : "foo" ,
740
737
CIForwardDeploymentEnabled : true ,
741
738
}
742
739
@@ -1148,6 +1145,38 @@ func TestAccGitlabProject_containerExpirationPolicy(t *testing.T) {
1148
1145
})
1149
1146
}
1150
1147
1148
+ func TestAccGitlabProject_DeprecatedBuildCoverageRegex (t * testing.T ) {
1149
+ var received gitlab.Project
1150
+ rInt := acctest .RandInt ()
1151
+
1152
+ resource .Test (t , resource.TestCase {
1153
+ PreCheck : func () { testAccPreCheck (t ) },
1154
+ ProviderFactories : providerFactories ,
1155
+ CheckDestroy : testAccCheckGitlabProjectDestroy ,
1156
+ Steps : []resource.TestStep {
1157
+ {
1158
+ SkipFunc : isGitLabVersionLessThan (context .Background (), testGitlabClient , "15.0" ),
1159
+ Config : fmt .Sprintf (`
1160
+ resource "gitlab_project" "this" {
1161
+ name = "foo-%d"
1162
+ visibility_level = "public"
1163
+
1164
+ build_coverage_regex = "helloWorld"
1165
+ }` , rInt ),
1166
+ Check : resource .ComposeTestCheckFunc (
1167
+ testAccCheckGitlabProjectExists ("gitlab_project.this" , & received ),
1168
+ ),
1169
+ },
1170
+ {
1171
+ SkipFunc : isGitLabVersionLessThan (context .Background (), testGitlabClient , "15.0" ),
1172
+ ResourceName : "gitlab_project.this" ,
1173
+ ImportState : true ,
1174
+ ImportStateVerify : true ,
1175
+ },
1176
+ },
1177
+ })
1178
+ }
1179
+
1151
1180
func testAccCheckGitlabProjectExists (n string , project * gitlab.Project ) resource.TestCheckFunc {
1152
1181
return func (s * terraform.State ) error {
1153
1182
var err error
@@ -1359,7 +1388,6 @@ resource "gitlab_project" "foo" {
1359
1388
# So that acceptance tests can be run in a gitlab organization
1360
1389
# with no billing
1361
1390
visibility_level = "public"
1362
- build_coverage_regex = "foo"
1363
1391
}
1364
1392
` , rInt , rInt , rInt )
1365
1393
}
@@ -1415,7 +1443,6 @@ resource "gitlab_project" "foo" {
1415
1443
# So that acceptance tests can be run in a gitlab organization
1416
1444
# with no billing
1417
1445
visibility_level = "public"
1418
- build_coverage_regex = "foo"
1419
1446
}
1420
1447
1421
1448
resource "gitlab_project_variable" "foo" {
@@ -1449,7 +1476,6 @@ resource "gitlab_project" "foo" {
1449
1476
# So that acceptance tests can be run in a gitlab organization
1450
1477
# with no billing
1451
1478
visibility_level = "public"
1452
- build_coverage_regex = "foo"
1453
1479
}
1454
1480
1455
1481
resource "gitlab_project_variable" "foo" {
@@ -1489,7 +1515,6 @@ resource "gitlab_project" "foo" {
1489
1515
only_allow_merge_if_all_discussions_are_resolved = true
1490
1516
squash_option = "default_off"
1491
1517
pages_access_level = "public"
1492
- build_coverage_regex = "foo"
1493
1518
allow_merge_on_skipped_pipeline = false
1494
1519
ci_config_path = ".gitlab-ci.yml@mynamespace/myproject"
1495
1520
resolve_outdated_diff_discussions = true
@@ -1589,7 +1614,6 @@ resource "gitlab_project" "foo" {
1589
1614
archived = true
1590
1615
packages_enabled = false
1591
1616
pages_access_level = "disabled"
1592
- build_coverage_regex = "bar"
1593
1617
ci_forward_deployment_enabled = false
1594
1618
merge_pipelines_enabled = false
1595
1619
merge_trains_enabled = false
@@ -1929,7 +1953,6 @@ resource "gitlab_project" "foo" {
1929
1953
only_allow_merge_if_all_discussions_are_resolved = true
1930
1954
squash_option = "default_off"
1931
1955
pages_access_level = "public"
1932
- build_coverage_regex = "foo"
1933
1956
allow_merge_on_skipped_pipeline = false
1934
1957
ci_config_path = ".gitlab-ci.yml@mynamespace/myproject"
1935
1958
resolve_outdated_diff_discussions = true
0 commit comments