]> Dogcows Code - chaz/sbt-tap/commitdiff
output start/end group as tap diagnostics
authorCharles McGarvey <chazmcgarvey@brokenzipper.com>
Fri, 11 Jan 2013 22:25:26 +0000 (15:25 -0700)
committerCharles McGarvey <chazmcgarvey@brokenzipper.com>
Fri, 11 Jan 2013 22:25:26 +0000 (15:25 -0700)
src/main/scala/SbtTapReporting.scala

index e828c2d6b977a360c0f53c6ff52c09612d3c5f5a..097157a520359f862faee08c7ba748c7597908b4 100644 (file)
@@ -28,7 +28,17 @@ class SbtTapListener extends TestsListener {
     )
   }
 
-  def startGroup(name: String) {}
+  def startGroup(name: String) {
+    writeTapFields("#", "start", name)
+  }
+
+  def endGroup(name: String, result: TestResult.Value) {
+    writeTapFields("#", "end", name, "with result", result.toString.toLowerCase)
+  }
+
+  def endGroup(name: String, t: Throwable) {
+    writeTapFields("#", "end", name)
+  }
 
   def testEvent(event: TestEvent) {
     event.detail.foreach { e: TEvent =>
@@ -63,7 +73,4 @@ class SbtTapListener extends TestsListener {
     t.printStackTrace(printWriter)
     sw.toString
   }
-  def endGroup(name: String, t: Throwable) { }
-
-  def endGroup(name: String, result: TestResult.Value) { }
 }
This page took 0.026539 seconds and 4 git commands to generate.