@@ -19,7 +19,6 @@ func TestAccBigqueryDataTransferConfig(t *testing.T) {
1919 "service_account" : testAccBigqueryDataTransferConfig_scheduledQuery_with_service_account ,
2020 "no_destintation" : testAccBigqueryDataTransferConfig_scheduledQuery_no_destination ,
2121 "booleanParam" : testAccBigqueryDataTransferConfig_copy_booleanParam ,
22- "update_params" : testAccBigqueryDataTransferConfig_force_new_update_params ,
2322 }
2423
2524 for name , tc := range testCases {
@@ -169,45 +168,6 @@ func testAccBigqueryDataTransferConfig_copy_booleanParam(t *testing.T) {
169168 })
170169}
171170
172- func testAccBigqueryDataTransferConfig_force_new_update_params (t * testing.T ) {
173- random_suffix := randString (t , 10 )
174-
175- vcrTest (t , resource.TestCase {
176- PreCheck : func () { testAccPreCheck (t ) },
177- Providers : testAccProviders ,
178- CheckDestroy : testAccCheckBigqueryDataTransferConfigDestroyProducer (t ),
179- Steps : []resource.TestStep {
180- {
181- Config : testAccBigqueryDataTransferConfig_update_params_force_new (random_suffix , "old" , "old" ),
182- },
183- {
184- ResourceName : "google_bigquery_data_transfer_config.update_config" ,
185- ImportState : true ,
186- ImportStateVerify : true ,
187- ImportStateVerifyIgnore : []string {"location" },
188- },
189- {
190- Config : testAccBigqueryDataTransferConfig_update_params_force_new (random_suffix , "new" , "old" ),
191- },
192- {
193- ResourceName : "google_bigquery_data_transfer_config.update_config" ,
194- ImportState : true ,
195- ImportStateVerify : true ,
196- ImportStateVerifyIgnore : []string {"location" },
197- },
198- {
199- Config : testAccBigqueryDataTransferConfig_update_params_force_new (random_suffix , "new" , "new" ),
200- },
201- {
202- ResourceName : "google_bigquery_data_transfer_config.update_config" ,
203- ImportState : true ,
204- ImportStateVerify : true ,
205- ImportStateVerifyIgnore : []string {"location" },
206- },
207- },
208- })
209- }
210-
211171func testAccCheckBigqueryDataTransferConfigDestroyProducer (t * testing.T ) func (s * terraform.State ) error {
212172 return func (s * terraform.State ) error {
213173 for name , rs := range s .RootModule ().Resources {
@@ -409,29 +369,3 @@ resource "google_bigquery_data_transfer_config" "copy_config" {
409369}
410370` , random_suffix , random_suffix , random_suffix )
411371}
412-
413- func testAccBigqueryDataTransferConfig_update_params_force_new (random_suffix , path , table string ) string {
414- return fmt .Sprintf (`
415- resource "google_bigquery_dataset" "dataset" {
416- dataset_id = "tf_test_%s"
417- friendly_name = "foo"
418- description = "bar"
419- location = "US"
420- }
421-
422- resource "google_bigquery_data_transfer_config" "update_config" {
423- display_name = "tf-test-%s"
424- data_source_id = "google_cloud_storage"
425- destination_dataset_id = google_bigquery_dataset.dataset.dataset_id
426- location = google_bigquery_dataset.dataset.location
427-
428- params = {
429- data_path_template = "gs://bq-bucket-%s-%s/*.json"
430- destination_table_name_template = "the-table-%s-%s"
431- file_format = "JSON"
432- max_bad_records = 0
433- write_disposition = "APPEND"
434- }
435- }
436- ` , random_suffix , random_suffix , random_suffix , path , random_suffix , table )
437- }
0 commit comments