From ffbfef8e69a35047de9bf405f9eb76c4dfe01829 Mon Sep 17 00:00:00 2001 From: Eric Zhang Date: Sat, 4 Jan 2025 18:59:27 -0500 Subject: [PATCH] add default event --- .../examples/secure_source_manager_hook_basic.tf.tmpl | 2 +- .../resource_secure_source_manager_hook_update_test.go | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/mmv1/templates/terraform/examples/secure_source_manager_hook_basic.tf.tmpl b/mmv1/templates/terraform/examples/secure_source_manager_hook_basic.tf.tmpl index 822d8205fc1f..e5d40b8d41e6 100644 --- a/mmv1/templates/terraform/examples/secure_source_manager_hook_basic.tf.tmpl +++ b/mmv1/templates/terraform/examples/secure_source_manager_hook_basic.tf.tmpl @@ -22,6 +22,6 @@ resource "google_secure_source_manager_hook" "basic" { repository_id = google_secure_source_manager_repository.repository.repository_id location = google_secure_source_manager_repository.repository.location target_uri = "https://www.example.com" - # default events + # default event events = ["PUSH"] } diff --git a/mmv1/third_party/terraform/services/securesourcemanager/resource_secure_source_manager_hook_update_test.go b/mmv1/third_party/terraform/services/securesourcemanager/resource_secure_source_manager_hook_update_test.go index 4c31d30e99a8..113c88af1293 100644 --- a/mmv1/third_party/terraform/services/securesourcemanager/resource_secure_source_manager_hook_update_test.go +++ b/mmv1/third_party/terraform/services/securesourcemanager/resource_secure_source_manager_hook_update_test.go @@ -102,7 +102,10 @@ resource "google_secure_source_manager_hook" "default" { location = google_secure_source_manager_repository.repository.location repository_id = google_secure_source_manager_repository.repository.repository_id events = ["PUSH", "PULL_REQUEST"] - target_uri = "https://www.updated.com" + push_option { + branch_filter = "main" + } + target_uri = "https://www.update.com" disabled = true } `, context)