@@ -314,28 +314,24 @@ class ParseLiveQueryTests: XCTestCase {
314
314
XCTFail ( " Should be able to get client " )
315
315
return
316
316
}
317
- client. isSocketEstablished = true // Socket needs to be true
317
+ client. isSocketEstablished = true // Socket neets to be true
318
318
client. isConnecting = true
319
319
client. attempts = 50
320
320
client. isConnected = true
321
321
client. clientId = " yolo "
322
- let expectation1 = XCTestExpectation ( description: " Synch " )
323
- client. synchronizationQueue. sync {
324
- XCTAssertEqual ( client. isSocketEstablished, true )
325
- XCTAssertEqual ( client. isConnecting, false )
326
- XCTAssertEqual ( client. clientId, " yolo " )
327
- XCTAssertEqual ( client. attempts, 1 )
328
- expectation1. fulfill ( )
329
- }
330
- wait ( for: [ expectation1] , timeout: 20.0 )
322
+
323
+ XCTAssertEqual ( client. isSocketEstablished, true )
324
+ XCTAssertEqual ( client. isConnecting, false )
325
+ XCTAssertEqual ( client. clientId, " yolo " )
326
+ XCTAssertEqual ( client. attempts, 1 )
331
327
}
332
328
333
329
func testDisconnectedState( ) throws {
334
330
guard let client = ParseLiveQuery . getDefault ( ) else {
335
331
XCTFail ( " Should be able to get client " )
336
332
return
337
333
}
338
- client. isSocketEstablished = true // Socket needs to be true
334
+ client. isSocketEstablished = true // Socket neets to be true
339
335
client. isConnecting = true
340
336
client. isConnected = true
341
337
client. clientId = " yolo "
@@ -356,7 +352,7 @@ class ParseLiveQueryTests: XCTestCase {
356
352
XCTFail ( " Should be able to get client " )
357
353
return
358
354
}
359
- client. isSocketEstablished = true // Socket needs to be true
355
+ client. isSocketEstablished = true // Socket neets to be true
360
356
client. isConnecting = true
361
357
client. isConnected = true
362
358
client. clientId = " yolo "
@@ -388,13 +384,11 @@ class ParseLiveQueryTests: XCTestCase {
388
384
XCTAssertEqual ( client. clientId, " yolo " )
389
385
client. close ( )
390
386
391
- DispatchQueue . main. asyncAfter ( deadline: . now( ) ) {
392
- XCTAssertEqual ( client. isSocketEstablished, true )
393
- XCTAssertEqual ( client. isConnected, false )
394
- XCTAssertEqual ( client. isConnecting, false )
395
- XCTAssertNil ( client. clientId)
396
- XCTAssertEqual ( client. isDisconnectedByUser, true )
397
- }
387
+ XCTAssertEqual ( client. isSocketEstablished, true )
388
+ XCTAssertEqual ( client. isConnected, false )
389
+ XCTAssertEqual ( client. isConnecting, false )
390
+ XCTAssertNil ( client. clientId)
391
+ XCTAssertEqual ( client. isDisconnectedByUser, true )
398
392
}
399
393
400
394
func testReconnectInterval( ) throws {
0 commit comments