Reduce use of scala.concurrent.duration.Duration
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / test / java / org / opendaylight / controller / cluster / datastore / entityownership / DistributedEntityOwnershipServiceTest.java
index 70345f883d09b9faf801963b6ab66991e53ad2b7..3ca33ef2b0e7c7ea7e0e352839e8de118278ccd5 100644 (file)
@@ -29,9 +29,9 @@ import static org.opendaylight.controller.cluster.datastore.entityownership.Enti
 import static org.opendaylight.controller.cluster.datastore.entityownership.EntityOwnersModel.entityTypeEntryWithEntityEntry;
 
 import akka.actor.ActorRef;
-import com.google.common.base.Optional;
 import com.google.common.collect.Sets;
 import java.util.Collection;
+import java.util.Optional;
 import java.util.concurrent.TimeUnit;
 import org.junit.After;
 import org.junit.Before;
@@ -67,7 +67,7 @@ import org.opendaylight.yangtools.yang.data.api.schema.tree.TreeType;
 import org.opendaylight.yangtools.yang.data.impl.schema.ImmutableNodes;
 import scala.concurrent.Await;
 import scala.concurrent.Future;
-import scala.concurrent.duration.Duration;
+import scala.concurrent.duration.FiniteDuration;
 
 /**
  * Unit tests for DistributedEntityOwnershipService.
@@ -123,7 +123,7 @@ public class DistributedEntityOwnershipServiceTest extends AbstractClusterRefEnt
 
         Future<ActorRef> future = dataStore.getActorContext().findLocalShardAsync(
                 DistributedEntityOwnershipService.ENTITY_OWNERSHIP_SHARD_NAME);
-        ActorRef shardActor = Await.result(future, Duration.create(10, TimeUnit.SECONDS));
+        ActorRef shardActor = Await.result(future, FiniteDuration.create(10, TimeUnit.SECONDS));
         assertNotNull(DistributedEntityOwnershipService.ENTITY_OWNERSHIP_SHARD_NAME + " not found", shardActor);
 
         service.close();