Skip to content

Commit 84d0048

Browse files
committed
Fixups after rebasing
1 parent ae0a5d5 commit 84d0048

1 file changed

Lines changed: 4 additions & 10 deletions

File tree

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

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -591,18 +591,12 @@ extension Event.HumanReadableOutputRecorder {
591591
// issues whose severity is error or greater.
592592
if issue.severity >= .error {
593593
// Extract detailed failure message
594-
let description: String
595-
if case let .expectationFailed(expectation) = issue.kind {
596-
// Use expandedDebugDescription only when verbose, otherwise use expandedDescription
597-
description = if verbosity > 0 {
598-
expectation.evaluatedExpression.expandedDebugDescription()
599-
} else {
600-
expectation.evaluatedExpression.expandedDescription()
601-
}
594+
let description = if case let .expectationFailed(expectation) = issue.kind {
595+
expectation.evaluatedExpression.expandedDescription(verbose: verbosity > 0)
602596
} else if let comment = issue.comments.first {
603-
description = comment.rawValue
597+
comment.rawValue
604598
} else {
605-
description = "Test failed"
599+
"Test failed"
606600
}
607601

608602
let issueInfo = Context.TestData.IssueInfo(

0 commit comments

Comments
 (0)