Skip to content

Commit cdc4c87

Browse files
authored
Merge pull request swiftlang#22598 from moiseev/intents-macos
Match availability of INIntentError and INIntentErrorDomain in a test
2 parents 3f39d7e + 332476d commit cdc4c87

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

test/stdlib/Intents.swift

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,14 @@ import StdlibUnittest
1111

1212
let IntentsTestSuite = TestSuite("Intents")
1313

14+
#if swift(>=4.2)
15+
let swiftVersion = "4.2"
16+
#else
1417
let swiftVersion = "4"
18+
#endif
1519

16-
if #available(OSX 10.12, iOS 10.0, watchOS 3.2, *) {
20+
#if !os(macOS)
21+
if #available(iOS 10.0, watchOS 3.2, *) {
1722

1823
IntentsTestSuite.test("ErrorDomain/\(swiftVersion)") {
1924
expectEqual("IntentsErrorDomain", INIntentErrorDomain)
@@ -23,6 +28,7 @@ if #available(OSX 10.12, iOS 10.0, watchOS 3.2, *) {
2328
expectEqual("IntentsErrorDomain", INIntentError.errorDomain)
2429
}
2530
}
31+
#endif
2632

2733
#if os(iOS)
2834
if #available(iOS 11.0, *) {

0 commit comments

Comments
 (0)