Honor timeout parameter when stopping actors #30715 (#30717)

This commit is contained in:
David Barrett 2021-09-27 16:37:54 +01:00 committed by GitHub
parent 5f38eb297f
commit 46bae17854
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -255,7 +255,7 @@ final class ActorTestKit private[akka] (
try {
Await.result(internalTestKitGuardian.ask { (x: ActorRef[ActorTestKitGuardian.Ack.type]) =>
ActorTestKitGuardian.StopActor(ref, x)
}, max)
}(Timeout(max), scheduler), max)
} catch {
case _: TimeoutException =>
assert(false, s"timeout ($max) during stop() waiting for actor [${ref.path}] to stop")