@@ -2,7 +2,6 @@ package redis_test
2
2
3
3
import (
4
4
{{- if ne $.TargetVersionName "ga" }}
5
- "strings"
6
5
"os/exec"
7
6
{{ end }}
8
7
"fmt"
@@ -761,7 +760,6 @@ func testAccCheckRedisClusterExportBackup(t *testing.T, resourceName string, bac
761
760
}
762
761
}
763
762
764
-
765
763
{{- if ne $.TargetVersionName "ga" }}
766
764
// Validate that persistence is updated for the cluster
767
765
func TestAccRedisCluster_persistenceUpdate(t *testing.T) {
@@ -1291,59 +1289,6 @@ func createRedisClusterResourceConfig(params *ClusterParams, isSecondaryCluster
1291
1289
`, params.ccrRole, pcBlock, scsBlock)
1292
1290
}
1293
1291
1294
- return fmt.Sprintf(`
1295
- resource "google_redis_cluster" "%s" {
1296
- provider = google-beta
1297
- name = "%s"
1298
- replica_count = %d
1299
- shard_count = %d
1300
- node_type = "%s"
1301
- deletion_protection_enabled = %v
1302
- region = "us-central1"
1303
- psc_configs {
1304
- network = google_compute_network.producer_net.id
1305
- }
1306
- redis_configs = {
1307
- %s
1308
- }
1309
- %s
1310
- %s
1311
- %s
1312
- %s
1313
- depends_on = [
1314
- %s
1315
- ]
1316
- }
1317
- `,
1318
- tfClusterResourceName = "test_secondary"
1319
- clusterName = params.secondaryClusterName
1320
- dependsOnBlock = dependsOnBlock + ", google_redis_cluster.test"
1321
-
1322
- // Construct cross_cluster_replication_config block
1323
- pcBlock := ``
1324
- scsBlock := ``
1325
- if params.ccrRole == "SECONDARY" {
1326
- pcBlock = fmt.Sprintf(`
1327
- primary_cluster {
1328
- cluster = google_redis_cluster.test.id
1329
- }
1330
- `)
1331
- } else if params.ccrRole == "PRIMARY" {
1332
- scsBlock = fmt.Sprintf(`
1333
- secondary_clusters {
1334
- cluster = google_redis_cluster.test.id
1335
- }
1336
- `)
1337
- }
1338
- crossClusterReplicationConfigBlock = fmt.Sprintf(`
1339
- cross_cluster_replication_config {
1340
- cluster_role = "%s"
1341
- %s
1342
- %s
1343
- }
1344
- `, params.ccrRole, pcBlock, scsBlock)
1345
- }
1346
-
1347
1292
return fmt.Sprintf(`
1348
1293
resource "google_redis_cluster" "%s" {
1349
1294
provider = google-beta
@@ -1381,4 +1326,4 @@ func createRedisClusterResourceConfig(params *ClusterParams, isSecondaryCluster
1381
1326
crossClusterReplicationConfigBlock,
1382
1327
dependsOnBlock)
1383
1328
}
1384
- {{ end }}
1329
+ {{ end }}
0 commit comments