diff options
author | Martin Odersky <odersky@gmail.com> | 2016-11-23 18:54:21 +0100 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2016-11-23 18:54:21 +0100 |
commit | 9c1cb55478c7ce5708a36b67b65d857d8f907bd3 (patch) | |
tree | a06b4f8db5e7b1121354f5d0de0356f2193026f8 | |
parent | ede2d531f0df401e7dd73e6c3d9c9fe5f4702d4b (diff) | |
download | dotty-9c1cb55478c7ce5708a36b67b65d857d8f907bd3.tar.gz dotty-9c1cb55478c7ce5708a36b67b65d857d8f907bd3.tar.bz2 dotty-9c1cb55478c7ce5708a36b67b65d857d8f907bd3.zip |
Honor -verbose in tests
-verbose output was suppressed like all other non-error
output in the tests. Now we don't filter output if -verbose is set.
-rw-r--r-- | compiler/test/dotty/tools/dotc/CompilerTest.scala | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/test/dotty/tools/dotc/CompilerTest.scala b/compiler/test/dotty/tools/dotc/CompilerTest.scala index fbec9003a..5192ec84c 100644 --- a/compiler/test/dotty/tools/dotc/CompilerTest.scala +++ b/compiler/test/dotty/tools/dotc/CompilerTest.scala @@ -264,13 +264,14 @@ abstract class CompilerTest { private def compileArgs(args: Array[String], expectedErrorsPerFile: List[ErrorsInFile]) (implicit defaultOptions: List[String]): Unit = { val allArgs = args ++ defaultOptions + val verbose = allArgs.contains("-verbose") //println(s"""all args: ${allArgs.mkString("\n")}""") val processor = if (allArgs.exists(_.startsWith("#"))) Bench else Main val storeReporter = new Reporter with UniqueMessagePositions with HideNonSensicalMessages { private val consoleReporter = new ConsoleReporter() private val innerStoreReporter = new StoreReporter(consoleReporter) def doReport(m: MessageContainer)(implicit ctx: Context): Unit = { - if (m.level == ERROR) { + if (m.level == ERROR || verbose) { innerStoreReporter.flush() consoleReporter.doReport(m) } |