From 0057d4d83cb40116b76296505f15075002e4b2e0 Mon Sep 17 00:00:00 2001 From: James Iry Date: Mon, 22 Jul 2013 16:23:31 -0700 Subject: Make future-spec tests not spawn threads in constructors. The future-spec tests were spawning threads in object constructors which meant they were on the ragged edge of entering deadlock from the static initialization lock acquired during the static initialization blocks we use to construct object reference fields. My work on restructuring lambdas pushed it over the edge. This commit refactors the tests to use class constructors rather than object constructors. --- test/files/jvm/future-spec/PromiseTests.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'test/files/jvm/future-spec/PromiseTests.scala') diff --git a/test/files/jvm/future-spec/PromiseTests.scala b/test/files/jvm/future-spec/PromiseTests.scala index 6e613bf3ec..49350586b8 100644 --- a/test/files/jvm/future-spec/PromiseTests.scala +++ b/test/files/jvm/future-spec/PromiseTests.scala @@ -9,7 +9,7 @@ import scala.runtime.NonLocalReturnControl import scala.util.{Try,Success,Failure} -object PromiseTests extends MinimalScalaTest { +class PromiseTests extends MinimalScalaTest { import ExecutionContext.Implicits._ val defaultTimeout = Inf -- cgit v1.2.3