Switch to MD-SAL APIs
[openflowplugin.git] / openflowplugin-impl / src / test / java / org / opendaylight / openflowplugin / impl / statistics / services / direct / singlelayer / FlowDirectStatisticsServiceTest.java
index 22bfbe644e7cee3046cdee65eb2a1a6296925199..bcb761a8af5aa1d1b3a9e06b6e7d830e29ed0f6e 100644 (file)
@@ -5,22 +5,20 @@
  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
  * and is available at http://www.eclipse.org/legal/epl-v10.html
  */
-
 package org.opendaylight.openflowplugin.impl.statistics.services.direct.singlelayer;
 
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
-import static org.mockito.Matchers.any;
-import static org.mockito.Matchers.eq;
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.ArgumentMatchers.eq;
 import static org.mockito.Mockito.mock;
 import static org.mockito.Mockito.verify;
 import static org.mockito.Mockito.when;
 
 import java.math.BigInteger;
-import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
-import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
+import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
 import org.opendaylight.openflowplugin.api.openflow.device.Xid;
 import org.opendaylight.openflowplugin.api.openflow.registry.flow.DeviceFlowRegistry;
 import org.opendaylight.openflowplugin.impl.registry.flow.FlowDescriptorFactory;
@@ -62,14 +60,13 @@ public class FlowDirectStatisticsServiceTest extends AbstractDirectStatisticsSer
     public void testBuildRequestBody() throws Exception {
         final GetFlowStatisticsInput input = mock(GetFlowStatisticsInput.class);
 
-        when(input.getNode()).thenReturn(createNodeRef(NODE_ID));
         when(input.getTableId()).thenReturn(TABLE_NO);
 
         final MultipartRequestFlowStats body = (MultipartRequestFlowStats) ((MultipartRequest) service
             .buildRequest(new Xid(42L), input))
             .getMultipartRequestBody();
 
-        assertEquals(TABLE_NO, body.getTableId());
+        assertEquals(TABLE_NO, body.getFlowStats().getTableId());
     }
 
     @Override