package org.opendaylight.openflowplugin.impl.services.sal;
+import static org.mockito.ArgumentMatchers.any;
+
import com.google.common.collect.Lists;
import java.util.List;
import java.util.concurrent.Future;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
+import org.mockito.ArgumentMatchers;
import org.mockito.Captor;
import org.mockito.InOrder;
-import org.mockito.Matchers;
import org.mockito.Mock;
import org.mockito.Mockito;
import org.mockito.runners.MockitoJUnitRunner;
public void setUp() throws Exception {
salMetersBatchService = new SalMetersBatchServiceImpl(salMeterService, transactionService);
- Mockito.when(transactionService.sendBarrier(Matchers.any()))
+ Mockito.when(transactionService.sendBarrier(any()))
.thenReturn(RpcResultBuilder.<SendBarrierOutput>success().buildFuture());
}
Assert.assertEquals(44, allValues.get(1).getOriginalMeter().getMeterId().getValue().longValue());
Assert.assertEquals(45, allValues.get(1).getUpdatedMeter().getMeterId().getValue().longValue());
- inOrder.verify(transactionService).sendBarrier(Matchers.<SendBarrierInput>any());
+ inOrder.verify(transactionService).sendBarrier(ArgumentMatchers.<SendBarrierInput>any());
}
@Test
Assert.assertEquals(44, allValues.get(1).getOriginalMeter().getMeterId().getValue().longValue());
Assert.assertEquals(45, allValues.get(1).getUpdatedMeter().getMeterId().getValue().longValue());
- inOrder.verify(transactionService).sendBarrier(Matchers.<SendBarrierInput>any());
+ inOrder.verify(transactionService).sendBarrier(ArgumentMatchers.<SendBarrierInput>any());
}
Assert.assertEquals(42L, allValues.get(0).getMeterId().getValue().longValue());
Assert.assertEquals(43L, allValues.get(1).getMeterId().getValue().longValue());
- inOrder.verify(transactionService).sendBarrier(Matchers.<SendBarrierInput>any());
+ inOrder.verify(transactionService).sendBarrier(ArgumentMatchers.<SendBarrierInput>any());
}
@Test
Assert.assertEquals(42L, allValues.get(0).getMeterId().getValue().longValue());
Assert.assertEquals(43L, allValues.get(1).getMeterId().getValue().longValue());
- inOrder.verify(transactionService).sendBarrier(Matchers.<SendBarrierInput>any());
+ inOrder.verify(transactionService).sendBarrier(ArgumentMatchers.<SendBarrierInput>any());
}
@Test
Assert.assertEquals(42L, allValues.get(0).getMeterId().getValue().longValue());
Assert.assertEquals(43L, allValues.get(1).getMeterId().getValue().longValue());
- inOrder.verify(transactionService).sendBarrier(Matchers.<SendBarrierInput>any());
+ inOrder.verify(transactionService).sendBarrier(ArgumentMatchers.<SendBarrierInput>any());
}
@Test
Assert.assertEquals(42L, allValues.get(0).getMeterId().getValue().longValue());
Assert.assertEquals(43L, allValues.get(1).getMeterId().getValue().longValue());
- inOrder.verify(transactionService).sendBarrier(Matchers.<SendBarrierInput>any());
+ inOrder.verify(transactionService).sendBarrier(ArgumentMatchers.<SendBarrierInput>any());
}
private static BatchAddMeters createEmptyBatchAddMeter(final long groupIdValue) {