diff options
author | Philipp Haller <hallerp@gmail.com> | 2009-05-27 22:58:02 +0000 |
---|---|---|
committer | Philipp Haller <hallerp@gmail.com> | 2009-05-27 22:58:02 +0000 |
commit | e8e1e61177069cdb89e89b3a41459ae19e84e914 (patch) | |
tree | 3506a8ec3921e1a0e5aac95a45bf8db1f642868b /test/files/jvm/daemon-actor-termination.scala | |
parent | 359d4609491a10543c08f2e65db0ec0f05b52705 (diff) | |
download | scala-e8e1e61177069cdb89e89b3a41459ae19e84e914.tar.gz scala-e8e1e61177069cdb89e89b3a41459ae19e84e914.tar.bz2 scala-e8e1e61177069cdb89e89b3a41459ae19e84e914.zip |
Added test for #2000.
Diffstat (limited to 'test/files/jvm/daemon-actor-termination.scala')
-rw-r--r-- | test/files/jvm/daemon-actor-termination.scala | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/test/files/jvm/daemon-actor-termination.scala b/test/files/jvm/daemon-actor-termination.scala index 322efbe212..c3dd58e253 100644 --- a/test/files/jvm/daemon-actor-termination.scala +++ b/test/files/jvm/daemon-actor-termination.scala @@ -1,8 +1,16 @@ -import scala.actors.DaemonActor +import scala.actors.{Actor, DefaultExecutorScheduler} -/* Test that a DaemonActor that hasn't finished does not prevent termination */ +/* Test that a daemon Actor that hasn't finished does not prevent termination */ + +trait DaemonActor extends Actor { + override def scheduler = + Test.daemonSched +} object Test { + val daemonSched = + new DefaultExecutorScheduler(true) + class MyDaemon extends DaemonActor { def act() { println("I'm going to make you wait.") |