Skip to content

Commit 831a813

Browse files
Add missing swift-testing example (#112)
1 parent caaafe5 commit 831a813

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

Tests/Library/LibraryTests.swift

+15
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,18 @@ struct LibraryTest {
2222
await #expect(color.red == 1.0)
2323
}
2424
}
25+
26+
extension LibraryTest {
27+
@Test func testCallbackOperation() async {
28+
await confirmation() { completion in
29+
// function explicitly opts out of an generated async version
30+
// so it requires a continuation here
31+
await withCheckedContinuation { continuation in
32+
JPKJetPack.jetPackConfiguration {
33+
completion()
34+
continuation.resume()
35+
}
36+
}
37+
}
38+
}
39+
}

0 commit comments

Comments
 (0)