-
Notifications
You must be signed in to change notification settings - Fork 84
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
'expected' and 'actual' are matched in the wrong order from the message regex matches. The colouring of red and green seem to be displayed correctly.
To Reproduce
Steps to reproduce the behavior:
- Run a Test from within VSCode window
- Click on a red flagged issue for any XCTAssertEqual() to unfold details
- Notice the mislabelling of "Expected" and "Actual"
Expected behavior
To be displayed correctly
Environment
- OS: macOS 15.3.2
- Swift version: 6.0.3 (swiftlang-6.0.3.1.10 clang-1600.0.30.1)
- Visual Studio Code version: 1.98.1
- vscode-swift version: 2.0.2 (last updated 2025-03-16, 18:15:03)
Additional context
Potential location of bug:
File: /src/TestExplorer/TestParsers/XCTestOutputParser.ts
private extractDiff(message: string): TestIssueDiff | undefined {
const regex = /\((.*)\) is not .* to \((.*)\)/ms;
const match = message.match(regex);
if (match && match[1] !== match[2]) {
return {
expected: match[1],
actual: match[2],
};
}
return undefined;
}
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Projects
Status
Done