From 53ad96ed92bb6488efef9e4acb08b9c12ab1fc8b Mon Sep 17 00:00:00 2001 From: Patrik Nordwall Date: Fri, 17 Jan 2014 20:38:52 +0100 Subject: [PATCH] =per #3820 Increase some test timeouts in persistence * reproduced the problem with sleep in LeveldbStore --- .../src/test/scala/akka/persistence/ChannelSpec.scala | 2 +- .../src/test/scala/akka/persistence/EventsourcedSpec.scala | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/akka-persistence/src/test/scala/akka/persistence/ChannelSpec.scala b/akka-persistence/src/test/scala/akka/persistence/ChannelSpec.scala index f6ed598f11..134b66b979 100644 --- a/akka-persistence/src/test/scala/akka/persistence/ChannelSpec.scala +++ b/akka-persistence/src/test/scala/akka/persistence/ChannelSpec.scala @@ -189,7 +189,7 @@ abstract class ChannelSpec(config: Config) extends AkkaSpec(config) with Persist 1 to 3 foreach { i ⇒ channel ! Deliver(Persistent(i), system.deadLetters.path) } - probe.expectMsgAllOf(1, 2, 3) + probe.expectMsgAllOf(10.seconds, 1, 2, 3) system.stop(channel) } } diff --git a/akka-persistence/src/test/scala/akka/persistence/EventsourcedSpec.scala b/akka-persistence/src/test/scala/akka/persistence/EventsourcedSpec.scala index dd9a609cb1..74dcbd637a 100644 --- a/akka-persistence/src/test/scala/akka/persistence/EventsourcedSpec.scala +++ b/akka-persistence/src/test/scala/akka/persistence/EventsourcedSpec.scala @@ -5,6 +5,7 @@ package akka.persistence import scala.collection.immutable.Seq +import scala.concurrent.duration._ import com.typesafe.config.Config @@ -310,7 +311,7 @@ abstract class EventsourcedSpec(config: Config) extends AkkaSpec(config) with Pe expectMsg("c") expectMsg("a") } - "support user stash operations with several stashed messages" in { + "support user stash operations with several stashed messages" in within(10.seconds) { val processor = namedProcessor[UserStashManyProcessor] val n = 10 val cmds = 1 to n flatMap (_ ⇒ List(Cmd("a"), Cmd("b-1"), Cmd("b-2"), Cmd("c"))) @@ -320,7 +321,7 @@ abstract class EventsourcedSpec(config: Config) extends AkkaSpec(config) with Pe processor ! GetState expectMsg((List("a-1", "a-2") ++ evts)) } - "support user stash operations under failures" in { + "support user stash operations under failures" in within(5.seconds) { val processor = namedProcessor[UserStashFailureProcessor] val bs = 1 to 10 map ("b-" + _) processor ! Cmd("a")