Tests: Replace deprecated grpc.Dial by grpc.NewClient.

This commit is contained in:
Marco Ebert 2024-06-15 10:09:29 +02:00
parent d6dad98091
commit 67cd62c832

View file

@ -104,7 +104,7 @@ var _ = framework.DescribeAnnotation("backend-protocol - GRPC", func() {
})
//nolint:goconst //string interpolation
conn, err := grpc.Dial(f.GetNginxIP()+":443",
conn, err := grpc.NewClient(f.GetNginxIP()+":443",
grpc.WithTransportCredentials(
credentials.NewTLS(&tls.Config{
ServerName: echoHost,
@ -165,7 +165,7 @@ var _ = framework.DescribeAnnotation("backend-protocol - GRPC", func() {
return strings.Contains(server, "grpc_pass grpc://upstream_balancer;")
})
conn, err := grpc.Dial(f.GetNginxIP()+":443",
conn, err := grpc.NewClient(f.GetNginxIP()+":443",
grpc.WithTransportCredentials(
credentials.NewTLS(&tls.Config{
ServerName: echoHost,
@ -239,7 +239,7 @@ var _ = framework.DescribeAnnotation("backend-protocol - GRPC", func() {
return strings.Contains(server, "grpc_pass grpcs://upstream_balancer;")
})
conn, err := grpc.Dial(f.GetNginxIP()+":443",
conn, err := grpc.NewClient(f.GetNginxIP()+":443",
grpc.WithTransportCredentials(
credentials.NewTLS(&tls.Config{
ServerName: echoHost,