-
Notifications
You must be signed in to change notification settings - Fork 128
Merge 'main' branch to 'release/6.2' #1127
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
stmontgomery
merged 8 commits into
swiftlang:release/6.2
from
stmontgomery:main-6.2-merge
May 24, 2025
Merged
Merge 'main' branch to 'release/6.2' #1127
stmontgomery
merged 8 commits into
swiftlang:release/6.2
from
stmontgomery:main-6.2-merge
May 24, 2025
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
) The SwiftPM entry point is unstable and the new ABIv0 entry point has already been added to the library. ### Motivation: Using the SwiftPM entry point when building tests from a CMake project as recommended in the documentation is outdated and unwise. ### Modifications: Replace the example with one using the new ABIv0 entry point. ### Result: CMake projects should stop relying on the SwiftPM entry point. ### Checklist: - [x] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md). - [x] If public symbols are renamed or modified, DocC references should be updated.
CMake is a strange animal and some things are case sensitive, while others aren't. It seems that `if(<condition>)` logical operator `OR` is case sensitive, and `or` was not cutting it. At least for CMake 3.26.4. If some CMake version allows `or`, it should also allow `OR`, so this change should not be a problem for those versions. Most of the time these pieces are not actually hit, because the build system sets `SwiftTesting_MACROS` to `NO`, so this is skipped, which might explain why it has not been a problem.
…ang#1116) This enhances the console output message shown when a test run finishes by including the total number of suites which ran or skipped, after the total number of test functions. Example: ``` ✔ Test run with 456 tests in 62 suites passed after 3.389 seconds. ``` The data was already being collected to support this, in a property named `suiteCount`, but it was not being used anywhere. So this PR adopts that property to augment the current "test run ended" message. ### Checklist: - [x] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md). - [x] If public symbols are renamed or modified, DocC references should be updated.
A few refinements to `IssueHandlingTrait`, which is still SPI. ### Motivation: Polish this SPI in anticipation of posting a pitch to promote it to public API soon. ### Modifications: - Expose a `handleIssue(_:)` instance method to allow more easily composing multiple issue handling traits and calling their underlying handler closure. This is conceptually similar to what was done for [ST-0010: Public API to evaluate ConditionTrait](https://github.com/swiftlang/swift-evolution/blob/main/proposals/testing/0010-evaluate-condition.md). - Refine the names of private decls. - Add `- Returns:` in DocC for places it's missing. ### Checklist: - [x] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md). - [x] If public symbols are renamed or modified, DocC references should be updated.
…1124) This removes the `triage-needed` label from the GitHub New Issue templates in this repository which have it. I added this while revamping these templates in swiftlang#962, but more recently we added a `triaged` label which is works the opposite way—it's applied after an issue has been triaged—so we don't need the older label anymore. ### Checklist: - [x] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md). - [x] If public symbols are renamed or modified, DocC references should be updated.
…th status and issue counts (swiftlang#1125) This outputs a console message when each test case of a parameterized test function ends, including its pass/fail status and a count of the number of issues which were recorded, when running in verbose mode (`swift test --verbose`). Here's an example: ``` ◇ Test contrivedExample(x:) started. ◇ Test case passing 1 argument x → 1 (Swift.Int) to contrivedExample(x:) started. ◇ Test case passing 1 argument x → 2 (Swift.Int) to contrivedExample(x:) started. ✔ Test case passing 1 argument x → 1 (Swift.Int) to contrivedExample(x:) passed after 0.001 seconds. ✘ Test contrivedExample(x:) recorded an issue with 1 argument x → 2 at EventRecorderTests.swift:759:3: Expectation failed: (x → 2) == 1 ↳ x: Swift.Int → 2 ↳ 1: Swift.Int → 1 ✘ Test case passing 1 argument x → 2 (Swift.Int) to contrivedExample(x:) failed after 0.001 seconds with 1 issue. ✘ Test contrivedExample(x:) with 2 test cases failed after 0.001 seconds with 1 issue. ``` > Note: This leverages swiftlang#1000 which added more robust identification of test cases. Fixes swiftlang#1021 Fixes rdar://146863942 ### Checklist: - [x] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md). - [x] If public symbols are renamed or modified, DocC references should be updated.
… reveals (swiftlang#1126) This enables the `InferIsolatedConformances` upcoming Swift feature from [SE-0470: Global-actor isolated conformances](https://github.com/swiftlang/swift-evolution/blob/main/proposals/0470-isolated-conformances.md) and fixes a couple of pre-existing issues it revealed. I confirmed these code changes still build successfully using a Swift 6.1 toolchain. ### Checklist: - [x] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md). - [x] If public symbols are renamed or modified, DocC references should be updated.
Contributor
Author
|
@swift-ci please test |
briancroom
approved these changes
May 24, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This merges the
mainbranch into therelease/6.2branch.Once this PR has been merged, I will adjust the milestones on the PRs included in this merge to be 6.2 wherever appropriate.
Checklist: