diff options
author | Felix Mulder <felix.mulder@gmail.com> | 2017-03-29 13:29:28 +0200 |
---|---|---|
committer | Felix Mulder <felix.mulder@gmail.com> | 2017-03-29 14:52:20 +0200 |
commit | 02ebe0f9b18b7dec024b79109ecf984d23c15cd1 (patch) | |
tree | b73e1f5d04167b9a089c1cf69b84d81f22241d86 /compiler/test/dotty/tools/dotc/ParallelTesting.scala | |
parent | b5b6f5ea98628b005b00bfa515d2e13d644d8435 (diff) | |
download | dotty-02ebe0f9b18b7dec024b79109ecf984d23c15cd1.tar.gz dotty-02ebe0f9b18b7dec024b79109ecf984d23c15cd1.tar.bz2 dotty-02ebe0f9b18b7dec024b79109ecf984d23c15cd1.zip |
Make summary report come at the end of test suite
Diffstat (limited to 'compiler/test/dotty/tools/dotc/ParallelTesting.scala')
-rw-r--r-- | compiler/test/dotty/tools/dotc/ParallelTesting.scala | 24 |
1 files changed, 6 insertions, 18 deletions
diff --git a/compiler/test/dotty/tools/dotc/ParallelTesting.scala b/compiler/test/dotty/tools/dotc/ParallelTesting.scala index 016e8770f..30679de9e 100644 --- a/compiler/test/dotty/tools/dotc/ParallelTesting.scala +++ b/compiler/test/dotty/tools/dotc/ParallelTesting.scala @@ -31,6 +31,7 @@ import dotc.util.DiffUtil trait ParallelTesting { import ParallelTesting._ + import ParallelSummaryReport._ /** If the running environment supports an interactive terminal, each `Test` * will be run with a progress bar and real time feedback @@ -197,11 +198,8 @@ trait ParallelTesting { val errorMsg = testSource.buildInstructions(reporter.errorCount, reporter.warningCount) addFailureInstruction(errorMsg) failTestSource(testSource) - reporter.echo(errorMsg) - reporter.flushToFile() } - /** Instructions on how to reproduce failed test source compilations */ private[this] val reproduceInstructions = mutable.ArrayBuffer.empty[String] protected final def addFailureInstruction(ins: String): Unit = @@ -210,7 +208,7 @@ trait ParallelTesting { /** The test sources that failed according to the implementing subclass */ private[this] val failedTestSources = mutable.ArrayBuffer.empty[String] protected final def failTestSource(testSource: TestSource) = synchronized { - failedTestSources.append(testSource.name) + failedTestSources.append(testSource.name + " failed") fail() } @@ -345,21 +343,11 @@ trait ParallelTesting { throw new TimeoutException("Compiling targets timed out") if (didFail) { - echo { - """| - | - | - |================================================================================ - |Test Report - |================================================================================ - |Failing tests:""".stripMargin - } - failedTestSources.toSet.foreach { source: String => - echo(" " + source) - } - echo("") - reproduceInstructions.iterator.foreach(echo) + reportFailed() + failedTestSources.toSet.foreach(addFailedTest) + reproduceInstructions.iterator.foreach(addReproduceInstruction) } + else reportPassed() } else echo { testFilter |