Skip to content

Commit ab126c8

Browse files
authored
Merge pull request #66852 from ktoso/wip-try-to-make-test
2 parents 36914d9 + a1b7aa5 commit ab126c8

File tree

2 files changed

+32
-0
lines changed

2 files changed

+32
-0
lines changed

test/Distributed/distributed_actor_basic.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,4 @@ distributed actor Second {
2323
try! await first.one(second: self)
2424
}
2525
}
26+
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
// RUN: %empty-directory(%t)
2+
3+
// RUN: %target-swift-emit-module-interface(%t/TestResilient.swiftinterface) %s -module-name TestResilient
4+
// RUN: %target-swift-typecheck-module-from-interface(%t/TestResilient.swiftinterface) -module-name TestResilient
5+
// RUN: %FileCheck %s < %t/TestResilient.swiftinterface
6+
7+
// RUN: %target-swift-frontend -compile-module-from-interface -swift-version 5 %t/TestResilient.swiftinterface -o %t/TestResilient.swiftmodule
8+
// RUN: %target-swift-frontend -emit-module -o /dev/null -merge-modules -swift-version 5 -emit-module-interface-path - %t/TestResilient.swiftmodule -module-name TestResilient | %FileCheck %s
9+
10+
import Distributed
11+
12+
@available(macOS 13.0, *)
13+
typealias DefaultDistributedActorSystem = LocalTestingDistributedActorSystem
14+
15+
@available(macOS 13.0, *)
16+
distributed actor CheckMe {
17+
distributed func test() {
18+
// ...
19+
}
20+
21+
}
22+
23+
// CHECK: public struct HasDistributedActors {
24+
@available(macOS 13.0, *)
25+
public struct HasDistributedActors {
26+
let check: CheckMe
27+
28+
func test() async throws {
29+
try await check.test()
30+
}
31+
}

0 commit comments

Comments
 (0)