@@ -202,7 +202,7 @@ void testDubboChain() throws ReflectiveOperationException {
202202 span .hasName ("org.apache.dubbo.rpc.service.GenericService/$invoke" )
203203 .hasKind (SpanKind .CLIENT )
204204 .hasParent (trace .getSpan (0 ))
205- .hasAttributesSatisfyingExactly (attrs . toArray ( new AttributeAssertion [ 0 ]) );
205+ .hasAttributesSatisfyingExactly (attrs );
206206 },
207207 span -> {
208208 List <AttributeAssertion > attrs = new ArrayList <>();
@@ -217,7 +217,7 @@ void testDubboChain() throws ReflectiveOperationException {
217217 "io.opentelemetry.instrumentation.apachedubbo.v2_7.api.MiddleService/hello" )
218218 .hasKind (SpanKind .SERVER )
219219 .hasParent (trace .getSpan (1 ))
220- .hasAttributesSatisfying (attrs . toArray ( new AttributeAssertion [ 0 ]) );
220+ .hasAttributesSatisfying (attrs );
221221 },
222222 span -> {
223223 List <AttributeAssertion > attrs = new ArrayList <>();
@@ -241,7 +241,7 @@ void testDubboChain() throws ReflectiveOperationException {
241241 span .hasName ("org.apache.dubbo.rpc.service.GenericService/$invoke" )
242242 .hasKind (SpanKind .CLIENT )
243243 .hasParent (trace .getSpan (2 ))
244- .hasAttributesSatisfyingExactly (attrs . toArray ( new AttributeAssertion [ 0 ]) );
244+ .hasAttributesSatisfyingExactly (attrs );
245245 },
246246 span -> {
247247 List <AttributeAssertion > attrs = new ArrayList <>();
@@ -256,7 +256,7 @@ void testDubboChain() throws ReflectiveOperationException {
256256 "io.opentelemetry.instrumentation.apachedubbo.v2_7.api.HelloService/hello" )
257257 .hasKind (SpanKind .SERVER )
258258 .hasParent (trace .getSpan (3 ))
259- .hasAttributesSatisfying (attrs . toArray ( new AttributeAssertion [ 0 ]) );
259+ .hasAttributesSatisfying (attrs );
260260 }));
261261
262262 testing ()
@@ -278,8 +278,7 @@ void testDubboChain() throws ReflectiveOperationException {
278278 rpcMethodAssertions (
279279 "io.opentelemetry.instrumentation.apachedubbo.v2_7.api.HelloService" ,
280280 "hello" ));
281- point .hasAttributesSatisfyingExactly (
282- attrs .toArray (new AttributeAssertion [0 ]));
281+ point .hasAttributesSatisfyingExactly (attrs );
283282 },
284283 point -> {
285284 List <AttributeAssertion > attrs = new ArrayList <>();
@@ -288,8 +287,7 @@ void testDubboChain() throws ReflectiveOperationException {
288287 rpcMethodAssertions (
289288 "io.opentelemetry.instrumentation.apachedubbo.v2_7.api.MiddleService" ,
290289 "hello" ));
291- point .hasAttributesSatisfyingExactly (
292- attrs .toArray (new AttributeAssertion [0 ]));
290+ point .hasAttributesSatisfyingExactly (attrs );
293291 }))));
294292
295293 testing ()
@@ -319,8 +317,7 @@ void testDubboChain() throws ReflectiveOperationException {
319317 satisfies (
320318 NETWORK_TYPE ,
321319 AbstractDubboTest ::assertNetworkType ));
322- point .hasAttributesSatisfyingExactly (
323- attrs .toArray (new AttributeAssertion [0 ]));
320+ point .hasAttributesSatisfyingExactly (attrs );
324321 },
325322 point -> {
326323 List <AttributeAssertion > attrs = new ArrayList <>();
@@ -337,8 +334,7 @@ void testDubboChain() throws ReflectiveOperationException {
337334 satisfies (
338335 NETWORK_TYPE ,
339336 AbstractDubboTest ::assertNetworkType ));
340- point .hasAttributesSatisfyingExactly (
341- attrs .toArray (new AttributeAssertion [0 ]));
337+ point .hasAttributesSatisfyingExactly (attrs );
342338 }))));
343339 }
344340
@@ -413,7 +409,7 @@ void testDubboChainInJvm() throws ReflectiveOperationException {
413409 span .hasName ("org.apache.dubbo.rpc.service.GenericService/$invoke" )
414410 .hasKind (SpanKind .CLIENT )
415411 .hasParent (trace .getSpan (0 ))
416- .hasAttributesSatisfyingExactly (attrs . toArray ( new AttributeAssertion [ 0 ]) );
412+ .hasAttributesSatisfyingExactly (attrs );
417413 },
418414 span -> {
419415 List <AttributeAssertion > attrs = new ArrayList <>();
@@ -428,7 +424,7 @@ void testDubboChainInJvm() throws ReflectiveOperationException {
428424 "io.opentelemetry.instrumentation.apachedubbo.v2_7.api.MiddleService/hello" )
429425 .hasKind (SpanKind .SERVER )
430426 .hasParent (trace .getSpan (1 ))
431- .hasAttributesSatisfying (attrs . toArray ( new AttributeAssertion [ 0 ]) );
427+ .hasAttributesSatisfying (attrs );
432428 }));
433429
434430 testing ()
@@ -450,8 +446,7 @@ void testDubboChainInJvm() throws ReflectiveOperationException {
450446 rpcMethodAssertions (
451447 "io.opentelemetry.instrumentation.apachedubbo.v2_7.api.MiddleService" ,
452448 "hello" ));
453- point .hasAttributesSatisfyingExactly (
454- attrs .toArray (new AttributeAssertion [0 ]));
449+ point .hasAttributesSatisfyingExactly (attrs );
455450 }))));
456451
457452 testing ()
@@ -481,8 +476,7 @@ void testDubboChainInJvm() throws ReflectiveOperationException {
481476 satisfies (
482477 NETWORK_TYPE ,
483478 AbstractDubboTest ::assertNetworkType ));
484- point .hasAttributesSatisfyingExactly (
485- attrs .toArray (new AttributeAssertion [0 ]));
479+ point .hasAttributesSatisfyingExactly (attrs );
486480 }))));
487481 }
488482}
0 commit comments