aboutsummaryrefslogtreecommitdiffstats
path: root/src/test
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2013-02-23 16:22:29 -0600
committerJesse Luehrs <doy@tozt.net>2013-02-23 16:22:29 -0600
commit10281c72c781ed02df6cf82a3f309cd5234eef27 (patch)
tree43d58f3ad788c7ef28e2320d6fc296fed9b588a9 /src/test
parentf774c072d0a6b5b403289e3db72eb3d57ee15099 (diff)
downloadscala-test-more-10281c72c781ed02df6cf82a3f309cd5234eef27.tar.gz
scala-test-more-10281c72c781ed02df6cf82a3f309cd5234eef27.zip
don't need this anymore since it was moved inside the class
Diffstat (limited to 'src/test')
-rw-r--r--src/test/scala/org/perl8/test/TestMoreTest.scala13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/test/scala/org/perl8/test/TestMoreTest.scala b/src/test/scala/org/perl8/test/TestMoreTest.scala
index 7ee183a..bee1e64 100644
--- a/src/test/scala/org/perl8/test/TestMoreTest.scala
+++ b/src/test/scala/org/perl8/test/TestMoreTest.scala
@@ -5,10 +5,6 @@ import java.io.ByteArrayOutputStream
import org.perl8.test.tap.Consumer
class TestMoreTest extends TestMore {
- private object OutputContainer {
- val output = new ByteArrayOutputStream
- }
-
val lineZero = Thread.currentThread.getStackTrace()(1).getLineNumber + 3
def line (offset: Int) = lineZero + offset
@@ -61,13 +57,14 @@ class TestMoreTest extends TestMore {
}
}
- Console.withOut(OutputContainer.output) {
- Console.withErr(OutputContainer.output) {
+ val out = new ByteArrayOutputStream
+ Console.withOut(out) {
+ Console.withErr(out) {
(new MyBasicTest).run
}
}
- is(Consumer.parse(OutputContainer.output).exitCode, 9, "got the right plan")
+ is(Consumer.parse(out).exitCode, 9, "got the right plan")
val expected =
"# ok\n" +
@@ -145,5 +142,5 @@ class TestMoreTest extends TestMore {
"1..23\n" +
"# Looks like you failed 9 tests of 23.\n"
- is(OutputContainer.output.toString, expected, "correct tap")
+ is(out.toString, expected, "correct tap")
}