@@ -389,8 +389,8 @@ func DoPerRPCCreds(ctx context.Context, tc testgrpc.TestServiceClient, serviceAc
389389 }
390390 token := GetToken (ctx , serviceAccountKeyFile , oauthScope )
391391 kv := map [string ]string {"authorization" : token .Type () + " " + token .AccessToken }
392- outCtx : = metadata .NewOutgoingContext (ctx , metadata.MD {"authorization" : []string {kv ["authorization" ]}})
393- reply , err := tc .UnaryCall (outCtx , req )
392+ ctx = metadata .NewOutgoingContext (ctx , metadata.MD {"authorization" : []string {kv ["authorization" ]}})
393+ reply , err := tc .UnaryCall (ctx , req )
394394 if err != nil {
395395 logger .Fatal ("/TestService/UnaryCall RPC failed: " , err )
396396 }
@@ -524,11 +524,11 @@ func DoCustomMetadata(ctx context.Context, tc testgrpc.TestServiceClient, args .
524524 ResponseSize : int32 (1 ),
525525 Payload : pl ,
526526 }
527- outCtx : = metadata .NewOutgoingContext (ctx , customMetadata )
527+ ctx = metadata .NewOutgoingContext (ctx , customMetadata )
528528 var header , trailer metadata.MD
529529 args = append (args , grpc .Header (& header ), grpc .Trailer (& trailer ))
530530 reply , err := tc .UnaryCall (
531- outCtx ,
531+ ctx ,
532532 req ,
533533 args ... ,
534534 )
@@ -543,7 +543,7 @@ func DoCustomMetadata(ctx context.Context, tc testgrpc.TestServiceClient, args .
543543 validateMetadata (header , trailer )
544544
545545 // Testing with FullDuplex.
546- stream , err := tc .FullDuplexCall (outCtx , args ... )
546+ stream , err := tc .FullDuplexCall (ctx , args ... )
547547 if err != nil {
548548 logger .Fatalf ("%v.FullDuplexCall(_) = _, %v, want <nil>" , tc , err )
549549 }
0 commit comments