-
Notifications
You must be signed in to change notification settings - Fork 97
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify the logic for parsing and handling test arguments in the @test…
… macro (#834) This is a minor refactor of the logic and data structures in the `@Test` macro implementation responsible for parsing and handling test function argument expressions. ### Motivation: I discovered there was a way to simplify this logic while working on #808, and since this isn't strictly pertinent to that PR I wanted to extract it and land it separately here. ### Modifications: - Remove the need to hardcode the parameter label `arguments:` in three places. - Remove the need to iterate a Collection using raw indices. - Resolve one "TODO" comment. ### 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.
- Loading branch information
1 parent
8a78407
commit 0098422
Showing
3 changed files
with
27 additions
and
34 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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