@@ -84,7 +84,7 @@ final class TestCombineLatest2: XCTestCase {
8484 value = await validator. validate ( )
8585 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 2 , " a " ) , ( 2 , " b " ) , ( 3 , " b " ) , ( 3 , " c " ) ] )
8686
87- wait ( for : [ finished] , timeout: 1.0 )
87+ await fulfillment ( of : [ finished] , timeout: 1.0 )
8888 value = validator. current
8989 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 2 , " a " ) , ( 2 , " b " ) , ( 3 , " b " ) , ( 3 , " c " ) ] )
9090 }
@@ -126,7 +126,7 @@ final class TestCombineLatest2: XCTestCase {
126126 value = await validator. validate ( )
127127 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 1 , " b " ) , ( 2 , " b " ) , ( 2 , " c " ) , ( 3 , " c " ) ] )
128128
129- wait ( for : [ finished] , timeout: 1.0 )
129+ await fulfillment ( of : [ finished] , timeout: 1.0 )
130130 value = validator. current
131131 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 1 , " b " ) , ( 2 , " b " ) , ( 2 , " c " ) , ( 3 , " c " ) ] )
132132 }
@@ -168,7 +168,7 @@ final class TestCombineLatest2: XCTestCase {
168168 value = await validator. validate ( )
169169 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 2 , " a " ) , ( 3 , " a " ) , ( 3 , " b " ) , ( 3 , " c " ) ] )
170170
171- wait ( for : [ finished] , timeout: 1.0 )
171+ await fulfillment ( of : [ finished] , timeout: 1.0 )
172172 value = validator. current
173173 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 2 , " a " ) , ( 3 , " a " ) , ( 3 , " b " ) , ( 3 , " c " ) ] )
174174 }
@@ -210,7 +210,7 @@ final class TestCombineLatest2: XCTestCase {
210210 value = await validator. validate ( )
211211 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 1 , " b " ) , ( 1 , " c " ) , ( 2 , " c " ) , ( 3 , " c " ) ] )
212212
213- wait ( for : [ finished] , timeout: 1.0 )
213+ await fulfillment ( of : [ finished] , timeout: 1.0 )
214214 value = validator. current
215215 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 1 , " b " ) , ( 1 , " c " ) , ( 2 , " c " ) , ( 3 , " c " ) ] )
216216 }
@@ -250,7 +250,7 @@ final class TestCombineLatest2: XCTestCase {
250250
251251 XCTAssertEqual ( validator. failure as? Failure , Failure ( ) )
252252
253- wait ( for : [ finished] , timeout: 1.0 )
253+ await fulfillment ( of : [ finished] , timeout: 1.0 )
254254 value = validator. current
255255 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 1 , " b " ) ] )
256256 }
@@ -290,7 +290,7 @@ final class TestCombineLatest2: XCTestCase {
290290
291291 XCTAssertEqual ( validator. failure as? Failure , Failure ( ) )
292292
293- wait ( for : [ finished] , timeout: 1.0 )
293+ await fulfillment ( of : [ finished] , timeout: 1.0 )
294294 value = validator. current
295295 XCTAssertEqual ( value, [ ( 1 , " a " ) , ( 2 , " a " ) ] )
296296 }
@@ -312,11 +312,11 @@ final class TestCombineLatest2: XCTestCase {
312312 finished. fulfill ( )
313313 }
314314 // ensure the other task actually starts
315- wait ( for : [ iterated] , timeout: 1.0 )
315+ await fulfillment ( of : [ iterated] , timeout: 1.0 )
316316 // cancellation should ensure the loop finishes
317317 // without regards to the remaining underlying sequence
318318 task. cancel ( )
319- wait ( for : [ finished] , timeout: 1.0 )
319+ await fulfillment ( of : [ finished] , timeout: 1.0 )
320320 }
321321
322322 func test_combineLatest_when_cancelled( ) async {
@@ -389,7 +389,7 @@ final class TestCombineLatest3: XCTestCase {
389389 value = await validator. validate ( )
390390 XCTAssertEqual ( value, [ ( 1 , " a " , 4 ) , ( 2 , " a " , 4 ) , ( 2 , " b " , 4 ) , ( 2 , " b " , 5 ) , ( 3 , " b " , 5 ) , ( 3 , " c " , 5 ) , ( 3 , " c " , 6 ) ] )
391391
392- wait ( for : [ finished] , timeout: 1.0 )
392+ await fulfillment ( of : [ finished] , timeout: 1.0 )
393393 value = validator. current
394394 XCTAssertEqual ( value, [ ( 1 , " a " , 4 ) , ( 2 , " a " , 4 ) , ( 2 , " b " , 4 ) , ( 2 , " b " , 5 ) , ( 3 , " b " , 5 ) , ( 3 , " c " , 5 ) , ( 3 , " c " , 6 ) ] )
395395 }
0 commit comments