14
14
package simple_regional_with_networking
15
15
16
16
import (
17
+ "strings"
17
18
"testing"
18
19
19
20
"github.com/GoogleCloudPlatform/cloud-foundation-toolkit/infra/blueprint-test/pkg/gcloud"
@@ -32,16 +33,16 @@ func TestSimpleRegionalWithNetworking(t *testing.T) {
32
33
projectId := bpt .GetStringOutput ("project_id" )
33
34
location := bpt .GetStringOutput ("location" )
34
35
clusterName := bpt .GetStringOutput ("cluster_name" )
35
- serviceAccount := bpt .GetStringOutput ("service_account" )
36
+ serviceAccount := strings . ReplaceAll ( bpt .GetStringOutput ("service_account" ), projectId , "PROJECT_ID " )
36
37
region := bpt .GetStringOutput ("region" )
37
38
subnetName := bpt .GetStringOutput ("subnet_name" )
38
39
ipRangeServicesName := bpt .GetStringOutput ("ip_range_services_name" )
39
40
ipRangePodName := bpt .GetStringOutput ("ip_range_pods_name" )
40
41
41
42
op := gcloud .Runf (t , "container clusters describe %s --zone %s --project %s" , clusterName , location , projectId )
42
43
g := golden .NewOrUpdate (t , op .String (),
43
- golden .WithSanitizer (golden .StringSanitizer (serviceAccount , "SERVICE_ACCOUNT" )),
44
44
golden .WithSanitizer (golden .StringSanitizer (projectId , "PROJECT_ID" )),
45
+ golden .WithSanitizer (golden .StringSanitizer (serviceAccount , "SERVICE_ACCOUNT" )),
45
46
golden .WithSanitizer (golden .StringSanitizer (clusterName , "CLUSTER_NAME" )),
46
47
)
47
48
validateJSONPaths := []string {
0 commit comments