diff --git a/.travis.yml b/.travis.yml index d9ed958..91243b7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,7 @@ language: objective-c xcode_project: Socket.IO-Client-Swift.xcodeproj # path to your xcodeproj folder xcode_scheme: SocketIO-Mac -osx_image: xcode9 +osx_image: xcode9.2 branches: only: - master diff --git a/Package.resolved b/Package.resolved index 3f29cea..88064dd 100644 --- a/Package.resolved +++ b/Package.resolved @@ -1,15 +1,6 @@ { "object": { "pins": [ - { - "package": "SSCZLib", - "repositoryURL": "https://github.com/daltoniam/zlib-spm.git", - "state": { - "branch": null, - "revision": "83ac8d719a2f3aa775dbdf116a57f56fb2c49abb", - "version": "1.1.0" - } - }, { "package": "SSCommonCrypto", "repositoryURL": "https://github.com/daltoniam/common-crypto-spm", @@ -27,6 +18,15 @@ "revision": "6cb1c474e09b0a3aa60bcdc7553b570336d6a61a", "version": "3.0.3" } + }, + { + "package": "SSCZLib", + "repositoryURL": "https://github.com/daltoniam/zlib-spm.git", + "state": { + "branch": null, + "revision": "83ac8d719a2f3aa775dbdf116a57f56fb2c49abb", + "version": "1.1.0" + } } ] }, diff --git a/Source/SocketIO/Manager/SocketManager.swift b/Source/SocketIO/Manager/SocketManager.swift index e4fbf7d..c499b1a 100644 --- a/Source/SocketIO/Manager/SocketManager.swift +++ b/Source/SocketIO/Manager/SocketManager.swift @@ -476,6 +476,8 @@ open class SocketManager : NSObject, SocketManagerSpec, SocketParsable, SocketDa self.handleQueue = queue case let .reconnects(reconnects): self.reconnects = reconnects + case let .reconnectAttempts(attempts): + self.reconnectAttempts = attempts case let .reconnectWait(wait): reconnectWait = abs(wait) case let .log(log): diff --git a/Tests/TestSocketIO/SocketMangerTest.swift b/Tests/TestSocketIO/SocketMangerTest.swift index 8b83cf8..22da481 100644 --- a/Tests/TestSocketIO/SocketMangerTest.swift +++ b/Tests/TestSocketIO/SocketMangerTest.swift @@ -79,13 +79,15 @@ class SocketMangerTest : XCTestCase { .handleQueue(queue), .forceNew(true), .reconnects(false), - .reconnectWait(5) + .reconnectWait(5), + .reconnectAttempts(5) ]) XCTAssertEqual(manager.handleQueue, queue) XCTAssertTrue(manager.forceNew) XCTAssertFalse(manager.reconnects) XCTAssertEqual(manager.reconnectWait, 5) + XCTAssertEqual(manager.reconnectAttempts, 5) } func testManagerRemovesSocket() {