OPNFLWPLUG-1032: Neon-MRI: Bump odlparent, yangtools, mdsal
[openflowplugin.git] / applications / forwardingrules-sync / src / test / java / org / opendaylight / openflowplugin / applications / frsync / impl / SyncReactorGuardDecoratorTest.java
index 54609323e485a07962c7b7c4a6307136cb564ec8..8724c531747e97796864554b493a7b4ad36c6078 100644 (file)
@@ -12,7 +12,7 @@ import com.google.common.util.concurrent.Futures;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
-import org.mockito.Matchers;
+import org.mockito.ArgumentMatchers;
 import org.mockito.Mock;
 import org.mockito.Mockito;
 import org.mockito.runners.MockitoJUnitRunner;
@@ -52,13 +52,13 @@ public class SyncReactorGuardDecoratorTest {
         fcNodePath = nodePath.augmentation(FlowCapableNode.class);
 
         final Node operationalNode = Mockito.mock(Node.class);
-        Mockito.when(operationalNode.getId()).thenReturn(NODE_ID);
-        Mockito.when(operationalNode.augmentation(FlowCapableNode.class)).thenReturn(fcOperationalNode);
+        Mockito.lenient().when(operationalNode.getId()).thenReturn(NODE_ID);
+        Mockito.lenient().when(operationalNode.augmentation(FlowCapableNode.class)).thenReturn(fcOperationalNode);
     }
 
     @Test
     public void testSyncupSuccess() {
-        Mockito.when(delegate.syncup(Matchers.any(), Matchers.any()))
+        Mockito.when(delegate.syncup(ArgumentMatchers.any(), ArgumentMatchers.any()))
                 .thenReturn(Futures.immediateFuture(Boolean.TRUE));
 
         reactor.syncup(fcNodePath, syncupEntry);
@@ -69,7 +69,7 @@ public class SyncReactorGuardDecoratorTest {
 
     @Test
     public void testSyncupFail() {
-        Mockito.when(delegate.syncup(Matchers.any(), Matchers.any()))
+        Mockito.when(delegate.syncup(ArgumentMatchers.any(), ArgumentMatchers.any()))
                 .thenReturn(Futures.immediateFailedFuture(new Exception()));
 
         reactor.syncup(fcNodePath, syncupEntry);