-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Description
Hi,
it seems that TestProbe can only be called 5 times. after that it breaks the test. I have a unit test like this:
class DatasetViewTest extends TestKit(ActorSystem("test")) with FlatSpecLike with Matchers {
trait TestContext {
val controller = TestProbe()
}
it should "1" in new TestContext {}
it should "2" in new TestContext {}
it should "3" in new TestContext {}
it should "4" in new TestContext {}
it should "5" in new TestContext {}
it should "6" in new TestContext {}
it should "7" in new TestContext {}
it should "8" in new TestContext {}
it should "9" in new TestContext {}
it should "10" in new TestContext {}
}
Only test 1-5 could run. then it stops with this error:
[error] (management / Test / testOnly) org.scalajs.testcommon.RPCCore$ClosedException: org.scalajs.jsenv.ComJSEnv$ComClosedException: JSCom has been closed
I could put val controller = TestProbe()
outsite scope of TestContext as a workaround, but some cases I have to redeclare it.
Thanks.
Metadata
Metadata
Assignees
Labels
No labels