X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-distributed-datastore%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fcluster%2Fdatastore%2FShardTransactionTest.java;h=9116f24c92971b3f0491b6de52d07eff01d84645;hb=refs%2Fchanges%2F70%2F8270%2F5;hp=075001b0d8327c17c03373126d0a1019da4d45fe;hpb=5ff14f6824d1a831b9c1def6b820a2516fed435f;p=controller.git diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardTransactionTest.java b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardTransactionTest.java index 075001b0d8..9116f24c92 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardTransactionTest.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardTransactionTest.java @@ -43,7 +43,8 @@ public class ShardTransactionTest extends AbstractActorTest { @Test public void testOnReceiveReadData() throws Exception { new JavaTestKit(getSystem()) {{ - final Props props = ShardTransaction.props(store.newReadWriteTransaction()); + final ActorRef shard = getSystem().actorOf(Shard.props("config")); + final Props props = ShardTransaction.props(store.newReadWriteTransaction(), shard); final ActorRef subject = getSystem().actorOf(props, "testReadData"); new Within(duration("1 seconds")) { @@ -103,7 +104,8 @@ public class ShardTransactionTest extends AbstractActorTest { @Test public void testOnReceiveWriteData() throws Exception { new JavaTestKit(getSystem()) {{ - final Props props = ShardTransaction.props(store.newReadWriteTransaction()); + final ActorRef shard = getSystem().actorOf(Shard.props("config")); + final Props props = ShardTransaction.props(store.newReadWriteTransaction(), shard); final ActorRef subject = getSystem().actorOf(props, "testWriteData"); new Within(duration("1 seconds")) { @@ -136,7 +138,8 @@ public class ShardTransactionTest extends AbstractActorTest { @Test public void testOnReceiveMergeData() throws Exception { new JavaTestKit(getSystem()) {{ - final Props props = ShardTransaction.props(store.newReadWriteTransaction()); + final ActorRef shard = getSystem().actorOf(Shard.props("config")); + final Props props = ShardTransaction.props(store.newReadWriteTransaction(), shard); final ActorRef subject = getSystem().actorOf(props, "testMergeData"); new Within(duration("1 seconds")) { @@ -170,7 +173,8 @@ public class ShardTransactionTest extends AbstractActorTest { @Test public void testOnReceiveDeleteData() throws Exception { new JavaTestKit(getSystem()) {{ - final Props props = ShardTransaction.props(store.newReadWriteTransaction()); + final ActorRef shard = getSystem().actorOf(Shard.props("config")); + final Props props = ShardTransaction.props(store.newReadWriteTransaction(), shard); final ActorRef subject = getSystem().actorOf(props, "testDeleteData"); new Within(duration("1 seconds")) { @@ -204,7 +208,8 @@ public class ShardTransactionTest extends AbstractActorTest { @Test public void testOnReceiveReadyTransaction() throws Exception { new JavaTestKit(getSystem()) {{ - final Props props = ShardTransaction.props(store.newReadWriteTransaction()); + final ActorRef shard = getSystem().actorOf(Shard.props("config")); + final Props props = ShardTransaction.props(store.newReadWriteTransaction(), shard); final ActorRef subject = getSystem().actorOf(props, "testReadyTransaction"); new Within(duration("1 seconds")) { @@ -237,7 +242,8 @@ public class ShardTransactionTest extends AbstractActorTest { @Test public void testOnReceiveCloseTransaction() throws Exception { new JavaTestKit(getSystem()) {{ - final Props props = ShardTransaction.props(store.newReadWriteTransaction()); + final ActorRef shard = getSystem().actorOf(Shard.props("config")); + final Props props = ShardTransaction.props(store.newReadWriteTransaction(), shard); final ActorRef subject = getSystem().actorOf(props, "testCloseTransaction"); new Within(duration("1 seconds")) {