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%2FShardManagerTest.java;h=e9ad450ed86614ff78114ff4bb545e23ab82367f;hb=c74d5c2399e500fe3e690edc8cee497b1cb6f867;hp=268ed3c27383f3254eafec08e74c8f287456456a;hpb=3b4aea96013998f11450f5b83e4527bebd27af6a;p=controller.git diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardManagerTest.java b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardManagerTest.java index 268ed3c273..e9ad450ed8 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardManagerTest.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/test/java/org/opendaylight/controller/cluster/datastore/ShardManagerTest.java @@ -75,7 +75,7 @@ public class ShardManagerTest { subject.tell(new FindPrimary(Shard.DEFAULT_NAME).toSerializable(), getRef()); - expectMsgClass(PrimaryFound.SERIALIZABLE_CLASS); + expectMsgClass(duration("1 seconds"), PrimaryFound.SERIALIZABLE_CLASS); expectNoMsg(); } @@ -170,7 +170,7 @@ public class ShardManagerTest { subject.tell(new FindPrimary("astronauts").toSerializable(), getRef()); - final String out = new ExpectMsg("primary found") { + final String out = new ExpectMsg(duration("1 seconds"), "primary found") { // do not put code outside this method, will run afterwards protected String match(Object in) { if (in.getClass().equals(PrimaryFound.SERIALIZABLE_CLASS)) { @@ -208,13 +208,13 @@ public class ShardManagerTest { subject.tell(new FindPrimary("astronauts").toSerializable(), getRef()); - expectMsgClass(PrimaryFound.SERIALIZABLE_CLASS); + expectMsgClass(duration("1 seconds"), PrimaryFound.SERIALIZABLE_CLASS); MockClusterWrapper.sendMemberRemoved(subject, "member-2", getRef().path().toString()); subject.tell(new FindPrimary("astronauts").toSerializable(), getRef()); - expectMsgClass(PrimaryNotFound.SERIALIZABLE_CLASS); + expectMsgClass(duration("1 seconds"), PrimaryNotFound.SERIALIZABLE_CLASS); expectNoMsg(); }