Skip to content

Commit 686653c

Browse files
chore: remove unused doc region tags (#8321) (#15149)
Signed-off-by: Modular Magician <[email protected]>
1 parent 279303a commit 686653c

5 files changed

+4
-34
lines changed

.changelog/8321.txt

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:none
2+
remove unused doc region tags from serverless samples
3+
```

google/iam_cloudfunctions2_function_generated_test.go

-10
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,6 @@ func TestAccCloudfunctions2functionIamPolicyGenerated(t *testing.T) {
137137

138138
func testAccCloudfunctions2functionIamMember_basicGenerated(context map[string]interface{}) string {
139139
return acctest.Nprintf(`
140-
# [START functions_v2_basic]
141140
locals {
142141
project = "%{project}" # Google Cloud Platform Project ID
143142
}
@@ -180,7 +179,6 @@ resource "google_cloudfunctions2_function" "function" {
180179
output "function_uri" {
181180
value = google_cloudfunctions2_function.function.service_config[0].uri
182181
}
183-
# [END functions_v2_basic]
184182
185183
resource "google_cloudfunctions2_function_iam_member" "foo" {
186184
project = google_cloudfunctions2_function.function.project
@@ -194,7 +192,6 @@ resource "google_cloudfunctions2_function_iam_member" "foo" {
194192

195193
func testAccCloudfunctions2functionIamPolicy_basicGenerated(context map[string]interface{}) string {
196194
return acctest.Nprintf(`
197-
# [START functions_v2_basic]
198195
locals {
199196
project = "%{project}" # Google Cloud Platform Project ID
200197
}
@@ -237,7 +234,6 @@ resource "google_cloudfunctions2_function" "function" {
237234
output "function_uri" {
238235
value = google_cloudfunctions2_function.function.service_config[0].uri
239236
}
240-
# [END functions_v2_basic]
241237
242238
data "google_iam_policy" "foo" {
243239
binding {
@@ -266,7 +262,6 @@ data "google_cloudfunctions2_function_iam_policy" "foo" {
266262

267263
func testAccCloudfunctions2functionIamPolicy_emptyBinding(context map[string]interface{}) string {
268264
return acctest.Nprintf(`
269-
# [START functions_v2_basic]
270265
locals {
271266
project = "%{project}" # Google Cloud Platform Project ID
272267
}
@@ -309,7 +304,6 @@ resource "google_cloudfunctions2_function" "function" {
309304
output "function_uri" {
310305
value = google_cloudfunctions2_function.function.service_config[0].uri
311306
}
312-
# [END functions_v2_basic]
313307
314308
data "google_iam_policy" "foo" {
315309
}
@@ -325,7 +319,6 @@ resource "google_cloudfunctions2_function_iam_policy" "foo" {
325319

326320
func testAccCloudfunctions2functionIamBinding_basicGenerated(context map[string]interface{}) string {
327321
return acctest.Nprintf(`
328-
# [START functions_v2_basic]
329322
locals {
330323
project = "%{project}" # Google Cloud Platform Project ID
331324
}
@@ -368,7 +361,6 @@ resource "google_cloudfunctions2_function" "function" {
368361
output "function_uri" {
369362
value = google_cloudfunctions2_function.function.service_config[0].uri
370363
}
371-
# [END functions_v2_basic]
372364
373365
resource "google_cloudfunctions2_function_iam_binding" "foo" {
374366
project = google_cloudfunctions2_function.function.project
@@ -382,7 +374,6 @@ resource "google_cloudfunctions2_function_iam_binding" "foo" {
382374

383375
func testAccCloudfunctions2functionIamBinding_updateGenerated(context map[string]interface{}) string {
384376
return acctest.Nprintf(`
385-
# [START functions_v2_basic]
386377
locals {
387378
project = "%{project}" # Google Cloud Platform Project ID
388379
}
@@ -425,7 +416,6 @@ resource "google_cloudfunctions2_function" "function" {
425416
output "function_uri" {
426417
value = google_cloudfunctions2_function.function.service_config[0].uri
427418
}
428-
# [END functions_v2_basic]
429419
430420
resource "google_cloudfunctions2_function_iam_binding" "foo" {
431421
project = google_cloudfunctions2_function.function.project

google/resource_cloudfunction2_function_test.go

+1-3
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,6 @@ func TestAccCloudFunctions2Function_fullUpdate(t *testing.T) {
207207

208208
func testAccCloudfunctions2function_cloudfunctions2BasicAuditlogsExample_update(context map[string]interface{}) string {
209209
return acctest.Nprintf(`
210-
# [START functions_v2_basic_auditlogs]
211210
# This example follows the examples shown in this Google Cloud Community blog post
212211
# https://medium.com/google-cloud/applying-a-path-pattern-when-filtering-in-eventarc-f06b937b4c34
213212
# and the docs:
@@ -314,6 +313,5 @@ resource "google_cloudfunctions2_function" "function" {
314313
value = google_storage_bucket.audit-log-bucket.name # Update: stops using path pattern operator
315314
}
316315
}
317-
}
318-
# [END functions_v2_basic_auditlogs]`, context)
316+
}`, context)
319317
}

google/resource_cloudfunctions2_function_generated_test.go

-9
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@ func TestAccCloudfunctions2function_cloudfunctions2BasicExample(t *testing.T) {
6161

6262
func testAccCloudfunctions2function_cloudfunctions2BasicExample(context map[string]interface{}) string {
6363
return acctest.Nprintf(`
64-
# [START functions_v2_basic]
6564
locals {
6665
project = "%{project}" # Google Cloud Platform Project ID
6766
}
@@ -104,7 +103,6 @@ resource "google_cloudfunctions2_function" "function" {
104103
output "function_uri" {
105104
value = google_cloudfunctions2_function.function.service_config[0].uri
106105
}
107-
# [END functions_v2_basic]
108106
`, context)
109107
}
110108

@@ -139,7 +137,6 @@ func TestAccCloudfunctions2function_cloudfunctions2FullExample(t *testing.T) {
139137

140138
func testAccCloudfunctions2function_cloudfunctions2FullExample(context map[string]interface{}) string {
141139
return acctest.Nprintf(`
142-
# [START functions_v2_full]
143140
locals {
144141
project = "%{project}" # Google Cloud Platform Project ID
145142
}
@@ -206,7 +203,6 @@ resource "google_cloudfunctions2_function" "function" {
206203
retry_policy = "RETRY_POLICY_RETRY"
207204
}
208205
}
209-
# [END functions_v2_full]
210206
`, context)
211207
}
212208

@@ -241,8 +237,6 @@ func TestAccCloudfunctions2function_cloudfunctions2BasicGcsExample(t *testing.T)
241237

242238
func testAccCloudfunctions2function_cloudfunctions2BasicGcsExample(context map[string]interface{}) string {
243239
return acctest.Nprintf(`
244-
# [START functions_v2_basic_gcs]
245-
246240
resource "google_storage_bucket" "source-bucket" {
247241
name = "tf-test-gcf-source-bucket%{random_suffix}"
248242
location = "US"
@@ -346,7 +340,6 @@ resource "google_cloudfunctions2_function" "function" {
346340
}
347341
}
348342
}
349-
# [END functions_v2_basic_gcs]
350343
`, context)
351344
}
352345

@@ -381,7 +374,6 @@ func TestAccCloudfunctions2function_cloudfunctions2BasicAuditlogsExample(t *test
381374

382375
func testAccCloudfunctions2function_cloudfunctions2BasicAuditlogsExample(context map[string]interface{}) string {
383376
return acctest.Nprintf(`
384-
# [START functions_v2_basic_auditlogs]
385377
# This example follows the examples shown in this Google Cloud Community blog post
386378
# https://medium.com/google-cloud/applying-a-path-pattern-when-filtering-in-eventarc-f06b937b4c34
387379
# and the docs:
@@ -490,7 +482,6 @@ resource "google_cloudfunctions2_function" "function" {
490482
}
491483
}
492484
}
493-
# [END functions_v2_basic_auditlogs]
494485
`, context)
495486
}
496487

website/docs/r/cloudfunctions2_function.html.markdown

-12
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ To get more information about function, see:
3030

3131

3232
```hcl
33-
# [START functions_v2_basic]
3433
locals {
3534
project = "my-project-name" # Google Cloud Platform Project ID
3635
}
@@ -73,13 +72,11 @@ resource "google_cloudfunctions2_function" "function" {
7372
output "function_uri" {
7473
value = google_cloudfunctions2_function.function.service_config[0].uri
7574
}
76-
# [END functions_v2_basic]
7775
```
7876
## Example Usage - Cloudfunctions2 Full
7977

8078

8179
```hcl
82-
# [START functions_v2_full]
8380
locals {
8481
project = "my-project-name" # Google Cloud Platform Project ID
8582
}
@@ -146,13 +143,11 @@ resource "google_cloudfunctions2_function" "function" {
146143
retry_policy = "RETRY_POLICY_RETRY"
147144
}
148145
}
149-
# [END functions_v2_full]
150146
```
151147
## Example Usage - Cloudfunctions2 Scheduler Auth
152148

153149

154150
```hcl
155-
# [START function_v2_scheduler_auth]
156151
locals {
157152
project = "my-project-name" # Google Cloud Platform Project ID
158153
}
@@ -230,15 +225,11 @@ resource "google_cloud_scheduler_job" "invoke_cloud_function" {
230225
}
231226
}
232227
}
233-
234-
# [END function_v2_scheduler_auth]
235228
```
236229
## Example Usage - Cloudfunctions2 Basic Gcs
237230

238231

239232
```hcl
240-
# [START functions_v2_basic_gcs]
241-
242233
resource "google_storage_bucket" "source-bucket" {
243234
name = "gcf-source-bucket"
244235
location = "US"
@@ -342,13 +333,11 @@ resource "google_cloudfunctions2_function" "function" {
342333
}
343334
}
344335
}
345-
# [END functions_v2_basic_gcs]
346336
```
347337
## Example Usage - Cloudfunctions2 Basic Auditlogs
348338

349339

350340
```hcl
351-
# [START functions_v2_basic_auditlogs]
352341
# This example follows the examples shown in this Google Cloud Community blog post
353342
# https://medium.com/google-cloud/applying-a-path-pattern-when-filtering-in-eventarc-f06b937b4c34
354343
# and the docs:
@@ -457,7 +446,6 @@ resource "google_cloudfunctions2_function" "function" {
457446
}
458447
}
459448
}
460-
# [END functions_v2_basic_auditlogs]
461449
```
462450
## Example Usage - Cloudfunctions2 Secret Env
463451

0 commit comments

Comments
 (0)