diff --git a/.swiftlint.yml b/.swiftlint.yml index 9fbd0542..e320cacd 100644 --- a/.swiftlint.yml +++ b/.swiftlint.yml @@ -13,7 +13,6 @@ identifier_name: error: 100 opt_in_rules: # some rules are only opt-in - first_where - - unused_private_declaration - empty_count - empty_string - empty_xctest_method diff --git a/.travis.yml b/.travis.yml index a10e8cff..e1fa0850 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,7 +25,7 @@ before_install: - xcrun simctl list # Update the brew and build dependencies tools - brew update && brew upgrade carthage - - carthage update --platform ios --use-xcframeworks --cache-builds --no-use-binaries + - carthage update --platform ios --cache-builds --use-xcframeworks --no-use-binaries - gem i slather # Force to update the Swiftlint to the last stable version - brew outdated swiftlint || brew upgrade swiftlint diff --git a/CHANGELOG.md b/CHANGELOG.md index a7c188b8..3f004c79 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,10 @@ Changelog ========= +[1.0.0-beta13](https://github.com/hyperwallet/hyperwallet-ios-sdk/releases/tag/1.0.0-beta13) +------------------- +- Fixed Xcode 12 issue + [1.0.0-beta12](https://github.com/hyperwallet/hyperwallet-ios-sdk/releases/tag/1.0.0-beta12) ------------------- - Added support for iOS 14 @@ -11,14 +15,12 @@ Changelog - Support update transfer method - Enhancements - [1.0.0-beta10](https://github.com/hyperwallet/hyperwallet-ios-sdk/releases/tag/1.0.0-beta10) ------------------- - Added Venmo as a Transfer method - Added support for List Prepaid Card Balances - Enhancements - [1.0.0-beta09](https://github.com/hyperwallet/hyperwallet-ios-sdk/releases/tag/1.0.0-beta09) ------------------- - Increased API response timeout diff --git a/HyperwalletSDK.podspec b/HyperwalletSDK.podspec index 56b82355..92c777b3 100644 --- a/HyperwalletSDK.podspec +++ b/HyperwalletSDK.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |spec| spec.name = 'HyperwalletSDK' - spec.version = '1.0.0-beta12' + spec.version = '1.0.0-beta13' spec.summary = 'Hyperwallet Core SDK for iOS to integrate with Hyperwallet Platform' spec.homepage = 'https://github.com/hyperwallet/hyperwallet-ios-sdk' spec.license = { :type => 'MIT', :file => 'LICENSE' } diff --git a/HyperwalletSDK.xcodeproj/project.pbxproj b/HyperwalletSDK.xcodeproj/project.pbxproj index 6073290a..65f9a12f 100644 --- a/HyperwalletSDK.xcodeproj/project.pbxproj +++ b/HyperwalletSDK.xcodeproj/project.pbxproj @@ -47,6 +47,7 @@ 980B9AE7251C0A2400653D1C /* PrepaidCardResponse.json in Resources */ = {isa = PBXBuildFile; fileRef = 980B9AE5251C052600653D1C /* PrepaidCardResponse.json */; }; 980C15DB2273BF91004C60D6 /* CHANGELOG.md in Resources */ = {isa = PBXBuildFile; fileRef = 980C15DA2273BF91004C60D6 /* CHANGELOG.md */; }; 980C15F12273D1FA004C60D6 /* ListBankCardResponse.json in Resources */ = {isa = PBXBuildFile; fileRef = DBCA37A6225D6D1700CD4137 /* ListBankCardResponse.json */; }; + 980E79402613B68E00F0834B /* Hippolyte.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = FD8C499225E014E30062A440 /* Hippolyte.xcframework */; }; 98101DC42238A2F000BA04CA /* HyperwalletSDK.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 98101DBA2238A2F000BA04CA /* HyperwalletSDK.framework */; }; B062E353E292414C07C70355 /* HyperwalletPaperCheckTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = B062EB9A428EB097C6B5B4FC /* HyperwalletPaperCheckTests.swift */; }; B062E601D8A9A6E7FCC498F7 /* PaperCheckErrorResponseWithMissingStateProvince.json in Resources */ = {isa = PBXBuildFile; fileRef = B062EC1CDD525FA26E0A7ED3 /* PaperCheckErrorResponseWithMissingStateProvince.json */; }; @@ -100,7 +101,6 @@ DB1A0422225D571B0080C8D6 /* AuthenticationTokenGeneratorMock.swift in Sources */ = {isa = PBXBuildFile; fileRef = DB1A0420225D571A0080C8D6 /* AuthenticationTokenGeneratorMock.swift */; }; DB1A0423225D571B0080C8D6 /* AuthenticationProviderMock.swift in Sources */ = {isa = PBXBuildFile; fileRef = DB1A0421225D571B0080C8D6 /* AuthenticationProviderMock.swift */; }; DB2A3B092261D2DC0049F891 /* HyperwalletSDK.h in Headers */ = {isa = PBXBuildFile; fileRef = DB2A3B082261D2DC0049F891 /* HyperwalletSDK.h */; settings = {ATTRIBUTES = (Public, ); }; }; - DB2A3B0E2261D4260049F891 /* Hippolyte.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DB2A3B0D2261D4260049F891 /* Hippolyte.framework */; }; DB3151CF22780AA300FC9F8E /* UserIndividualResponse.json in Resources */ = {isa = PBXBuildFile; fileRef = DB3151CE22780AA300FC9F8E /* UserIndividualResponse.json */; }; DB45190F22DD00A00022BD1F /* HyperwalletTransferMethodConfigurationFieldQueryTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = DB45190E22DD00A00022BD1F /* HyperwalletTransferMethodConfigurationFieldQueryTests.swift */; }; DB764E91227833E10053BB91 /* UserBusinessResponse.json in Resources */ = {isa = PBXBuildFile; fileRef = DB764E8F22782D890053BB91 /* UserBusinessResponse.json */; }; @@ -143,8 +143,6 @@ FD536D072579F98B0056DC2D /* HyperwalletTransferMethodUpdateConfigurationQueries.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD536D062579F98B0056DC2D /* HyperwalletTransferMethodUpdateConfigurationQueries.swift */; }; FD536D09257A3C610056DC2D /* HyperwalletTransferMethodUpdateConfigurationField.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD536D08257A3C610056DC2D /* HyperwalletTransferMethodUpdateConfigurationField.swift */; }; FD536D0C257A60CE0056DC2D /* HyperwalletTransferMethodUpdateConfigurationTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD536D0A257A60920056DC2D /* HyperwalletTransferMethodUpdateConfigurationTests.swift */; }; - FD8C499325E014E30062A440 /* Hippolyte.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = FD8C499225E014E30062A440 /* Hippolyte.xcframework */; }; - FD8C499425E014E30062A440 /* Hippolyte.xcframework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = FD8C499225E014E30062A440 /* Hippolyte.xcframework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; FDD2F4CF2580AFB0008E4CFC /* TransferMethodUpdateConfigurationFieldsPaypalResponse.json in Resources */ = {isa = PBXBuildFile; fileRef = FDD2F4CE2580AFB0008E4CFC /* TransferMethodUpdateConfigurationFieldsPaypalResponse.json */; }; FDD2F4D12580B1D0008E4CFC /* TransferMethodUpdateConfigurationFieldsBankCardResponse.json in Resources */ = {isa = PBXBuildFile; fileRef = FDD2F4D02580B1D0008E4CFC /* TransferMethodUpdateConfigurationFieldsBankCardResponse.json */; }; FDF2E7A6257E06D600589076 /* TransferMethodUpdateConfigurationFieldsResponse.json in Resources */ = {isa = PBXBuildFile; fileRef = FDF2E7A5257E06D600589076 /* TransferMethodUpdateConfigurationFieldsResponse.json */; }; @@ -161,20 +159,6 @@ }; /* End PBXContainerItemProxy section */ -/* Begin PBXCopyFilesBuildPhase section */ - FD8C499525E014E30062A440 /* Embed Frameworks */ = { - isa = PBXCopyFilesBuildPhase; - buildActionMask = 2147483647; - dstPath = ""; - dstSubfolderSpec = 10; - files = ( - FD8C499425E014E30062A440 /* Hippolyte.xcframework in Embed Frameworks */, - ); - name = "Embed Frameworks"; - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXCopyFilesBuildPhase section */ - /* Begin PBXFileReference section */ 0733FE082277C191000FB92A /* HyperwalletPayPalAccount.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HyperwalletPayPalAccount.swift; sourceTree = ""; }; 0733FE2A2277C743000FB92A /* HyperwalletPayPalAccountTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HyperwalletPayPalAccountTests.swift; sourceTree = ""; }; @@ -322,7 +306,6 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - FD8C499325E014E30062A440 /* Hippolyte.xcframework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -330,7 +313,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - DB2A3B0E2261D4260049F891 /* Hippolyte.framework in Frameworks */, + 980E79402613B68E00F0834B /* Hippolyte.xcframework in Frameworks */, 98101DC42238A2F000BA04CA /* HyperwalletSDK.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; @@ -738,7 +721,6 @@ 98101DB72238A2F000BA04CA /* Frameworks */, 98101DB82238A2F000BA04CA /* Resources */, DBCA37C3225E52DA00CD4137 /* Swiftlint */, - FD8C499525E014E30062A440 /* Embed Frameworks */, ); buildRules = ( ); @@ -1210,7 +1192,6 @@ "$(inherited)", "@executable_path/Frameworks", "@loader_path/Frameworks", - "$(PROJECT_DIR)/Carthage/Build/iOS", ); PRODUCT_BUNDLE_IDENTIFIER = com.hyperwallet.ios.HyperwalletSDKTests; PRODUCT_NAME = "$(TARGET_NAME)"; @@ -1238,7 +1219,6 @@ "$(inherited)", "@executable_path/Frameworks", "@loader_path/Frameworks", - "$(PROJECT_DIR)/Carthage/Build/iOS", ); PRODUCT_BUNDLE_IDENTIFIER = com.hyperwallet.ios.HyperwalletSDKTests; PRODUCT_NAME = "$(TARGET_NAME)"; diff --git a/README.md b/README.md index 805ebe9d..845ba249 100644 --- a/README.md +++ b/README.md @@ -27,13 +27,13 @@ Use [Carthage](https://github.com/Carthage/Carthage) or [CocoaPods](https://coco ### Carthage Specify it in your Cartfile: ```ogdl -github "hyperwallet/hyperwallet-ios-sdk" "1.0.0-beta12" +github "hyperwallet/hyperwallet-ios-sdk" "1.0.0-beta13" ``` ### CocoaPods Specify it in your Podfile: ```ruby -pod 'HyperwalletSDK', '~> 1.0.0-beta12' +pod 'HyperwalletSDK', '~> 1.0.0-beta13' ``` ## Initialization diff --git a/Sources/Info.plist b/Sources/Info.plist index 1d46ffc9..72c00ee9 100644 --- a/Sources/Info.plist +++ b/Sources/Info.plist @@ -21,6 +21,6 @@ CFBundleVersion $(CURRENT_PROJECT_VERSION) TAG_VERSION - 1.0.0-beta12 + 1.0.0-beta13 diff --git a/Tests/AnyCodableTests.swift b/Tests/AnyCodableTests.swift index 1677e813..fff41563 100644 --- a/Tests/AnyCodableTests.swift +++ b/Tests/AnyCodableTests.swift @@ -1,7 +1,7 @@ @testable import HyperwalletSDK import XCTest -//swiftlint:disable force_cast force_try +// swiftlint:disable force_cast force_try class AnyCodableTests: XCTestCase { func testEncode() { // Given diff --git a/Tests/Balance/HyperwalletBalanceTests.swift b/Tests/Balance/HyperwalletBalanceTests.swift index 5fef20e1..f721069d 100644 --- a/Tests/Balance/HyperwalletBalanceTests.swift +++ b/Tests/Balance/HyperwalletBalanceTests.swift @@ -79,7 +79,7 @@ class HyperwalletBalanceTests: XCTestCase { var userBalanceList: HyperwalletPageList? var errorResponse: HyperwalletErrorType? - //When + // When Hyperwallet.shared.listUserBalances { (result, error) in userBalanceList = result errorResponse = error @@ -93,6 +93,7 @@ class HyperwalletBalanceTests: XCTestCase { } } + // swiftlint:disable empty_xctest_method override static var defaultTestSuite: XCTestSuite { let testSuite = XCTestSuite(name: String(describing: self)) let testParameters = getTestParameters() diff --git a/Tests/Balance/HyperwalletPrepaidCardBalanceTests.swift b/Tests/Balance/HyperwalletPrepaidCardBalanceTests.swift index ecbfeb09..11554875 100644 --- a/Tests/Balance/HyperwalletPrepaidCardBalanceTests.swift +++ b/Tests/Balance/HyperwalletPrepaidCardBalanceTests.swift @@ -80,7 +80,7 @@ class HyperwalletPrepaidCardBalanceTests: XCTestCase { var prepaidCardBalanceList: HyperwalletPageList? var errorResponse: HyperwalletErrorType? - //When + // When Hyperwallet.shared.listPrepaidCardBalances(prepaidCardToken: "trm-1234") { (result, error) in prepaidCardBalanceList = result errorResponse = error @@ -94,6 +94,7 @@ class HyperwalletPrepaidCardBalanceTests: XCTestCase { } } + // swiftlint:disable empty_xctest_method override static var defaultTestSuite: XCTestSuite { let testSuite = XCTestSuite(name: String(describing: self)) let testParameters = getTestParameters() diff --git a/Tests/GraphQL/HyperwalletTransferMethodConfigurationTests.swift b/Tests/GraphQL/HyperwalletTransferMethodConfigurationTests.swift index 5f13410c..b76ba05b 100644 --- a/Tests/GraphQL/HyperwalletTransferMethodConfigurationTests.swift +++ b/Tests/GraphQL/HyperwalletTransferMethodConfigurationTests.swift @@ -2,7 +2,7 @@ import Hippolyte @testable import HyperwalletSDK import XCTest -//swiftlint:disable multiline_arguments +// swiftlint:disable multiline_arguments class HyperwalletTransferMethodConfigurationTests: XCTestCase { override func setUp() { Hyperwallet.setup(HyperwalletTestHelper.authenticationProvider) @@ -14,7 +14,7 @@ class HyperwalletTransferMethodConfigurationTests: XCTestCase { } } - //swiftlint:disable function_body_length + // swiftlint:disable function_body_length func testRetrieveTransferMethodConfigurationKeys_success() { // Given let request = setUpTransferMethodConfigurationRequest("TransferMethodConfigurationKeysResponse") diff --git a/Tests/GraphQL/HyperwalletTransferMethodUpdateConfigurationTests.swift b/Tests/GraphQL/HyperwalletTransferMethodUpdateConfigurationTests.swift index 2e7dcc5e..87e1fcc3 100644 --- a/Tests/GraphQL/HyperwalletTransferMethodUpdateConfigurationTests.swift +++ b/Tests/GraphQL/HyperwalletTransferMethodUpdateConfigurationTests.swift @@ -31,7 +31,7 @@ class HyperwalletTransferMethodUpdateConfigurationTests: XCTestCase { } } - //swiftlint:disable function_body_length + // swiftlint:disable function_body_length func testRetrieveTransferMethodUpdateConfigurationFields_bankAccount() { // Given let request = setUpTransferMethodUpdateConfigurationRequest("TransferMethodUpdateConfigurationFieldsResponse") diff --git a/Tests/GraphQL/TransferMethodConfigurationFieldResultTests.swift b/Tests/GraphQL/TransferMethodConfigurationFieldResultTests.swift index 2aef8ee6..6a1885c2 100644 --- a/Tests/GraphQL/TransferMethodConfigurationFieldResultTests.swift +++ b/Tests/GraphQL/TransferMethodConfigurationFieldResultTests.swift @@ -1,7 +1,7 @@ @testable import HyperwalletSDK import XCTest -//swiftlint:disable force_try +// swiftlint:disable force_try class TransferMethodConfigurationFieldResultTests: XCTestCase { var transferMethodConfigurationField: TransferMethodConfigurationField! var fieldResult: TransferMethodConfigurationFieldResult! diff --git a/Tests/GraphQL/TransferMethodConfigurationKeyResultTests.swift b/Tests/GraphQL/TransferMethodConfigurationKeyResultTests.swift index f6ec0971..0986f1c2 100644 --- a/Tests/GraphQL/TransferMethodConfigurationKeyResultTests.swift +++ b/Tests/GraphQL/TransferMethodConfigurationKeyResultTests.swift @@ -1,7 +1,7 @@ @testable import HyperwalletSDK import XCTest -//swiftlint:disable force_try +// swiftlint:disable force_try class TransferMethodConfigurationKeyResultTests: XCTestCase { var transferMethodConfigurationKey: TransferMethodConfigurationKey! var keyResult: TransferMethodConfigurationKeyResult! @@ -12,26 +12,6 @@ class TransferMethodConfigurationKeyResultTests: XCTestCase { keyResult = TransferMethodConfigurationKeyResult(transferMethodConfigurationKey.countries?.nodes) } - func testPerformanceCountries() { - self.measure { - _ = keyResult.countries() - } - } - - func testPerformanceUSCurrencies() { - self.measure { - _ = keyResult.currencies(from: keyResult.countries()?.first?.code ?? "") - } - } - - func testPerformanceTransferMethods() { - self.measure { - let country = keyResult.countries()?.first - _ = keyResult.transferMethodTypes(countryCode: country?.code ?? "", - currencyCode: country?.currencies?.nodes?.first?.code ?? "") - } - } - func testCountries_success() { let countries = keyResult.countries() XCTAssertEqual(countries?.count, 4) diff --git a/Tests/HTTPTransactionTests.swift b/Tests/HTTPTransactionTests.swift index 87c308ae..35759f8f 100644 --- a/Tests/HTTPTransactionTests.swift +++ b/Tests/HTTPTransactionTests.swift @@ -33,7 +33,7 @@ class HTTPTransactionTests: XCTestCase { // Given var hasRequestTransactionPerformed = false // When - an API call request is made - let completionHandler = {(data: [String: String]?, error: HyperwalletErrorType?) -> Void in + let completionHandler = {(_: [String: String]?, _: HyperwalletErrorType?) -> Void in hasRequestTransactionPerformed = true } transaction.performRest(httpMethod: .get, @@ -71,7 +71,7 @@ class HTTPTransactionTests: XCTestCase { var queryParamsDictionary: [String: String]? var urlValueComponents: URLComponents? // When - let completionHandler = { (data: [String: String]?, error: HyperwalletErrorType?) -> Void in } + let completionHandler = { (_: [String: String]?, _: HyperwalletErrorType?) -> Void in } transaction.performRest(httpMethod: .get, urlPath: "users/%@/bank-accounts", payload: "", @@ -122,7 +122,7 @@ class HTTPTransactionTests: XCTestCase { transferMethodType: "BANK_ACCOUNT", profile: "INDIVIDUAL") // When - an API call request is made - let completionHandler = { (data: [String: String]?, error: HyperwalletErrorType?) -> Void in } + let completionHandler = { (_: [String: String]?, _: HyperwalletErrorType?) -> Void in } transaction.performGraphQl(request, completionHandler: completionHandler) diff --git a/Tests/Receipt/HyperwalletReceiptTests.swift b/Tests/Receipt/HyperwalletReceiptTests.swift index 9a48c2ec..3391fe03 100644 --- a/Tests/Receipt/HyperwalletReceiptTests.swift +++ b/Tests/Receipt/HyperwalletReceiptTests.swift @@ -13,7 +13,7 @@ class HyperwalletReceiptTests: XCTestCase { } } - //swiftlint:disable function_body_length + // swiftlint:disable function_body_length func testListUserReceipts_success() { // Given let expectation = self.expectation(description: "List User Receipts completed") diff --git a/Tests/TransactionTypeTests.swift b/Tests/TransactionTypeTests.swift index a80047f4..eb75b279 100644 --- a/Tests/TransactionTypeTests.swift +++ b/Tests/TransactionTypeTests.swift @@ -58,7 +58,7 @@ class TransactionTypeTests: XCTestCase { XCTAssertEqual(authorizationValue, "Bearer \(authenticationToken)", "The Bearer token should be equals") } - //swiftlint:disable force_cast + // swiftlint:disable force_cast func testCreateRestRequest_invalidURL() { let transactionType: TransactionType = .rest let configuration = Configuration(createOn: 0, diff --git a/Tests/Transfer/HyperwalletTransferTests.swift b/Tests/Transfer/HyperwalletTransferTests.swift index d603477c..c2abbac7 100644 --- a/Tests/Transfer/HyperwalletTransferTests.swift +++ b/Tests/Transfer/HyperwalletTransferTests.swift @@ -24,7 +24,7 @@ class HyperwalletTransferTests: XCTestCase { var transferResponse: HyperwalletTransfer? var errorResponse: HyperwalletErrorType? - //When + // When let transferRequest = HyperwalletTransfer.Builder(clientTransferId: "6712348070812", sourceToken: "usr-123456", destinationToken: "trm-invalid-token") @@ -115,7 +115,7 @@ class HyperwalletTransferTests: XCTestCase { } func testScheduleTransfer_success() { - //Given + // Given let expectation = self.expectation(description: "Schedule transfer completed") let response = HyperwalletTestHelper.okHTTPResponse(for: "ScheduleTransferResponse") let url = String(format: "%@transfers/trf-123456/status-transitions", HyperwalletTestHelper.restURL) @@ -125,7 +125,7 @@ class HyperwalletTransferTests: XCTestCase { var statusTransitionResponse: HyperwalletStatusTransition? var errorResponse: HyperwalletErrorType? - //When + // When Hyperwallet.shared.scheduleTransfer(transferToken: "trf-123456", completion: { (result, error) in statusTransitionResponse = result errorResponse = error @@ -133,14 +133,14 @@ class HyperwalletTransferTests: XCTestCase { }) wait(for: [expectation], timeout: 1) - //Then + // Then XCTAssertNil(errorResponse, "The `errorResponse` should be nil") XCTAssertNotNil(statusTransitionResponse, "The `statusTransitionResponse` should not be nil") verifyStatusTransitionResponse(statusTransitionResponse) } func testListTransfers_success() { - //Given + // Given let expectation = self.expectation(description: "List Transfers completed") let response = HyperwalletTestHelper.okHTTPResponse(for: "ListTransferResponse") let url = String(format: "%@transfers?+", HyperwalletTestHelper.restURL) @@ -154,7 +154,7 @@ class HyperwalletTransferTests: XCTestCase { transferQueryParam.sourceToken = "usr-123456" transferQueryParam.destinationToken = "trm-123456" - //When + // When Hyperwallet.shared.listTransfers(queryParam: transferQueryParam) { (result, error) in transfersList = result errorResponse = error @@ -162,7 +162,7 @@ class HyperwalletTransferTests: XCTestCase { } wait(for: [expectation], timeout: 1) - //Then + // Then XCTAssertNil(errorResponse, "The `errorResponse` should be nil") verifyTransfersListResponse(transfersList) } @@ -178,7 +178,7 @@ class HyperwalletTransferTests: XCTestCase { var transfersList: HyperwalletPageList? var errorResponse: HyperwalletErrorType? - //When + // When Hyperwallet.shared.listTransfers { (result, error) in transfersList = result errorResponse = error @@ -195,13 +195,13 @@ class HyperwalletTransferTests: XCTestCase { private extension HyperwalletTransferTests { func verifyTransferResponse(_ response: HyperwalletTransfer?) { XCTAssertNotNil(response, "The `response` should be not nil") - //Mandatory fields + // Mandatory fields XCTAssertEqual(response?.clientTransferId, "6712348070812", "The `clientTransferId` should be 6712348070812") XCTAssertEqual(response?.destinationAmount, "62.29", "The `destinationAmount` should be 62.29") XCTAssertEqual(response?.destinationCurrency, "USD", "The `destinationCurrency` should be USD") XCTAssertEqual(response?.destinationToken, "trm-123456", "The `destinationToken` should be trm-123456") XCTAssertEqual(response?.sourceToken, "usr-123456", "The `sourceToken` should be usr-123456") - //Optional fields + // Optional fields XCTAssertEqual(response?.sourceAmount, "80", "The `sourceAmount` should be 80") XCTAssertEqual(response?.sourceCurrency, "CAD", "The `sourceCurrency` should be CAD") diff --git a/Tests/TransferMethod/HyperwalletPrepaidCardTests.swift b/Tests/TransferMethod/HyperwalletPrepaidCardTests.swift index 06a8b140..bd371ab3 100644 --- a/Tests/TransferMethod/HyperwalletPrepaidCardTests.swift +++ b/Tests/TransferMethod/HyperwalletPrepaidCardTests.swift @@ -40,7 +40,7 @@ class HyperwalletPrepaidCardTests: XCTestCase { XCTAssertEqual(prepaidCardResponse?.type, HyperwalletTransferMethod.TransferMethodType.prepaidCard.rawValue) } - //swiftlint:disable function_body_length + // swiftlint:disable function_body_length func testListPrepaidCards_success() { // Given let expectation = self.expectation(description: "List prepaid cards completed")