@@ -37,7 +37,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
37
37
try Player ( id: 1 , name: " Arthur " , score: 1000 ) . insert ( db)
38
38
} )
39
39
let recorder = publisher. record ( )
40
- try wait ( for: recorder. single, timeout: 1 )
40
+ try wait ( for: recorder. single, timeout: 5 )
41
41
try XCTAssertEqual ( writer. read ( Player . fetchCount) , 1 )
42
42
}
43
43
@@ -65,7 +65,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
65
65
return try Player . fetchCount ( db)
66
66
} )
67
67
let recorder = publisher. record ( )
68
- let count = try wait ( for: recorder. single, timeout: 1 )
68
+ let count = try wait ( for: recorder. single, timeout: 5 )
69
69
XCTAssertEqual ( count, 1 )
70
70
}
71
71
@@ -87,7 +87,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
87
87
try db. execute ( sql: " THIS IS NOT SQL " )
88
88
} )
89
89
let recorder = publisher. record ( )
90
- let recording = try wait ( for: recorder. recording, timeout: 1 )
90
+ let recording = try wait ( for: recorder. recording, timeout: 5 )
91
91
XCTAssertTrue ( recording. output. isEmpty)
92
92
assertFailure ( recording. completion) { ( error: DatabaseError ) in
93
93
XCTAssertEqual ( error. resultCode, . SQLITE_ERROR)
@@ -117,7 +117,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
117
117
try db. execute ( sql: " THIS IS NOT SQL " )
118
118
} )
119
119
let recorder = publisher. record ( )
120
- let recording = try wait ( for: recorder. recording, timeout: 1 )
120
+ let recording = try wait ( for: recorder. recording, timeout: 5 )
121
121
XCTAssertTrue ( recording. output. isEmpty)
122
122
assertFailure ( recording. completion) { ( error: DatabaseError ) in
123
123
XCTAssertEqual ( error. resultCode, . SQLITE_ERROR)
@@ -160,7 +160,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
160
160
} )
161
161
162
162
semaphore. signal ( )
163
- waitForExpectations ( timeout: 1 , handler: nil )
163
+ waitForExpectations ( timeout: 5 , handler: nil )
164
164
cancellable. cancel ( )
165
165
}
166
166
@@ -199,7 +199,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
199
199
expectation. fulfill ( )
200
200
} )
201
201
202
- waitForExpectations ( timeout: 1 , handler: nil )
202
+ waitForExpectations ( timeout: 5 , handler: nil )
203
203
cancellable. cancel ( )
204
204
}
205
205
@@ -239,7 +239,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
239
239
expectation. fulfill ( )
240
240
} )
241
241
242
- waitForExpectations ( timeout: 1 , handler: nil )
242
+ waitForExpectations ( timeout: 5 , handler: nil )
243
243
cancellable. cancel ( )
244
244
}
245
245
@@ -269,7 +269,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
269
269
updates: { db in try Player ( id: 1 , name: " Arthur " , score: 1000 ) . insert ( db) } ,
270
270
thenRead: { db, _ in try Player . fetchCount ( db) } )
271
271
let recorder = publisher. record ( )
272
- let count = try wait ( for: recorder. single, timeout: 1 )
272
+ let count = try wait ( for: recorder. single, timeout: 5 )
273
273
XCTAssertEqual ( count, 1 )
274
274
}
275
275
@@ -292,7 +292,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
292
292
updates: { _ in } ,
293
293
thenRead: { db, _ in try Player . createTable ( db) } )
294
294
let recorder = publisher. record ( )
295
- let recording = try wait ( for: recorder. recording, timeout: 1 )
295
+ let recording = try wait ( for: recorder. recording, timeout: 5 )
296
296
XCTAssertTrue ( recording. output. isEmpty)
297
297
assertFailure ( recording. completion) { ( error: DatabaseError ) in
298
298
XCTAssertEqual ( error. resultCode, . SQLITE_READONLY)
@@ -317,7 +317,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
317
317
updates: { db in try db. execute ( sql: " THIS IS NOT SQL " ) } ,
318
318
thenRead: { _, _ in XCTFail ( " Should not read " ) } )
319
319
let recorder = publisher. record ( )
320
- let recording = try wait ( for: recorder. recording, timeout: 1 )
320
+ let recording = try wait ( for: recorder. recording, timeout: 5 )
321
321
XCTAssertTrue ( recording. output. isEmpty)
322
322
assertFailure ( recording. completion) { ( error: DatabaseError ) in
323
323
XCTAssertEqual ( error. resultCode, . SQLITE_ERROR)
@@ -349,7 +349,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
349
349
} ,
350
350
thenRead: { _, _ in XCTFail ( " Should not read " ) } )
351
351
let recorder = publisher. record ( )
352
- let recording = try wait ( for: recorder. recording, timeout: 1 )
352
+ let recording = try wait ( for: recorder. recording, timeout: 5 )
353
353
XCTAssertTrue ( recording. output. isEmpty)
354
354
assertFailure ( recording. completion) { ( error: DatabaseError ) in
355
355
XCTAssertEqual ( error. resultCode, . SQLITE_ERROR)
@@ -379,7 +379,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
379
379
updates: { _ in } ,
380
380
thenRead: { db, _ in try Row . fetchAll ( db, sql: " THIS IS NOT SQL " ) } )
381
381
let recorder = publisher. record ( )
382
- let recording = try wait ( for: recorder. recording, timeout: 1 )
382
+ let recording = try wait ( for: recorder. recording, timeout: 5 )
383
383
XCTAssertTrue ( recording. output. isEmpty)
384
384
assertFailure ( recording. completion) { ( error: DatabaseError ) in
385
385
XCTAssertEqual ( error. resultCode, . SQLITE_ERROR)
@@ -421,7 +421,7 @@ class DatabaseWriterWritePublisherTests : XCTestCase {
421
421
. prefix ( 1 )
422
422
let recorder = publisher. record ( )
423
423
scoreSubject. send ( 0 )
424
- let count = try wait ( for: recorder. single, timeout: 1 )
424
+ let count = try wait ( for: recorder. single, timeout: 5 )
425
425
XCTAssertEqual ( count, 1 )
426
426
}
427
427
0 commit comments