1
1
package discoveryengine_test
2
2
3
3
import (
4
+ "testing"
5
+
4
6
"github.com/hashicorp/terraform-plugin-testing/helper/resource"
5
7
"github.com/hashicorp/terraform-provider-google/google/acctest"
6
- "testing"
7
8
)
8
9
9
10
func TestAccDiscoveryEngineSearchEngine_discoveryengineSearchengineBasicExample_update (t * testing.T ) {
@@ -53,12 +54,21 @@ resource "google_discovery_engine_data_store" "basic" {
53
54
solution_types = ["SOLUTION_TYPE_SEARCH"]
54
55
create_advanced_site_search = false
55
56
}
57
+ resource "google_discovery_engine_data_store" "second" {
58
+ location = "global"
59
+ data_store_id = "tf-test-example2-datastore%{random_suffix}"
60
+ display_name = "tf-test-structured-datastore2"
61
+ industry_vertical = "GENERIC"
62
+ content_config = "NO_CONTENT"
63
+ solution_types = ["SOLUTION_TYPE_SEARCH"]
64
+ create_advanced_site_search = false
65
+ }
56
66
resource "google_discovery_engine_search_engine" "basic" {
57
67
engine_id = "tf-test-example-engine-id%{random_suffix}"
58
68
collection_id = "default_collection"
59
69
location = google_discovery_engine_data_store.basic.location
60
70
display_name = "Example Display Name"
61
- data_store_ids = [google_discovery_engine_data_store.basic.data_store_id]
71
+ data_store_ids = [google_discovery_engine_data_store.basic.data_store_id, google_discovery_engine_data_store.second.data_store_id ]
62
72
industry_vertical = google_discovery_engine_data_store.basic.industry_vertical
63
73
common_config {
64
74
company_name = "Example Company Name"
@@ -82,6 +92,15 @@ resource "google_discovery_engine_data_store" "basic" {
82
92
solution_types = ["SOLUTION_TYPE_SEARCH"]
83
93
create_advanced_site_search = false
84
94
}
95
+ resource "google_discovery_engine_data_store" "second" {
96
+ location = "global"
97
+ data_store_id = "tf-test-example2-datastore%{random_suffix}"
98
+ display_name = "tf-test-structured-datastore2"
99
+ industry_vertical = "GENERIC"
100
+ content_config = "NO_CONTENT"
101
+ solution_types = ["SOLUTION_TYPE_SEARCH"]
102
+ create_advanced_site_search = false
103
+ }
85
104
resource "google_discovery_engine_search_engine" "basic" {
86
105
engine_id = "tf-test-example-engine-id%{random_suffix}"
87
106
collection_id = "default_collection"
0 commit comments