Skip to content

Commit 738a018

Browse files
committed
fix a few test assertions
1 parent fbc82b4 commit 738a018

4 files changed

+3
-10
lines changed

test/Distributed/distributed_actor_conditionally_implicitly_codable.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ func test_NotAtAll_NoImplicit(_ actor: SerReqNotCodable) {
3131

3232
// ==== ------------------------------------------------------------------------
3333

34-
distributed actor NotAtAll_NothingCodable { // expected-error{{type 'NotAtAll_NothingCodable' does not conform to protocol 'Decodable'}}
34+
distributed actor NotAtAll_NothingCodable {
3535
typealias ActorSystem = FakeIdIsNotCodableActorSystem
3636
}
3737
func test_NotAtAll_NoImplicit(_ actor: NotAtAll_NothingCodable) {
38-
let _: any Codable = actor
38+
let _: any Codable = actor // expected-error{{value of type 'NotAtAll_NothingCodable' does not conform to specified type 'Decodable'}}
3939

4040
// no implicit conformance
4141
let _: any CustomSerializationProtocol = actor // expected-error{{value of type 'NotAtAll_NothingCodable' does not conform to specified type 'CustomSerializationProtocol'}}

test/Distributed/distributed_actor_system_missing.swift

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,7 @@ distributed actor DA {
1010
// expected-error@-1{{distributed actor 'DA' does not declare ActorSystem it can be used with}}
1111
// expected-error@-2 {{type 'DA' does not conform to protocol 'DistributedActor'}}
1212

13-
// Since synthesis would have failed due to the missing ActorSystem:
14-
// expected-error@-5{{type 'DA' does not conform to protocol 'Decodable'}}
15-
16-
// expected-note@-7{{you can provide a module-wide default actor system by declaring:}}
13+
// expected-note@-4{{you can provide a module-wide default actor system by declaring:}}
1714

1815
// Note to add the typealias is diagnosed on the protocol:
1916
// _Distributed.DistributedActor:3:20: note: diagnostic produced elsewhere: protocol requires nested type 'ActorSystem'; do you want to add it?
@@ -26,8 +23,6 @@ distributed actor DA {
2623
distributed actor Server { // expected-error 2 {{distributed actor 'Server' does not declare ActorSystem it can be used with}}
2724
// expected-error@-1 {{type 'Server' does not conform to protocol 'DistributedActor'}}
2825
// expected-note@-2{{you can provide a module-wide default actor system by declaring:}}
29-
// expected-error@-3{{type 'Server' does not conform to protocol 'Encodable'}}
30-
// expected-error@-4{{type 'Server' does not conform to protocol 'Decodable'}}
3126
typealias ActorSystem = DoesNotExistDataSystem
3227
// expected-error@-1{{cannot find type 'DoesNotExistDataSystem' in scope}}
3328
typealias SerializationRequirement = any Codable

test/Distributed/distributed_actor_system_missing_type_no_crash.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ distributed actor Fish {
1212
// expected-error@-2{{distributed actor 'Fish' does not declare ActorSystem it can be used with}}
1313
// expected-error@-3{{type 'Fish' does not conform to protocol 'DistributedActor'}}
1414
// expected-note@-4{{you can provide a module-wide default actor system by declaring:\ntypealias DefaultDistributedActorSystem = <#ConcreteActorSystem#>}}
15-
// expected-error@-5{{type 'Fish' does not conform to protocol 'Decodable'}}
1615

1716
distributed func tell(_ text: String, by: Fish) {
1817
// What would the fish say, if it could talk?

test/Distributed/distributed_protocols_distributed_func_serialization_requirements.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ distributed actor ProtocolWithChecksSeqReqDA_MissingSystem: ProtocolWithChecksSe
5353
// expected-error@-4{{distributed actor 'ProtocolWithChecksSeqReqDA_MissingSystem' does not declare ActorSystem it can be used with}}
5454
//
5555
// expected-error@-6{{type 'ProtocolWithChecksSeqReqDA_MissingSystem' does not conform to protocol 'DistributedActor'}}
56-
// expected-error@-7{{type 'ProtocolWithChecksSeqReqDA_MissingSystem' does not conform to protocol 'Decodable'}}
5756

5857
// Entire conformance is doomed, so we didn't proceed to checking the functions; that's fine
5958
distributed func testAT() async throws -> NotCodable { .init() }

0 commit comments

Comments
 (0)