X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-distributed-datastore%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fcluster%2Fdatastore%2FDistributedDataStoreTest.java;h=2a9356e63d495d15d20b6be45960e5ac9a6bc697;hp=6544f3303022b698580d24f350073e5a79fa7b55;hb=9c0508d8b591e356f145d5d1a277c10965a647bb;hpb=8eabfd813c5d19bbe9c2ab01ccbff32eeec58419 diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/DistributedDataStoreTest.java b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/DistributedDataStoreTest.java index 6544f33030..2a9356e63d 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/DistributedDataStoreTest.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/DistributedDataStoreTest.java @@ -1,6 +1,7 @@ package org.opendaylight.controller.cluster.datastore; import junit.framework.Assert; +import org.opendaylight.controller.md.cluster.datastore.model.TestModel; import org.opendaylight.controller.md.sal.common.api.data.AsyncDataBroker; import org.opendaylight.controller.md.sal.common.api.data.AsyncDataChangeEvent; import org.opendaylight.controller.md.sal.common.api.data.AsyncDataChangeListener; @@ -12,13 +13,14 @@ import org.opendaylight.yangtools.concepts.ListenerRegistration; import org.opendaylight.yangtools.yang.data.api.InstanceIdentifier; import org.opendaylight.yangtools.yang.data.api.schema.NormalizedNode; -public class DistributedDataStoreTest { +public class DistributedDataStoreTest extends AbstractActorTest{ private DistributedDataStore distributedDataStore; @org.junit.Before public void setUp() throws Exception { - distributedDataStore = new DistributedDataStore(); + distributedDataStore = new DistributedDataStore(getSystem(), "config"); + distributedDataStore.onGlobalContextUpdated(TestModel.createTestContext()); } @org.junit.After @@ -29,7 +31,7 @@ public class DistributedDataStoreTest { @org.junit.Test public void testRegisterChangeListener() throws Exception { ListenerRegistration registration = - distributedDataStore.registerChangeListener(InstanceIdentifier.builder().build(), new AsyncDataChangeListener>() { + distributedDataStore.registerChangeListener(TestModel.TEST_PATH, new AsyncDataChangeListener>() { @Override public void onDataChanged(AsyncDataChangeEvent> change) { throw new UnsupportedOperationException("onDataChanged");