Skip to content

Commit df630df

Browse files
committed
Fixing build fail
1 parent 2c690d0 commit df630df

File tree

1 file changed

+1
-59
lines changed

1 file changed

+1
-59
lines changed

mmv1/third_party/terraform/services/redis/resource_redis_cluster_test.go.tmpl

+1-59
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
package redis_test
22

33
import (
4-
{{- if ne $.TargetVersionName "ga" }}
5-
"strings"
6-
"os/exec"
7-
{{ end }}
84
"fmt"
95
"log"
106
"testing"
@@ -761,7 +757,6 @@ func testAccCheckRedisClusterExportBackup(t *testing.T, resourceName string, bac
761757
}
762758
}
763759

764-
765760
{{- if ne $.TargetVersionName "ga" }}
766761
// Validate that persistence is updated for the cluster
767762
func TestAccRedisCluster_persistenceUpdate(t *testing.T) {
@@ -1291,59 +1286,6 @@ func createRedisClusterResourceConfig(params *ClusterParams, isSecondaryCluster
12911286
`, params.ccrRole, pcBlock, scsBlock)
12921287
}
12931288

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-
13471289
return fmt.Sprintf(`
13481290
resource "google_redis_cluster" "%s" {
13491291
provider = google-beta
@@ -1381,4 +1323,4 @@ func createRedisClusterResourceConfig(params *ClusterParams, isSecondaryCluster
13811323
crossClusterReplicationConfigBlock,
13821324
dependsOnBlock)
13831325
}
1384-
{{ end }}
1326+
{{ end }}

0 commit comments

Comments
 (0)