Skip to content

Add tests for parsing parallel XCTest run output #1418

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

plemarquand
Copy link
Contributor

When performing a parallel XCTest run we first parse the terminal output, then parse the xUnit XML output and merge the two data sets together to create the run results. This merging was not being tested at the unit test level, only at the integration test level, which lead to a subtle and occasional bug, #1334 (fixed in #1343).

As a followup, update the existing XCTestOutputParser tests to test both regular and parallel test run output. xUnit XML is synthesized from the expected results and fed in to the TestXUnitParser to modify the test's TestRunState just as it is in the extension.

When performing a parallel XCTest run we first parse the terminal
output, then parse the xUnit XML output and merge the two data sets
together to create the run results. This merging was not being tested at
the unit test level, only at the integration test level, which lead to
a subtle and occasional bug, swiftlang#1334 (fixed in swiftlang#1343).

As a followup, update the existing XCTestOutputParser tests to test both
regular and parallel test run output. xUnit XML is synthesized from the
expected results and fed in to the `TestXUnitParser` to modify the
test's `TestRunState` just as it is in the extension.
@plemarquand plemarquand merged commit b9713fd into swiftlang:main Mar 4, 2025
13 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants