Use ArgumentMatchers.anyList() 56/105056/1
authorRobert Varga <robert.varga@pantheon.tech>
Tue, 4 Apr 2023 07:18:59 +0000 (09:18 +0200)
committerRobert Varga <nite@hq.sk>
Wed, 5 Apr 2023 12:00:33 +0000 (12:00 +0000)
This is type-safe alternative, use it to remove a warning.

Change-Id: I5b7b7355410ecb84bfdf82fe1115b625cc16c048
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit ec0ade62668172b8ea0dcf89a6c21e98c98e4587)

pcep/spi/src/test/java/org/opendaylight/protocol/pcep/spi/RegistryTest.java

index adf1b4e35a970926494b13b204cb32526a6d63c7..37b28c0a07f331202ccda9e5b27e817fdc754ef0 100644 (file)
@@ -9,6 +9,7 @@ package org.opendaylight.protocol.pcep.spi;
 
 import static org.mockito.ArgumentMatchers.any;
 import static org.mockito.ArgumentMatchers.anyBoolean;
+import static org.mockito.ArgumentMatchers.anyList;
 import static org.mockito.Mockito.doNothing;
 import static org.mockito.Mockito.doReturn;
 
@@ -117,7 +118,7 @@ public class RegistryTest {
             any(ByteBuf.class));
         doNothing().when(this.objectSerializer).serializeObject(any(Object.class), any(ByteBuf.class));
 
-        doReturn(null).when(this.msgParser).parseMessage(any(ByteBuf.class), any(List.class));
+        doReturn(null).when(this.msgParser).parseMessage(any(ByteBuf.class), anyList());
         doNothing().when(this.msgSerializer).serializeMessage(any(Message.class), any(ByteBuf.class));
 
         doNothing().when(this.labelSerializer).serializeLabel(anyBoolean(), anyBoolean(), any(LabelType.class),