You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+34-3Lines changed: 34 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3781,7 +3781,7 @@ _You can enable the following settings in Xcode by running [this script](resourc
3781
3781
3782
3782
</details>
3783
3783
3784
-
*<a id='void-type'></a>(<a href='#void-type'>link</a>) **Avoid using `()` as a type**. Prefer `Void`.
3784
+
*<a id='void-type'></a>(<a href='#void-type'>link</a>) **Avoid using `()` as a type**. Prefer `Void`. [](https://github.com/nicklockwood/SwiftFormat/blob/main/Rules.md#void)
3785
3785
3786
3786
<details>
3787
3787
@@ -3794,7 +3794,7 @@ _You can enable the following settings in Xcode by running [this script](resourc
3794
3794
```
3795
3795
</details>
3796
3796
3797
-
*<a id='void-instance'></a>(<a href='#void-instance'>link</a>) **Avoid using `Void()` as an instance of `Void`**. Prefer `()`.
3797
+
*<a id='void-instance'></a>(<a href='#void-instance'>link</a>) **Avoid using `Void()` as an instance of `Void`**. Prefer `()`. [](https://github.com/nicklockwood/SwiftFormat/blob/main/Rules.md#void)
3798
3798
3799
3799
<details>
3800
3800
@@ -3809,7 +3809,7 @@ _You can enable the following settings in Xcode by running [this script](resourc
3809
3809
```
3810
3810
</details>
3811
3811
3812
-
*<a id='count-where'></a>(<a href='#count-where'>link</a>) **Prefer using `count(where: { … })` over `filter { … }.count`**.
3812
+
*<a id='count-where'></a>(<a href='#count-where'>link</a>) **Prefer using `count(where: { … })` over `filter { … }.count`**. [](https://github.com/nicklockwood/SwiftFormat/blob/main/Rules.md#preferCountWhere)
3813
3813
3814
3814
<details>
3815
3815
@@ -3824,6 +3824,37 @@ _You can enable the following settings in Xcode by running [this script](resourc
3824
3824
```
3825
3825
</details>
3826
3826
3827
+
*<a id='swift-testing-test-case-names'></a>(<a href='#swift-testing-test-case-names'>link</a>) **In Swift Testing, don't prefix test case methods with "`test`".** [](https://github.com/nicklockwood/SwiftFormat/blob/main/Rules.md#swiftTestingTestCaseNames)
3828
+
3829
+
<details>
3830
+
3831
+
### Why?
3832
+
3833
+
Prefixing test case methods with "`test`" was necessary with XCTest, but is not necessary in Swift Testing. [Idiomatic usage](https://developer.apple.com/documentation/testing/migratingfromxctest#Convert-test-methods) of Swift Testing excludes the "`test`" prefix.
0 commit comments