Skip to content

Commit b8aae3d

Browse files
committed
Suppress failure summary if verbosity == .min
1 parent 5a0a451 commit b8aae3d

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

Sources/Testing/Events/Recorder/Event.ConsoleOutputRecorder.swift

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -342,9 +342,12 @@ extension Event.ConsoleOutputRecorder {
342342
write(lines.joined())
343343

344344
// Print failure summary when run ends, unless an environment variable is
345-
// set to explicitly disable it. The summary is printed after the main
346-
// output so it appears at the very end of the console output.
347-
if case .runEnded = event.kind, Environment.flag(named: "SWT_FAILURE_SUMMARY_ENABLED") != false {
345+
// set to explicitly disable it or verbosity is set to the lowest value. The
346+
// summary is printed after the main output so it appears at the very end of
347+
// the console output.
348+
if case .runEnded = event.kind,
349+
Environment.flag(named: "SWT_FAILURE_SUMMARY_ENABLED") != false,
350+
context.configuration?.verbosity != .min {
348351
if let summary = _humanReadableOutputRecorder.generateFailureSummary(options: options) {
349352
// Add blank line before summary for visual separation
350353
write("\n\(summary)")

0 commit comments

Comments
 (0)