Skip to content

Commit 7f0f8da

Browse files
committed
Fix a test marked @MainActor but not async.
SPM and swift-corelibs-xctest do not support main-actor-isolated tests unless they are marked `async` because the compilation stage that finds tests is not actor-aware. This test is preventing us from merging swiftlang/swift-package-manager#7967.
1 parent c542180 commit 7f0f8da

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Tests/Foundation/TestURLSession.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ final class TestURLSession: LoopbackServerTest, @unchecked Sendable {
410410
}
411411
}
412412

413-
func test_taskCopy() {
413+
func test_taskCopy() async {
414414
let url = URL(string: "http://127.0.0.1:\(TestURLSession.serverPort)/Nepal")!
415415
let session = URLSession(configuration: URLSessionConfiguration.default,
416416
delegate: nil,

0 commit comments

Comments
 (0)