diff --git a/.codecov.yml b/.codecov.yml index 3af28fb7d..9d8475330 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -5,7 +5,7 @@ coverage: status: patch: default: - target: 49 + target: auto changes: false project: default: diff --git a/CHANGELOG.md b/CHANGELOG.md index f8e062e79..4eb5d389a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,9 +1,15 @@ # Parse-Swift Changelog ### main -[Full Changelog](https://github.com/parse-community/Parse-Swift/compare/1.5.0...main) +[Full Changelog](https://github.com/parse-community/Parse-Swift/compare/1.5.1...main) * _Contributing to this repo? Add info about your change here to be included in the next release_ +### 1.5.1 +[Full Changelog](https://github.com/parse-community/Parse-Swift/compare/1.5.0...1.5.1) + +__Improvements__ +- Update ParseError to match server and make ParseError and ParseObject Pointer documentation public ([#125](https://github.com/parse-community/Parse-Swift/pull/125)), thanks to [Corey Baker](https://github.com/cbaker6). + ### 1.5.0 [Full Changelog](https://github.com/parse-community/Parse-Swift/compare/1.4.0...1.5.0) diff --git a/ParseSwift.podspec b/ParseSwift.podspec index a28aee266..32638f23b 100644 --- a/ParseSwift.podspec +++ b/ParseSwift.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = "ParseSwift" - s.version = "1.5.0" + s.version = "1.5.1" s.summary = "Parse Pure Swift SDK" s.homepage = "https://github.com/parse-community/Parse-Swift" s.authors = { diff --git a/ParseSwift.xcodeproj/project.pbxproj b/ParseSwift.xcodeproj/project.pbxproj index 2e1648201..857926b3c 100644 --- a/ParseSwift.xcodeproj/project.pbxproj +++ b/ParseSwift.xcodeproj/project.pbxproj @@ -298,6 +298,9 @@ 70DFEA8A2618E77800F8EB4B /* InitializeSDKTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70DFEA892618E77800F8EB4B /* InitializeSDKTests.swift */; }; 70DFEA8B2618E77800F8EB4B /* InitializeSDKTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70DFEA892618E77800F8EB4B /* InitializeSDKTests.swift */; }; 70DFEA8C2618E77800F8EB4B /* InitializeSDKTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70DFEA892618E77800F8EB4B /* InitializeSDKTests.swift */; }; + 70E09E1C262F0634002DD451 /* ParsePointerCombineTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70E09E1B262F0634002DD451 /* ParsePointerCombineTests.swift */; }; + 70E09E1D262F0634002DD451 /* ParsePointerCombineTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70E09E1B262F0634002DD451 /* ParsePointerCombineTests.swift */; }; + 70E09E1E262F0634002DD451 /* ParsePointerCombineTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70E09E1B262F0634002DD451 /* ParsePointerCombineTests.swift */; }; 70F2E255254F247000B2EA5C /* ParseSwift.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4AFDA7121F26D9A5002AE4FC /* ParseSwift.framework */; }; 70F2E2B3254F283000B2EA5C /* ParseUserTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70C7DC1D24D20E530050419B /* ParseUserTests.swift */; }; 70F2E2B4254F283000B2EA5C /* ParseQueryTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 70C7DC1F24D20F180050419B /* ParseQueryTests.swift */; }; @@ -636,6 +639,7 @@ 70D1BE0625BB2BF400A42E7C /* ParseConfigTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ParseConfigTests.swift; sourceTree = ""; }; 70D1BE7225BB43EB00A42E7C /* BaseConfig.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseConfig.swift; sourceTree = ""; }; 70DFEA892618E77800F8EB4B /* InitializeSDKTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = InitializeSDKTests.swift; sourceTree = ""; }; + 70E09E1B262F0634002DD451 /* ParsePointerCombineTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ParsePointerCombineTests.swift; sourceTree = ""; }; 70F2E23E254F246000B2EA5C /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 70F2E250254F247000B2EA5C /* ParseSwiftTestsmacOS.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ParseSwiftTestsmacOS.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 70F2E254254F247000B2EA5C /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; @@ -843,6 +847,7 @@ 911DB13524C4FC100027F3C7 /* ParseObjectTests.swift */, 7044C1EB25C5CC930011F6E7 /* ParseOperationCombineTests.swift */, 70C5508425B4A68700B5DBC2 /* ParseOperationTests.swift */, + 70E09E1B262F0634002DD451 /* ParsePointerCombineTests.swift */, 70CE1D882545BF730018D572 /* ParsePointerTests.swift */, 7044C20525C5D6780011F6E7 /* ParseQueryCombineTests.swift */, 70C7DC1F24D20F180050419B /* ParseQueryTests.swift */, @@ -1665,6 +1670,7 @@ buildActionMask = 2147483647; files = ( 911DB13624C4FC100027F3C7 /* ParseObjectTests.swift in Sources */, + 70E09E1C262F0634002DD451 /* ParsePointerCombineTests.swift in Sources */, 89899D592603CF3E002E2043 /* ParseTwitterTests.swift in Sources */, 70CE1D892545BF730018D572 /* ParsePointerTests.swift in Sources */, 89899D772603CF66002E2043 /* ParseFacebookTests.swift in Sources */, @@ -1817,6 +1823,7 @@ buildActionMask = 2147483647; files = ( 709B98512556ECAA00507778 /* ParseEncoderTests.swift in Sources */, + 70E09E1E262F0634002DD451 /* ParsePointerCombineTests.swift in Sources */, 89899D642603CF3F002E2043 /* ParseTwitterTests.swift in Sources */, 709B98532556ECAA00507778 /* ParsePointerTests.swift in Sources */, 89899D822603CF67002E2043 /* ParseFacebookTests.swift in Sources */, @@ -1872,6 +1879,7 @@ buildActionMask = 2147483647; files = ( 70F2E2B6254F283000B2EA5C /* ParseACLTests.swift in Sources */, + 70E09E1D262F0634002DD451 /* ParsePointerCombineTests.swift in Sources */, 89899D632603CF3E002E2043 /* ParseTwitterTests.swift in Sources */, 70F2E2B7254F283000B2EA5C /* ParsePointerTests.swift in Sources */, 89899D812603CF67002E2043 /* ParseFacebookTests.swift in Sources */, @@ -2329,7 +2337,7 @@ INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 12.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = com.parse.ParseSwift; PRODUCT_NAME = ParseSwift; SKIP_INSTALL = YES; @@ -2353,7 +2361,7 @@ INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 12.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = com.parse.ParseSwift; PRODUCT_NAME = ParseSwift; SKIP_INSTALL = YES; @@ -2419,7 +2427,7 @@ INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.13; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = com.parse.ParseSwift; PRODUCT_NAME = ParseSwift; SDKROOT = macosx; @@ -2445,7 +2453,7 @@ INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.13; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; PRODUCT_BUNDLE_IDENTIFIER = com.parse.ParseSwift; PRODUCT_NAME = ParseSwift; SDKROOT = macosx; @@ -2592,7 +2600,7 @@ INFOPLIST_FILE = "ParseSwift-watchOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; PRODUCT_BUNDLE_IDENTIFIER = "com.parse.ParseSwift-watchOS"; @@ -2621,7 +2629,7 @@ INFOPLIST_FILE = "ParseSwift-watchOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; MTL_FAST_MATH = YES; PRODUCT_BUNDLE_IDENTIFIER = "com.parse.ParseSwift-watchOS"; PRODUCT_NAME = ParseSwift; @@ -2648,7 +2656,7 @@ INFOPLIST_FILE = "ParseSwift-tvOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; PRODUCT_BUNDLE_IDENTIFIER = "com.parse.ParseSwift-tvOS"; @@ -2676,7 +2684,7 @@ INFOPLIST_FILE = "ParseSwift-tvOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - MARKETING_VERSION = 1.5.0; + MARKETING_VERSION = 1.5.1; MTL_FAST_MATH = YES; PRODUCT_BUNDLE_IDENTIFIER = "com.parse.ParseSwift-tvOS"; PRODUCT_NAME = ParseSwift; diff --git a/Scripts/jazzy.sh b/Scripts/jazzy.sh index b49e96ad0..c6b8fb256 100755 --- a/Scripts/jazzy.sh +++ b/Scripts/jazzy.sh @@ -5,7 +5,7 @@ bundle exec jazzy \ --author_url http://parseplatform.org \ --github_url https://github.com/parse-community/Parse-Swift \ --root-url http://parseplatform.org/Parse-Swift/api/ \ - --module-version 1.5.0 \ + --module-version 1.5.1 \ --theme fullwidth \ --skip-undocumented \ --output ./docs/api \ diff --git a/Sources/ParseSwift/Objects/ParseObject+combine.swift b/Sources/ParseSwift/Objects/ParseObject+combine.swift index fbd7fd069..2ef066b40 100644 --- a/Sources/ParseSwift/Objects/ParseObject+combine.swift +++ b/Sources/ParseSwift/Objects/ParseObject+combine.swift @@ -22,7 +22,6 @@ public extension ParseObject { `includeAll` for `Query`. - parameter options: A set of header options sent to the server. Defaults to an empty set. - returns: A publisher that eventually produces a single value and then finishes or fails. - - important: If an object fetched has the same objectId as current, it will automatically update the current. */ func fetchPublisher(includeKeys: [String]? = nil, options: API.Options = []) -> Future { diff --git a/Sources/ParseSwift/ParseConstants.swift b/Sources/ParseSwift/ParseConstants.swift index 54f08266d..71b1e0bfd 100644 --- a/Sources/ParseSwift/ParseConstants.swift +++ b/Sources/ParseSwift/ParseConstants.swift @@ -9,7 +9,7 @@ import Foundation enum ParseConstants { - static let parseVersion = "1.5.0" + static let parseVersion = "1.5.1" static let hashingKey = "parseSwift" static let fileManagementDirectory = "parse/" static let fileManagementPrivateDocumentsDirectory = "Private Documents/" diff --git a/Sources/ParseSwift/Protocols/Fetchable.swift b/Sources/ParseSwift/Protocols/Fetchable.swift index 869fe1272..c80c328bf 100644 --- a/Sources/ParseSwift/Protocols/Fetchable.swift +++ b/Sources/ParseSwift/Protocols/Fetchable.swift @@ -6,6 +6,11 @@ // Copyright © 2020 Parse. All rights reserved. // +import Foundation +#if canImport(Combine) +import Combine +#endif + public protocol Fetchable: Decodable { associatedtype FetchingType @@ -13,8 +18,8 @@ public protocol Fetchable: Decodable { func fetch() throws -> FetchingType } -extension Fetchable { - public func fetch() throws -> FetchingType { +public extension Fetchable { + func fetch() throws -> FetchingType { try fetch(includeKeys: nil, options: []) } } diff --git a/Sources/ParseSwift/Storage/ParseStorage.swift b/Sources/ParseSwift/Storage/ParseStorage.swift index efb149c6d..15a37326b 100644 --- a/Sources/ParseSwift/Storage/ParseStorage.swift +++ b/Sources/ParseSwift/Storage/ParseStorage.swift @@ -6,7 +6,7 @@ // // MARK: ParseStorage -public struct ParseStorage { +struct ParseStorage { public static var shared = ParseStorage() private var backingStore: ParseKeyValueStore! diff --git a/Sources/ParseSwift/Types/ParseError.swift b/Sources/ParseSwift/Types/ParseError.swift index 33de9d4aa..68a6dfeac 100644 --- a/Sources/ParseSwift/Types/ParseError.swift +++ b/Sources/ParseSwift/Types/ParseError.swift @@ -8,10 +8,14 @@ import Foundation +/* + An object with a Parse code and message. + */ public struct ParseError: ParseType, Decodable, Swift.Error { public let code: Code public let message: String + /// A textual representation of this error. public var localizedDescription: String { return "ParseError code=\(code.rawValue) error=\(message)" } diff --git a/Sources/ParseSwift/Types/Pointer.swift b/Sources/ParseSwift/Types/Pointer.swift index 04e658ffa..6a50422c3 100644 --- a/Sources/ParseSwift/Types/Pointer.swift +++ b/Sources/ParseSwift/Types/Pointer.swift @@ -1,4 +1,7 @@ import Foundation +#if canImport(Combine) +import Combine +#endif private func getObjectId(target: T) throws -> String { guard let objectId = target.objectId else { @@ -14,18 +17,34 @@ private func getObjectId(target: Objectable) throws -> String { return objectId } +/// A Pointer referencing a ParseObject. public struct Pointer: Fetchable, Encodable { - public typealias FetchingType = T private let __type: String = "Pointer" // swiftlint:disable:this identifier_name + + /** + The id of the object. + */ public var objectId: String + + /** + The class name of the object. + */ public var className: String + /** + Create a Pointer type. + - parameter target: Object to point to. + */ public init(_ target: T) throws { self.objectId = try getObjectId(target: target) self.className = target.className } + /** + Create a Pointer type. + - parameter objectId: The id of the object. + */ public init(objectId: String) { self.className = T.className self.objectId = objectId @@ -42,8 +61,18 @@ public struct Pointer: Fetchable, Encodable { } } -extension Pointer { - public func fetch(includeKeys: [String]? = nil, options: API.Options = []) throws -> T { +public extension Pointer { + + /** + Fetches the `ParseObject` *synchronously* with the current data from the server and sets an error if one occurs. + - parameter includeKeys: The name(s) of the key(s) to include that are + `ParseObject`s. Use `["*"]` to include all keys. This is similar to `include` and + `includeAll` for `Query`. + - parameter options: A set of header options sent to the server. Defaults to an empty set. + - throws: An error of `ParseError` type. + */ + func fetch(includeKeys: [String]? = nil, + options: API.Options = []) throws -> T { let path = API.Endpoint.object(className: className, objectId: objectId) return try API.NonParseBodyCommand(method: .GET, path: path) { (data) -> T in @@ -51,8 +80,20 @@ extension Pointer { }.execute(options: options) } - public func fetch(options: API.Options = [], callbackQueue: DispatchQueue = .main, - completion: @escaping (Result) -> Void) { + /** + Fetches the `ParseObject` *asynchronously* and executes the given callback block. + - parameter includeKeys: The name(s) of the key(s) to include. Use `["*"]` to include + all keys. + - parameter options: A set of header options sent to the server. Defaults to an empty set. + - parameter callbackQueue: The queue to return to after completion. Default + value of .main. + - parameter completion: The block to execute when completed. + It should have the following argument signature: `(Result)`. + */ + func fetch(includeKeys: [String]? = nil, + options: API.Options = [], + callbackQueue: DispatchQueue = .main, + completion: @escaping (Result) -> Void) { let path = API.Endpoint.object(className: className, objectId: objectId) API.NonParseBodyCommand(method: .GET, path: path) { (data) -> T in @@ -63,6 +104,27 @@ extension Pointer { } } } + + #if canImport(Combine) + /** + Fetches the `ParseObject` *aynchronously* with the current data from the server and sets an error if one occurs. + Publishes when complete. + - parameter includeKeys: The name(s) of the key(s) to include that are + `ParseObject`s. Use `["*"]` to include all keys. This is similar to `include` and + `includeAll` for `Query`. + - parameter options: A set of header options sent to the server. Defaults to an empty set. + - returns: A publisher that eventually produces a single value and then finishes or fails. + */ + @available(macOS 10.15, iOS 13.0, macCatalyst 13.0, watchOS 6.0, tvOS 13.0, *) + func fetchPublisher(includeKeys: [String]? = nil, + options: API.Options = []) -> Future { + Future { promise in + self.fetch(includeKeys: includeKeys, + options: options, + completion: promise) + } + } + #endif } internal struct PointerType: Encodable { diff --git a/Tests/ParseSwiftTests/ParsePointerCombineTests.swift b/Tests/ParseSwiftTests/ParsePointerCombineTests.swift new file mode 100644 index 000000000..cdb1540ab --- /dev/null +++ b/Tests/ParseSwiftTests/ParsePointerCombineTests.swift @@ -0,0 +1,115 @@ +// +// ParsePointerCombineTests.swift +// ParseSwift +// +// Created by Corey Baker on 4/20/21. +// Copyright © 2021 Parse Community. All rights reserved. +// + +#if canImport(Combine) + +import Foundation +import XCTest +import Combine +@testable import ParseSwift + +@available(macOS 10.15, iOS 13.0, macCatalyst 13.0, watchOS 6.0, tvOS 13.0, *) +class ParsePointerCombineTests: XCTestCase { + + struct GameScore: ParseObject { + //: Those are required for Object + var objectId: String? + var createdAt: Date? + var updatedAt: Date? + var ACL: ParseACL? + + //: Your own properties + var score: Int + + //: a custom initializer + init(score: Int) { + self.score = score + } + } + + override func setUpWithError() throws { + try super.setUpWithError() + guard let url = URL(string: "http://localhost:1337/1") else { + throw ParseError(code: .unknownError, message: "Should create valid URL") + } + ParseSwift.initialize(applicationId: "applicationId", + clientKey: "clientKey", + masterKey: "masterKey", + serverURL: url, + testing: true) + } + + override func tearDownWithError() throws { + try super.tearDownWithError() + MockURLProtocol.removeAll() + #if !os(Linux) && !os(Android) + try KeychainStore.shared.deleteAll() + #endif + try ParseStorage.shared.deleteAll() + } + + func testFetch() throws { + var score = GameScore(score: 10) + let objectId = "yarr" + score.objectId = objectId + let pointer = try score.toPointer() + + var scoreOnServer = score + scoreOnServer.createdAt = Date() + scoreOnServer.updatedAt = scoreOnServer.createdAt + scoreOnServer.ACL = nil + + var subscriptions = Set() + let expectation1 = XCTestExpectation(description: "Fetch") + + let encoded: Data! + do { + encoded = try ParseCoding.jsonEncoder().encode(scoreOnServer) + //Get dates in correct format from ParseDecoding strategy + scoreOnServer = try scoreOnServer.getDecoder().decode(GameScore.self, from: encoded) + } catch { + XCTFail("Should encode/decode. Error \(error)") + return + } + + MockURLProtocol.mockRequests { _ in + return MockURLResponse(data: encoded, statusCode: 200, delay: 0.0) + } + + let publisher = pointer.fetchPublisher() + .sink(receiveCompletion: { result in + + if case let .failure(error) = result { + XCTFail(error.localizedDescription) + } + expectation1.fulfill() + + }, receiveValue: { fetched in + + XCTAssert(fetched.hasSameObjectId(as: scoreOnServer)) + guard let fetchedCreatedAt = fetched.createdAt, + let fetchedUpdatedAt = fetched.updatedAt else { + XCTFail("Should unwrap dates") + return + } + guard let originalCreatedAt = scoreOnServer.createdAt, + let originalUpdatedAt = scoreOnServer.updatedAt else { + XCTFail("Should unwrap dates") + return + } + XCTAssertEqual(fetchedCreatedAt, originalCreatedAt) + XCTAssertEqual(fetchedUpdatedAt, originalUpdatedAt) + XCTAssertNil(fetched.ACL) + }) + publisher.store(in: &subscriptions) + + wait(for: [expectation1], timeout: 20.0) + } +} + +#endif diff --git a/Tests/ParseSwiftTests/ParsePointerTests.swift b/Tests/ParseSwiftTests/ParsePointerTests.swift index c4103edb2..0253ae68c 100644 --- a/Tests/ParseSwiftTests/ParsePointerTests.swift +++ b/Tests/ParseSwiftTests/ParsePointerTests.swift @@ -6,7 +6,6 @@ // Copyright © 2020 Parse Community. All rights reserved. // -#if canImport(XCTest) import Foundation import XCTest @testable import ParseSwift @@ -61,6 +60,20 @@ class ParsePointerTests: XCTestCase { XCTAssertEqual(pointer.objectId, initializedPointer.objectId) } + func testPointerNoObjectId() throws { + let score = GameScore(score: 10) + XCTAssertThrowsError(try Pointer(score)) + } + + func testPointerObjectId() throws { + let score = Pointer(objectId: "yarr") + var score2 = GameScore(score: 10) + score2.objectId = "yarr" + let pointer = try score2.toPointer() + XCTAssertEqual(pointer.className, score.className) + XCTAssertEqual(pointer.objectId, score.objectId) + } + // swiftlint:disable:next function_body_length func testFetch() throws { var score = GameScore(score: 10) @@ -243,4 +256,3 @@ class ParsePointerTests: XCTestCase { self.fetchAsync(score: pointer, scoreOnServer: scoreOnServer, callbackQueue: .main) } } -#endif