Skip to content

Commit d494fab

Browse files
authored
Fix filePath propagation across withKnownIssue overrides (#353)
There are several overrides of `withKnownIssue`, each of which capture source location information via default argument values. When delegating to another override, we propagate the outermost source location values. Except in a couple places, where we mistakenly overlooked doing so. This fixes that oversight.
1 parent 12b0fd9 commit d494fab

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Sources/Testing/Issues/KnownIssue.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ public func withKnownIssue(
121121
column: Int = #column,
122122
_ body: () throws -> Void
123123
) {
124-
try? withKnownIssue(comment, isIntermittent: isIntermittent, fileID: fileID, line: line, column: column, body, matching: { _ in true })
124+
try? withKnownIssue(comment, isIntermittent: isIntermittent, fileID: fileID, filePath: filePath, line: line, column: column, body, matching: { _ in true })
125125
}
126126

127127
/// Invoke a function that has a known issue that is expected to occur during
@@ -236,7 +236,7 @@ public func withKnownIssue(
236236
column: Int = #column,
237237
_ body: () async throws -> Void
238238
) async {
239-
try? await withKnownIssue(comment, isIntermittent: isIntermittent, fileID: fileID, line: line, column: column, body, matching: { _ in true })
239+
try? await withKnownIssue(comment, isIntermittent: isIntermittent, fileID: fileID, filePath: filePath, line: line, column: column, body, matching: { _ in true })
240240
}
241241

242242
/// Invoke a function that has a known issue that is expected to occur during

0 commit comments

Comments
 (0)