@@ -28,8 +28,6 @@ abstract class AbstractRunner {
2828 verbose = config.optVerbose,
2929 debug = config.optDebug || propOrFalse(" partest.debug" ),
3030 terse = config.optTerse,
31- diffOnFail = config.optShowDiff,
32- logOnFail = config.optShowLog,
3331 colorEnabled = colorEnabled
3432 )
3533
@@ -50,6 +48,8 @@ abstract class AbstractRunner {
5048 private [this ] var summarizing = false
5149 private [this ] var elapsedMillis = 0L
5250 private [this ] var expectedFailures = 0
51+ private [this ] var onlyIndividualTests = false
52+
5353
5454 import nestUI ._
5555 import nestUI .color ._
@@ -170,6 +170,7 @@ abstract class AbstractRunner {
170170 val allTests : Array [Path ] = distinctBy(miscTests ++ kindsTests)(_.toCanonical) sortBy (_.toString) toArray
171171 val grouped = (allTests groupBy kindOf).toArray sortBy (x => standardKinds indexOf x._1)
172172
173+ onlyIndividualTests = individualTests.nonEmpty && rerunTests.isEmpty && kindsTests.isEmpty && greppedTests.isEmpty
173174 totalTests = allTests.size
174175 expectedFailures = propOrNone(" partest.errors" ) match {
175176 case Some (num) => num.toInt
@@ -243,7 +244,7 @@ abstract class AbstractRunner {
243244 case t : Throwable => throw new RuntimeException (s " Error running $testFile" , t)
244245 }
245246 stopwatchDuration = Some (durationMs)
246- nestUI.reportTest(state, runner, durationMs)
247+ nestUI.reportTest(state, runner, durationMs, diffOnFail = config.optShowDiff || onlyIndividualTests , logOnFail = config.optShowLog || onlyIndividualTests )
247248 runner.cleanup()
248249 state
249250 }
0 commit comments