@@ -62,7 +62,7 @@ class MockRealtime: RCNConfigRealtime, @unchecked Sendable {
62
62
}
63
63
}
64
64
65
- // MARK: - AsyncStreamTests
65
+ // MARK: - AsyncSequenceTests
66
66
67
67
@available ( iOS 13 , tvOS 13 , macOS 10 . 15 , macCatalyst 13 , watchOS 7 , * )
68
68
class AsyncSequenceTests : XCTestCase {
@@ -99,8 +99,8 @@ class AsyncSequenceTests: XCTestCase {
99
99
try super. tearDownWithError ( )
100
100
}
101
101
102
- func testStreamYieldsUpdate_whenUpdateIsSent ( ) async throws {
103
- let expectation = self . expectation ( description: " Stream should yield an update." )
102
+ func testSequenceYieldsUpdate_whenUpdateIsSent ( ) async throws {
103
+ let expectation = self . expectation ( description: " Sequence should yield an update." )
104
104
let keysToUpdate = [ " foo " , " bar " ]
105
105
106
106
let listenerAttachedExpectation = self . expectation ( description: " Listener should be attached. " )
@@ -123,8 +123,8 @@ class AsyncSequenceTests: XCTestCase {
123
123
listeningTask. cancel ( )
124
124
}
125
125
126
- func testStreamFinishes_whenErrorIsSent ( ) async throws {
127
- let expectation = self . expectation ( description: " Stream should throw an error." )
126
+ func testSequenceFinishes_whenErrorIsSent ( ) async throws {
127
+ let expectation = self . expectation ( description: " Sequence should throw an error." )
128
128
let testError = TestError ( )
129
129
130
130
let listenerAttachedExpectation = self . expectation ( description: " Listener should be attached. " )
@@ -150,7 +150,7 @@ class AsyncSequenceTests: XCTestCase {
150
150
listeningTask. cancel ( )
151
151
}
152
152
153
- func testStreamCancellation_callsRemoveOnListener ( ) async throws {
153
+ func testSequenceCancellation_callsRemoveOnListener ( ) async throws {
154
154
let listenerAttachedExpectation = expectation ( description: " Listener should be attached. " )
155
155
mockRealtime. listenerAttachedExpectation = listenerAttachedExpectation
156
156
@@ -176,8 +176,8 @@ class AsyncSequenceTests: XCTestCase {
176
176
XCTAssertTrue ( mockRealtime. mockRegistration. wasRemoveCalled)
177
177
}
178
178
179
- func testStreamFinishesGracefully_whenListenerSendsNil ( ) async throws {
180
- let expectation = self . expectation ( description: " Stream should finish without error." )
179
+ func testSequenceFinishesGracefully_whenListenerSendsNil ( ) async throws {
180
+ let expectation = self . expectation ( description: " Sequence should finish without error." )
181
181
182
182
let listenerAttachedExpectation = self . expectation ( description: " Listener should be attached. " )
183
183
mockRealtime. listenerAttachedExpectation = listenerAttachedExpectation
@@ -203,8 +203,8 @@ class AsyncSequenceTests: XCTestCase {
203
203
listeningTask. cancel ( )
204
204
}
205
205
206
- func testStreamYieldsMultipleUpdates_whenMultipleUpdatesAreSent ( ) async throws {
207
- let expectation = self . expectation ( description: " Stream should receive two updates." )
206
+ func testSequenceYieldsMultipleUpdates_whenMultipleUpdatesAreSent ( ) async throws {
207
+ let expectation = self . expectation ( description: " Sequence should receive two updates." )
208
208
expectation. expectedFulfillmentCount = 2
209
209
210
210
let updatesToSend = [
0 commit comments