From 2b48fba8028c04b4cf6b9b5176b777c4b1c2bd33 Mon Sep 17 00:00:00 2001 From: metalurgical <97008724+metalurgical@users.noreply.github.com> Date: Tue, 17 Sep 2024 06:03:13 +0200 Subject: [PATCH] update --- .github/workflows/main.yml | 2 +- Sources/SingleFactorAuth/SingleFactorAuth.swift | 4 ++-- Tests/SingleFactorAuthTests/AquaTest.swift | 2 +- Tests/SingleFactorAuthTests/CyanTest.swift | 2 +- Tests/SingleFactorAuthTests/SingleFactorAuthTests.swift | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index e6901d4..6216984 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -28,4 +28,4 @@ jobs: with: xcode-version: latest-stable - name: package - run: xcodebuild test -scheme SingleFactorAuth -destination "platform=iOS Simulator,OS=16.2,name=iPhone 14" COMPILER_INDEX_STORE_ENABLE=NO + run: xcodebuild test -scheme SingleFactorAuth -destination "platform=iOS Simulator,OS=17.5,name=iPhone 14" COMPILER_INDEX_STORE_ENABLE=NO diff --git a/Sources/SingleFactorAuth/SingleFactorAuth.swift b/Sources/SingleFactorAuth/SingleFactorAuth.swift index bf6d15b..ee1da24 100644 --- a/Sources/SingleFactorAuth/SingleFactorAuth.swift +++ b/Sources/SingleFactorAuth/SingleFactorAuth.swift @@ -13,8 +13,8 @@ public class SingleFactorAuth { let torusUtils: TorusUtils private var sessionManager: SessionManager - public init(singleFactorAuthArgs: SFAParams) throws { - sessionManager = .init() + public init(singleFactorAuthArgs: SFAParams, sessionTime: Int) throws { + sessionManager = SessionManager(sessionTime: sessionTime) nodeDetailManager = NodeDetailManager(network: singleFactorAuthArgs.getNetwork()) let torusOptions = TorusOptions(clientId: singleFactorAuthArgs.getWeb3AuthClientId(), network: singleFactorAuthArgs.getNetwork(), enableOneKey: true) try torusUtils = TorusUtils(params: torusOptions) diff --git a/Tests/SingleFactorAuthTests/AquaTest.swift b/Tests/SingleFactorAuthTests/AquaTest.swift index bf04c58..d569929 100644 --- a/Tests/SingleFactorAuthTests/AquaTest.swift +++ b/Tests/SingleFactorAuthTests/AquaTest.swift @@ -15,7 +15,7 @@ final class AquaTest: XCTestCase { override func setUp() { singleFactorAuthArgs = SFAParams(web3AuthClientId: "CLIENT ID", network: .legacy(.AQUA)) - singleFactoreAuth = try! SingleFactorAuth(singleFactorAuthArgs: singleFactorAuthArgs) + singleFactoreAuth = try! SingleFactorAuth(singleFactorAuthArgs: singleFactorAuthArgs, sessionTime: 86400) } func testConnect() async throws { diff --git a/Tests/SingleFactorAuthTests/CyanTest.swift b/Tests/SingleFactorAuthTests/CyanTest.swift index dd8c1c4..d10a958 100644 --- a/Tests/SingleFactorAuthTests/CyanTest.swift +++ b/Tests/SingleFactorAuthTests/CyanTest.swift @@ -14,7 +14,7 @@ final class CyanTest: XCTestCase { override func setUp() { singleFactorAuthArgs = SFAParams(web3AuthClientId: "CLIENT ID", network: .legacy(.CYAN)) - singleFactoreAuth = try! SingleFactorAuth(singleFactorAuthArgs: singleFactorAuthArgs) + singleFactoreAuth = try! SingleFactorAuth(singleFactorAuthArgs: singleFactorAuthArgs, sessionTime: 86400) } func testConnect() async throws { diff --git a/Tests/SingleFactorAuthTests/SingleFactorAuthTests.swift b/Tests/SingleFactorAuthTests/SingleFactorAuthTests.swift index 3a350e6..618281a 100644 --- a/Tests/SingleFactorAuthTests/SingleFactorAuthTests.swift +++ b/Tests/SingleFactorAuthTests/SingleFactorAuthTests.swift @@ -14,7 +14,7 @@ final class SingleFactorAuthTests: XCTestCase { override func setUp() { singleFactorAuthArgs = SFAParams(web3AuthClientId: "CLIENT ID", network: .legacy(.TESTNET)) - singleFactoreAuth = try! SingleFactorAuth(singleFactorAuthArgs: singleFactorAuthArgs) + singleFactoreAuth = try! SingleFactorAuth(singleFactorAuthArgs: singleFactorAuthArgs, sessionTime: 86400) } func testConnect() async throws {