@@ -46,8 +46,6 @@ var wantInstrumentationScope = instrumentation.Scope{
46
46
Version : otelgrpc .Version (),
47
47
}
48
48
49
- const bufSize = 2048
50
-
51
49
// newGrpcTest creats a grpc server, starts it, and executes all the calls, closes everything down.
52
50
func newGrpcTest (listener net.Listener , cOpt []grpc.DialOption , sOpt []grpc.ServerOption ) error {
53
51
grpcServer := grpc .NewServer (sOpt ... )
@@ -108,18 +106,19 @@ func TestInterceptors(t *testing.T) {
108
106
109
107
listener , err := net .Listen ("tcp" , "127.0.0.1:0" )
110
108
require .NoError (t , err , "failed to open port" )
111
- err = newGrpcTest (listener , []grpc.DialOption {
112
- //nolint:staticcheck // Interceptors are deprecated and will be removed in the next release.
113
- grpc .WithUnaryInterceptor (otelgrpc .UnaryClientInterceptor (
114
- otelgrpc .WithTracerProvider (clientUnaryTP ),
115
- otelgrpc .WithMessageEvents (otelgrpc .ReceivedEvents , otelgrpc .SentEvents ),
116
- )),
117
- //nolint:staticcheck // Interceptors are deprecated and will be removed in the next release.
118
- grpc .WithStreamInterceptor (otelgrpc .StreamClientInterceptor (
119
- otelgrpc .WithTracerProvider (clientStreamTP ),
120
- otelgrpc .WithMessageEvents (otelgrpc .ReceivedEvents , otelgrpc .SentEvents ),
121
- )),
122
- },
109
+ err = newGrpcTest (listener ,
110
+ []grpc.DialOption {
111
+ //nolint:staticcheck // Interceptors are deprecated and will be removed in the next release.
112
+ grpc .WithUnaryInterceptor (otelgrpc .UnaryClientInterceptor (
113
+ otelgrpc .WithTracerProvider (clientUnaryTP ),
114
+ otelgrpc .WithMessageEvents (otelgrpc .ReceivedEvents , otelgrpc .SentEvents ),
115
+ )),
116
+ //nolint:staticcheck // Interceptors are deprecated and will be removed in the next release.
117
+ grpc .WithStreamInterceptor (otelgrpc .StreamClientInterceptor (
118
+ otelgrpc .WithTracerProvider (clientStreamTP ),
119
+ otelgrpc .WithMessageEvents (otelgrpc .ReceivedEvents , otelgrpc .SentEvents ),
120
+ )),
121
+ },
123
122
[]grpc.ServerOption {
124
123
//nolint:staticcheck // Interceptors are deprecated and will be removed in the next release.
125
124
grpc .UnaryInterceptor (otelgrpc .UnaryServerInterceptor (
0 commit comments