@@ -12,7 +12,6 @@ import (
1212
1313 "github.com/google/go-cmp/cmp"
1414 "github.com/google/go-cmp/cmp/cmpopts"
15- "go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
1615 "golang.org/x/oauth2/google"
1716 "google.golang.org/api/internal"
1817 "google.golang.org/grpc"
@@ -135,28 +134,22 @@ func TestApplyClientCertSource(t *testing.T) {
135134 }
136135}
137136
138- func TestOtelHTTPOpts (t * testing.T ) {
139- otelhttpopts := []otelhttp. Option {
140- otelhttp . WithServerName ( "test" ) ,
137+ func TestOpenTelemetryOpts (t * testing.T ) {
138+ otelOpts := []any {
139+ "non- otelhttp-otelgrpc-option" ,
141140 }
142141 opts := []ClientOption {
143- WithOtelHTTPOpts ( otelhttpopts ... ),
142+ WithOpenTelemetryOpts ( otelOpts ... ),
144143 }
145144 var got internal.DialSettings
146145 for _ , opt := range opts {
147146 opt .Apply (& got )
148147 }
149148 want := internal.DialSettings {
150- OtelHTTPOpts : []otelhttp.Option {
151- otelhttp .WithServerName ("test" ),
152- },
149+ OpenTelemetryOpts : []any {},
153150 }
154151
155- comparer := cmp .Comparer (func (x , y internal.DialSettings ) bool {
156- return len (x .OtelHTTPOpts ) == len (y .OtelHTTPOpts )
157- })
158-
159- if ! cmp .Equal (got , want , comparer ) {
160- t .Error (cmp .Diff (got , want , comparer ))
152+ if cmp .Equal (got , want ) {
153+ t .Error (cmp .Diff (got , want ))
161154 }
162155}
0 commit comments