@@ -33,6 +33,7 @@ import (
3333 "golang.stackrox.io/grpc-http1/server"
3434 "google.golang.org/grpc"
3535 "google.golang.org/grpc/codes"
36+ "google.golang.org/grpc/credentials/insecure"
3637 "google.golang.org/grpc/examples/features/proto/echo"
3738 "google.golang.org/grpc/metadata"
3839 "google.golang.org/grpc/status"
@@ -374,15 +375,15 @@ func (c *testCase) Run(t *testing.T, cfg *testConfig) {
374375 )
375376
376377 if c .useProxy {
377- opts := []client.ConnectOption {client .DialOpts (grpc .WithInsecure ( ))}
378+ opts := []client.ConnectOption {client .DialOpts (grpc .WithTransportCredentials ( insecure . NewCredentials () ))}
378379 if ! c .behindHTTP1ReverseProxy {
379380 opts = append (opts , client .ForceHTTP2 ())
380381 }
381382 opts = append (opts , client .UseWebSocket (c .useWebSocket ), client .ForceDowngrade (c .forceDowngrade ))
382383
383384 cc , err = client .ConnectViaProxy (ctx , targetAddr , nil , opts ... )
384385 } else {
385- cc , err = grpc .DialContext (ctx , targetAddr , grpc .WithInsecure ( ))
386+ cc , err = grpc .DialContext (ctx , targetAddr , grpc .WithTransportCredentials ( insecure . NewCredentials () ))
386387 }
387388 require .NoError (t , err , "failed to establish connection" )
388389
0 commit comments