Adjust to yangtools-2.0.0 changes
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / test / java / org / opendaylight / controller / cluster / databroker / actors / dds / AbstractDataStoreClientBehaviorTest.java
index 618933e0685cee1fc5a7830aaae4ab5e8f3bef54..57cf9fb9c3df978aa9682a9ce3d10e5f2403f484 100644 (file)
@@ -19,6 +19,7 @@ import akka.actor.Status;
 import akka.testkit.JavaTestKit;
 import akka.testkit.TestProbe;
 import java.util.Collections;
+import java.util.Optional;
 import org.junit.After;
 import org.junit.Assert;
 import org.junit.Before;
@@ -59,6 +60,7 @@ public abstract class AbstractDataStoreClientBehaviorTest {
         behavior = createBehavior(clientContext, context);
     }
 
+    @SuppressWarnings("checkstyle:hiddenField")
     protected abstract AbstractDataStoreClientBehavior createBehavior(ClientActorContext clientContext,
                                                                       ActorContext context);
 
@@ -134,7 +136,7 @@ public abstract class AbstractDataStoreClientBehaviorTest {
     public void testGetConnection() throws Exception {
         //set up data tree mock
         final CursorAwareDataTreeModification modification = mock(CursorAwareDataTreeModification.class);
-        when(modification.readNode(YangInstanceIdentifier.EMPTY)).thenReturn(com.google.common.base.Optional.absent());
+        when(modification.readNode(YangInstanceIdentifier.EMPTY)).thenReturn(Optional.empty());
         final DataTreeSnapshot snapshot = mock(DataTreeSnapshot.class);
         when(snapshot.newModification()).thenReturn(modification);
         final DataTree dataTree = mock(DataTree.class);
@@ -171,4 +173,4 @@ public abstract class AbstractDataStoreClientBehaviorTest {
         return mock;
     }
 
-}
\ No newline at end of file
+}