diff options
author | aleksandar <aleksandar@lampmac14.epfl.ch> | 2011-12-12 18:17:58 +0100 |
---|---|---|
committer | aleksandar <aleksandar@lampmac14.epfl.ch> | 2011-12-12 18:17:58 +0100 |
commit | 249aa978e7900a792594d51b45f4560568f1552c (patch) | |
tree | 057f142a07b8643294b74f06d853a4836f45b939 /test/files/jvm/concurrent-future.scala | |
parent | 7021aef3fd8a20c8f730af36f229e7bb2cfe8fb5 (diff) | |
parent | c2a52307bf60ca9d8b8d4980d8594284ff320dab (diff) | |
download | scala-249aa978e7900a792594d51b45f4560568f1552c.tar.gz scala-249aa978e7900a792594d51b45f4560568f1552c.tar.bz2 scala-249aa978e7900a792594d51b45f4560568f1552c.zip |
Merge branch 'execution-context' of github.com:phaller/scala into execution-context
Conflicts:
test/files/jvm/concurrent-future.scala
Diffstat (limited to 'test/files/jvm/concurrent-future.scala')
-rw-r--r-- | test/files/jvm/concurrent-future.scala | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/test/files/jvm/concurrent-future.scala b/test/files/jvm/concurrent-future.scala index 8fb237eb0a..eb3bbad591 100644 --- a/test/files/jvm/concurrent-future.scala +++ b/test/files/jvm/concurrent-future.scala @@ -44,7 +44,7 @@ object Test extends App { def testOnSuccessWhenFailed(): Unit = once { done => - val f = future { + val f = future[Unit] { output(3, "hai world") done() throw new Exception @@ -56,7 +56,7 @@ object Test extends App { def testOnFailure(): Unit = once { done => - val f = future { + val f = future[Unit] { output(4, "hai world") throw new Exception } @@ -64,16 +64,15 @@ object Test extends App { output(4, "onoes") done() } - f onFailure { - case _ => - output(4, "kthxbye") - done() + f onFailure { case _ => + output(4, "kthxbye") + done() } } def testOnFailureWhenSpecialThrowable(num: Int, cause: Throwable): Unit = once { done => - val f = future { + val f = future[Unit] { output(num, "hai world") throw cause } @@ -93,7 +92,7 @@ object Test extends App { def testOnFailureWhenFutureTimeoutException(): Unit = once { done => - val f = future { + val f = future[Unit] { output(8, "hai world") throw new FutureTimeoutException(null) } |