Decreased the time to wait in SchedulerSpec to make tests run a wee bit faster, see #1291
This commit is contained in:
parent
463c6921d6
commit
35d4d0456d
1 changed files with 3 additions and 3 deletions
|
|
@ -127,7 +127,7 @@ class SchedulerSpec extends AkkaSpec with BeforeAndAfterEach {
|
|||
}
|
||||
|
||||
"never fire prematurely" in {
|
||||
val ticks = new CountDownLatch(5000)
|
||||
val ticks = new CountDownLatch(300)
|
||||
|
||||
case class Msg(ts: Long)
|
||||
|
||||
|
|
@ -141,12 +141,12 @@ class SchedulerSpec extends AkkaSpec with BeforeAndAfterEach {
|
|||
}
|
||||
})
|
||||
|
||||
(1 to 5000).foreach { i ⇒
|
||||
(1 to 300).foreach { i ⇒
|
||||
collectCancellable(system.scheduler.scheduleOnce(actor, Msg(System.currentTimeMillis), 10 milliseconds))
|
||||
Thread.sleep(5)
|
||||
}
|
||||
|
||||
assert(ticks.await(20, TimeUnit.SECONDS) == true)
|
||||
assert(ticks.await(3, TimeUnit.SECONDS) == true)
|
||||
}
|
||||
|
||||
"schedule with different initial delay and frequency" in {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue