diff options
Diffstat (limited to 'test/files/run/boolexprs.scala')
-rw-r--r-- | test/files/run/boolexprs.scala | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/test/files/run/boolexprs.scala b/test/files/run/boolexprs.scala index b5bc5f7787..7080f84b56 100644 --- a/test/files/run/boolexprs.scala +++ b/test/files/run/boolexprs.scala @@ -34,29 +34,27 @@ object Test2 { // Test code object Test { - import java.lang.System; - def check_success(name: String, closure: => Int, expected: Int): Unit = { - System.out.print("test " + name); + Console.print("test " + name); try { val actual: Int = closure; if (actual == expected) { - System.out.print(" was successful"); + Console.print(" was successful"); } else { - System.out.print(" failed: expected "+ expected +", found "+ actual); + Console.print(" failed: expected "+ expected +", found "+ actual); } } catch { case exception: Throwable => { - System.out.print(" raised exception " + exception); + Console.print(" raised exception " + exception); } } - System.out.println(); + Console.println; } def main(args: Array[String]): Unit = { check_success("Test1", Test1.run, 1); check_success("Test2", Test2.run, 0); - System.out.println(); + Console.println; } } |