Repository: IvanRublev/PersistentStorageSerializable Branch: master Commit: 55233686ef4a Files: 244 Total size: 883.7 KB Directory structure: gitextract_z6r8nz93/ ├── .gitignore ├── .swift-version ├── .travis.yml ├── Cartfile ├── Cartfile.private ├── Cartfile.resolved ├── Example/ │ ├── ExamplesOfUsage.playground/ │ │ ├── Contents.swift │ │ ├── contents.xcplayground │ │ └── timeline.xctimeline │ ├── PersistentStorageSerializable/ │ │ ├── AppDelegate.swift │ │ ├── Base.lproj/ │ │ │ ├── LaunchScreen.xib │ │ │ └── Main.storyboard │ │ ├── Images.xcassets/ │ │ │ └── AppIcon.appiconset/ │ │ │ └── Contents.json │ │ ├── Info.plist │ │ ├── Settings.swift │ │ └── ViewController.swift │ ├── PersistentStorageSerializable.xcodeproj/ │ │ ├── project.pbxproj │ │ ├── project.xcworkspace/ │ │ │ └── contents.xcworkspacedata │ │ └── xcshareddata/ │ │ └── xcschemes/ │ │ ├── PersistentStorageSerializable-MacExample.xcscheme │ │ ├── PersistentStorageSerializable-Tests.xcscheme │ │ └── PersistentStorageSerializable-iOSExample.xcscheme │ ├── PersistentStorageSerializable.xcworkspace/ │ │ └── contents.xcworkspacedata │ ├── PersistentStorageSerializable_MacExample/ │ │ ├── AppDelegate.swift │ │ ├── AppSettings.swift │ │ ├── Assets.xcassets/ │ │ │ └── AppIcon.appiconset/ │ │ │ └── Contents.json │ │ ├── Base.lproj/ │ │ │ └── Main.storyboard │ │ ├── Info.plist │ │ └── ViewController.swift │ ├── Podfile │ ├── Pods/ │ │ ├── Local Podspecs/ │ │ │ └── PersistentStorageSerializable.podspec.json │ │ ├── Manifest.lock │ │ ├── Nimble/ │ │ │ ├── LICENSE.md │ │ │ ├── README.md │ │ │ └── Sources/ │ │ │ ├── Lib/ │ │ │ │ └── CwlPreconditionTesting/ │ │ │ │ ├── CwlCatchException/ │ │ │ │ │ └── CwlCatchException/ │ │ │ │ │ ├── CwlCatchException.h │ │ │ │ │ ├── CwlCatchException.m │ │ │ │ │ └── CwlCatchException.swift │ │ │ │ └── CwlPreconditionTesting/ │ │ │ │ ├── CwlBadInstructionException.swift │ │ │ │ ├── CwlCatchBadInstruction.h │ │ │ │ ├── CwlCatchBadInstruction.m │ │ │ │ ├── CwlCatchBadInstruction.swift │ │ │ │ ├── CwlDarwinDefinitions.swift │ │ │ │ ├── mach_excServer.c │ │ │ │ └── mach_excServer.h │ │ │ ├── Nimble/ │ │ │ │ ├── Adapters/ │ │ │ │ │ ├── AdapterProtocols.swift │ │ │ │ │ ├── AssertionDispatcher.swift │ │ │ │ │ ├── AssertionRecorder.swift │ │ │ │ │ ├── NMBExpectation.swift │ │ │ │ │ ├── NMBObjCMatcher.swift │ │ │ │ │ ├── NimbleEnvironment.swift │ │ │ │ │ └── NimbleXCTestHandler.swift │ │ │ │ ├── DSL+Wait.swift │ │ │ │ ├── DSL.swift │ │ │ │ ├── Expectation.swift │ │ │ │ ├── Expression.swift │ │ │ │ ├── FailureMessage.swift │ │ │ │ ├── Matchers/ │ │ │ │ │ ├── AllPass.swift │ │ │ │ │ ├── AsyncMatcherWrapper.swift │ │ │ │ │ ├── BeAKindOf.swift │ │ │ │ │ ├── BeAnInstanceOf.swift │ │ │ │ │ ├── BeCloseTo.swift │ │ │ │ │ ├── BeEmpty.swift │ │ │ │ │ ├── BeGreaterThan.swift │ │ │ │ │ ├── BeGreaterThanOrEqualTo.swift │ │ │ │ │ ├── BeIdenticalTo.swift │ │ │ │ │ ├── BeLessThan.swift │ │ │ │ │ ├── BeLessThanOrEqual.swift │ │ │ │ │ ├── BeLogical.swift │ │ │ │ │ ├── BeNil.swift │ │ │ │ │ ├── BeVoid.swift │ │ │ │ │ ├── BeginWith.swift │ │ │ │ │ ├── Contain.swift │ │ │ │ │ ├── EndWith.swift │ │ │ │ │ ├── Equal.swift │ │ │ │ │ ├── HaveCount.swift │ │ │ │ │ ├── Match.swift │ │ │ │ │ ├── MatchError.swift │ │ │ │ │ ├── MatcherFunc.swift │ │ │ │ │ ├── MatcherProtocols.swift │ │ │ │ │ ├── PostNotification.swift │ │ │ │ │ ├── RaisesException.swift │ │ │ │ │ ├── SatisfyAnyOf.swift │ │ │ │ │ ├── ThrowAssertion.swift │ │ │ │ │ └── ThrowError.swift │ │ │ │ ├── Nimble.h │ │ │ │ └── Utils/ │ │ │ │ ├── Async.swift │ │ │ │ ├── Errors.swift │ │ │ │ ├── Functional.swift │ │ │ │ ├── SourceLocation.swift │ │ │ │ └── Stringers.swift │ │ │ └── NimbleObjectiveC/ │ │ │ ├── CurrentTestCaseTracker.h │ │ │ ├── DSL.h │ │ │ ├── DSL.m │ │ │ ├── NMBExceptionCapture.h │ │ │ ├── NMBExceptionCapture.m │ │ │ ├── NMBStringify.h │ │ │ ├── NMBStringify.m │ │ │ └── XCTestObservationCenter+Register.m │ │ ├── Pods.xcodeproj/ │ │ │ ├── project.pbxproj │ │ │ ├── project.xcworkspace/ │ │ │ │ └── contents.xcworkspacedata │ │ │ └── xcshareddata/ │ │ │ └── xcschemes/ │ │ │ ├── PersistentStorageSerializable-OSX.xcscheme │ │ │ ├── PersistentStorageSerializable-iOS.xcscheme │ │ │ ├── Reflection-OSX.xcscheme │ │ │ └── Reflection-iOS.xcscheme │ │ ├── Quick/ │ │ │ ├── LICENSE │ │ │ ├── README.md │ │ │ └── Sources/ │ │ │ ├── Quick/ │ │ │ │ ├── Callsite.swift │ │ │ │ ├── Configuration/ │ │ │ │ │ └── Configuration.swift │ │ │ │ ├── DSL/ │ │ │ │ │ ├── DSL.swift │ │ │ │ │ └── World+DSL.swift │ │ │ │ ├── ErrorUtility.swift │ │ │ │ ├── Example.swift │ │ │ │ ├── ExampleGroup.swift │ │ │ │ ├── ExampleMetadata.swift │ │ │ │ ├── Filter.swift │ │ │ │ ├── Hooks/ │ │ │ │ │ ├── Closures.swift │ │ │ │ │ ├── ExampleHooks.swift │ │ │ │ │ ├── HooksPhase.swift │ │ │ │ │ └── SuiteHooks.swift │ │ │ │ ├── NSBundle+CurrentTestBundle.swift │ │ │ │ ├── QuickSelectedTestSuiteBuilder.swift │ │ │ │ ├── QuickTestSuite.swift │ │ │ │ ├── URL+FileName.swift │ │ │ │ └── World.swift │ │ │ └── QuickObjectiveC/ │ │ │ ├── Configuration/ │ │ │ │ ├── QuickConfiguration.h │ │ │ │ └── QuickConfiguration.m │ │ │ ├── DSL/ │ │ │ │ ├── QCKDSL.h │ │ │ │ ├── QCKDSL.m │ │ │ │ └── World+DSL.h │ │ │ ├── NSString+QCKSelectorName.h │ │ │ ├── NSString+QCKSelectorName.m │ │ │ ├── Quick.h │ │ │ ├── QuickSpec.h │ │ │ ├── QuickSpec.m │ │ │ ├── World.h │ │ │ └── XCTestSuite+QuickTestSuiteBuilder.m │ │ ├── Reflection/ │ │ │ ├── LICENSE │ │ │ ├── README.md │ │ │ └── Sources/ │ │ │ └── Reflection/ │ │ │ ├── Advance.swift │ │ │ ├── Any+Extensions.swift │ │ │ ├── Array+Extensions.swift │ │ │ ├── Construct.swift │ │ │ ├── Get.swift │ │ │ ├── Identity.swift │ │ │ ├── MemoryProperties.swift │ │ │ ├── Metadata+Class.swift │ │ │ ├── Metadata+Kind.swift │ │ │ ├── Metadata+Struct.swift │ │ │ ├── Metadata+Tuple.swift │ │ │ ├── Metadata.swift │ │ │ ├── MetadataType.swift │ │ │ ├── NominalType.swift │ │ │ ├── NominalTypeDescriptor.swift │ │ │ ├── PointerType.swift │ │ │ ├── Properties.swift │ │ │ ├── ReflectionError.swift │ │ │ ├── RelativePointer.swift │ │ │ ├── Set.swift │ │ │ ├── Storage.swift │ │ │ ├── UnsafePointer+Extensions.swift │ │ │ └── ValueWitnessTable.swift │ │ └── Target Support Files/ │ │ ├── Nimble/ │ │ │ ├── Info.plist │ │ │ ├── Nimble-dummy.m │ │ │ ├── Nimble-prefix.pch │ │ │ ├── Nimble-umbrella.h │ │ │ ├── Nimble.modulemap │ │ │ └── Nimble.xcconfig │ │ ├── PersistentStorageSerializable-OSX/ │ │ │ ├── Info.plist │ │ │ ├── PersistentStorageSerializable-OSX-dummy.m │ │ │ ├── PersistentStorageSerializable-OSX-prefix.pch │ │ │ ├── PersistentStorageSerializable-OSX-umbrella.h │ │ │ ├── PersistentStorageSerializable-OSX.modulemap │ │ │ └── PersistentStorageSerializable-OSX.xcconfig │ │ ├── PersistentStorageSerializable-iOS/ │ │ │ ├── Info.plist │ │ │ ├── PersistentStorageSerializable-iOS-dummy.m │ │ │ ├── PersistentStorageSerializable-iOS-prefix.pch │ │ │ ├── PersistentStorageSerializable-iOS-umbrella.h │ │ │ ├── PersistentStorageSerializable-iOS.modulemap │ │ │ └── PersistentStorageSerializable-iOS.xcconfig │ │ ├── Pods-PersistentStorageSerializable_MacExample/ │ │ │ ├── Info.plist │ │ │ ├── Pods-PersistentStorageSerializable_MacExample-acknowledgements.markdown │ │ │ ├── Pods-PersistentStorageSerializable_MacExample-acknowledgements.plist │ │ │ ├── Pods-PersistentStorageSerializable_MacExample-dummy.m │ │ │ ├── Pods-PersistentStorageSerializable_MacExample-frameworks.sh │ │ │ ├── Pods-PersistentStorageSerializable_MacExample-resources.sh │ │ │ ├── Pods-PersistentStorageSerializable_MacExample-umbrella.h │ │ │ ├── Pods-PersistentStorageSerializable_MacExample.debug.xcconfig │ │ │ ├── Pods-PersistentStorageSerializable_MacExample.modulemap │ │ │ └── Pods-PersistentStorageSerializable_MacExample.release.xcconfig │ │ ├── Pods-PersistentStorageSerializable_Tests/ │ │ │ ├── Info.plist │ │ │ ├── Pods-PersistentStorageSerializable_Tests-acknowledgements.markdown │ │ │ ├── Pods-PersistentStorageSerializable_Tests-acknowledgements.plist │ │ │ ├── Pods-PersistentStorageSerializable_Tests-dummy.m │ │ │ ├── Pods-PersistentStorageSerializable_Tests-frameworks.sh │ │ │ ├── Pods-PersistentStorageSerializable_Tests-resources.sh │ │ │ ├── Pods-PersistentStorageSerializable_Tests-umbrella.h │ │ │ ├── Pods-PersistentStorageSerializable_Tests.debug.xcconfig │ │ │ ├── Pods-PersistentStorageSerializable_Tests.modulemap │ │ │ └── Pods-PersistentStorageSerializable_Tests.release.xcconfig │ │ ├── Pods-PersistentStorageSerializable_iOSExample/ │ │ │ ├── Info.plist │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample-acknowledgements.markdown │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample-acknowledgements.plist │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample-dummy.m │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample-frameworks.sh │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample-resources.sh │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample-umbrella.h │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig │ │ │ ├── Pods-PersistentStorageSerializable_iOSExample.modulemap │ │ │ └── Pods-PersistentStorageSerializable_iOSExample.release.xcconfig │ │ ├── Quick/ │ │ │ ├── Info.plist │ │ │ ├── Quick-dummy.m │ │ │ ├── Quick-prefix.pch │ │ │ ├── Quick-umbrella.h │ │ │ ├── Quick.modulemap │ │ │ └── Quick.xcconfig │ │ ├── Reflection-OSX/ │ │ │ ├── Info.plist │ │ │ ├── Reflection-OSX-dummy.m │ │ │ ├── Reflection-OSX-prefix.pch │ │ │ ├── Reflection-OSX-umbrella.h │ │ │ ├── Reflection-OSX.modulemap │ │ │ └── Reflection-OSX.xcconfig │ │ └── Reflection-iOS/ │ │ ├── Info.plist │ │ ├── Reflection-iOS-dummy.m │ │ ├── Reflection-iOS-prefix.pch │ │ ├── Reflection-iOS-umbrella.h │ │ ├── Reflection-iOS.modulemap │ │ └── Reflection-iOS.xcconfig │ └── Tests/ │ ├── Car.plist │ ├── Info.plist │ ├── PersistentStorageMock.swift │ ├── PersistentStorageSerializableTests.swift │ └── SupportedSerializableTypeTests.swift ├── LICENSE ├── PersistentStorageSerializable/ │ ├── Assets/ │ │ └── .gitkeep │ └── Classes/ │ ├── .gitkeep │ ├── PersistentStorage.swift │ ├── PersistentStorageSerializable.swift │ ├── PlistStorage.swift │ ├── PropertiesIteration.swift │ ├── SupportedSerializableType.swift │ ├── SwiftTryCatch.h │ ├── SwiftTryCatch.m │ └── UserDefaultsStorage.swift ├── PersistentStorageSerializable.podspec └── README.md ================================================ FILE CONTENTS ================================================ ================================================ FILE: .gitignore ================================================ # OS X .DS_Store # Xcode build/ *.pbxuser !default.pbxuser *.mode1v3 !default.mode1v3 *.mode2v3 !default.mode2v3 *.perspectivev3 !default.perspectivev3 xcuserdata/ *.xccheckout profile *.moved-aside DerivedData *.hmap *.ipa # Bundler .bundle Carthage # We recommend against adding the Pods directory to your .gitignore. However # you should judge for yourself, the pros and cons are mentioned at: # http://guides.cocoapods.org/using/using-cocoapods.html#should-i-ignore-the-pods-directory-in-source-control # # Note: if you ignore the Pods directory, make sure to uncomment # `pod install` in .travis.yml # !Pods/ Pods/* !Pods/Pods.xcodeproj/ Podfile.lock ================================================ FILE: .swift-version ================================================ 3.1 ================================================ FILE: .travis.yml ================================================ # references: # * http://www.objc.io/issue-6/travis-ci.html # * https://github.com/supermarin/xcpretty#usage osx_image: xcode8.3 language: objective-c # cache: cocoapods # podfile: Example/Podfile # before_install: # - gem install cocoapods # Since Travis is not always on latest version # - pod install --project-directory=Example before_install: cd Example && pod install && cd - install: - gem install xcpretty --no-rdoc --no-ri --no-document --quiet script: - set -o pipefail && xcodebuild test -workspace Example/PersistentStorageSerializable.xcworkspace -scheme PersistentStorageSerializable-Tests -sdk iphonesimulator10.0 -destination 'platform=iOS Simulator,name=iPhone SE,OS=10.0' ONLY_ACTIVE_ARCH=NO | xcpretty - pod lib lint ================================================ FILE: Cartfile ================================================ github "Zewo/Reflection" ~> 0.14 ================================================ FILE: Cartfile.private ================================================ github "jspahrsummers/xcconfigs" "2055f18" ================================================ FILE: Cartfile.resolved ================================================ github "Zewo/Reflection" "0.14.3" github "jspahrsummers/xcconfigs" "2055f18efbe18e77408f7f43947f7ad92b2d4ff0" ================================================ FILE: Example/ExamplesOfUsage.playground/Contents.swift ================================================ //: # PersistentStorageSerializable library. import UIKit import PersistentStorageSerializable /*: ## Custom persistent storage Usually, we use `UserDefaultsStorage` class provided by the library to serialize type values with the system user defaults. We can define a custom persistent storage by adopting `PersistentStorage` protocol. Let's define a memory storage and use it instead `UserDefaultsStorage` for demonstration purposes. */ final class MemoryStorage { var dictionary = [String : Any]() } extension MemoryStorage: PersistentStorage { func beginTransaction() throws {} func register(defaultValues: [String : Any]) {} func get(valueOf key: String) -> Any? { return dictionary[key] } func set(value: Any?, for key: String) throws { dictionary[key] = value } func finishTransaction() throws {} } let memoryStorage = MemoryStorage() /*: --- ## Serializing a struct type Declare struct type for your user preferences and adopt `PersistentStorageSerializable` protocol. */ struct UserPreferences: PersistentStorageSerializable { var myString = "Hello" var myBool = false // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! = "UserPreferences" } memoryStorage.dictionary var preferences = try! UserPreferences(from: memoryStorage) preferences.myString = "Greetings" preferences.myBool = true try! preferences.persist() //: Preferences values are persisted in storage. memoryStorage.dictionary /*: --- ## Serializing a class type If we use classes as a data structure for settings then we can use a custom subclass to adopt serialization functionality. */ class Serializable: PersistentStorageSerializable { var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! required init() {} } class AppSettings: Serializable { var myUInt = UInt.max var myDouble = 125.76 //: - We can use only plist types and collections of such types for properties. If we have to persist some other type we should convert it to plist one as shown below. var _myColor = [Float](arrayLiteral: 0, 0, 0, 0) var myColor: UIColor { get { return UIColor(colorLiteralRed: _myColor[0], green: _myColor[1], blue: _myColor[2], alpha: _myColor[3]) } set { var r: CGFloat = 0, g: CGFloat = 0, b: CGFloat = 0, a: CGFloat = 0 newValue.getRed(&r, green: &g, blue: &b, alpha: &a) _myColor = [Float(r), Float(g), Float(b), Float(a)] } } } var settings = try! AppSettings(from: memoryStorage, keyPrefix: "AppSettings") settings.myColor = UIColor.red try! settings.persist() //: The memory storage contains values of both `preferences` and `settings` instances. memoryStorage.dictionary /*: --- ## Reading data stored by the previous version of the app When you have some data persisted in user defaults by the previous version of the app and want `PersistentStorageSerializable` library to read that data into your structure you need to provide a mapping between properties names and User Defaults keys. Say we have our data persisted in storage. */ memoryStorage.dictionary.removeAll() memoryStorage.dictionary["oldGoogTitle"] = "Superhero" memoryStorage.dictionary["well.persisted.option"] = true memoryStorage.dictionary //: We want those to be serialized with the following class. final class ApplicationConfiguration: PersistentStorageSerializable { var title = "" var showIntro = false // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! } //: Provide key mapping by overloading `persistentStorageKey(for:)` function. extension ApplicationConfiguration { func persistentStorageKey(for propertyName: String) -> String { let keyMap = ["title" : "oldGoogTitle", "showIntro" : "well.persisted.option"] return keyMap[propertyName]! } } //: Now we can load data persisted in the storage. let configuration = try! ApplicationConfiguration(from: memoryStorage, keyPrefix: "") configuration.title configuration.showIntro //: ### Same with a custom subclass class SerializableWithKeyMap: PersistentStorageSerializable { var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! required init() {} var keyMap: [String : String]! func persistentStorageKey(for propertyName: String) -> String { return keyMap[propertyName]! } } class ApplicationConfiguration2: SerializableWithKeyMap { var title = "" var showIntro = false required init() { super.init() keyMap = ["title" : "oldGoogTitle", "showIntro" : "well.persisted.option"] } } let configuration2 = try! ApplicationConfiguration2(from: memoryStorage, keyPrefix: "") configuration2.title configuration2.showIntro /*: --- */ ================================================ FILE: Example/ExamplesOfUsage.playground/contents.xcplayground ================================================ ================================================ FILE: Example/ExamplesOfUsage.playground/timeline.xctimeline ================================================ ================================================ FILE: Example/PersistentStorageSerializable/AppDelegate.swift ================================================ // // AppDelegate.swift // PersistentStorageSerializable // // Created by IvanRublev on 04/05/2017. // Copyright (c) 2017 IvanRublev. All rights reserved. // import UIKit @UIApplicationMain class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { // Override point for customization after application launch. return true } func applicationWillResignActive(_ application: UIApplication) { // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. } func applicationDidEnterBackground(_ application: UIApplication) { // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. } func applicationWillEnterForeground(_ application: UIApplication) { // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. } func applicationDidBecomeActive(_ application: UIApplication) { // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. } func applicationWillTerminate(_ application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } } ================================================ FILE: Example/PersistentStorageSerializable/Base.lproj/LaunchScreen.xib ================================================ ================================================ FILE: Example/PersistentStorageSerializable/Base.lproj/Main.storyboard ================================================ ================================================ FILE: Example/PersistentStorageSerializable/Images.xcassets/AppIcon.appiconset/Contents.json ================================================ { "images" : [ { "idiom" : "iphone", "size" : "29x29", "scale" : "2x" }, { "idiom" : "iphone", "size" : "29x29", "scale" : "3x" }, { "idiom" : "iphone", "size" : "40x40", "scale" : "2x" }, { "idiom" : "iphone", "size" : "40x40", "scale" : "3x" }, { "idiom" : "iphone", "size" : "60x60", "scale" : "2x" }, { "idiom" : "iphone", "size" : "60x60", "scale" : "3x" } ], "info" : { "version" : 1, "author" : "xcode" } } ================================================ FILE: Example/PersistentStorageSerializable/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable $(EXECUTABLE_NAME) CFBundleIdentifier $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName $(PRODUCT_NAME) CFBundlePackageType APPL CFBundleShortVersionString 1.0 CFBundleSignature ???? CFBundleVersion 1 LSRequiresIPhoneOS UILaunchStoryboardName LaunchScreen UIMainStoryboardFile Main UIRequiredDeviceCapabilities armv7 UISupportedInterfaceOrientations UIInterfaceOrientationPortrait ================================================ FILE: Example/PersistentStorageSerializable/Settings.swift ================================================ // // Settings.swift // PersistentStorageSerializable // // Created by Ivan Rublev on 4/5/17. // Copyright © 2017 CocoaPods. All rights reserved. // import Foundation import PersistentStorageSerializable struct Settings: PersistentStorageSerializable { var flag = false var title = "" var number = 1 // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! } ================================================ FILE: Example/PersistentStorageSerializable/ViewController.swift ================================================ // // ViewController.swift // PersistentStorageSerializable // // Created by IvanRublev on 04/05/2017. // Copyright (c) 2017 IvanRublev. All rights reserved. // import UIKit import PersistentStorageSerializable class ViewController: UIViewController { @IBOutlet var flagSwitch: UISwitch! @IBOutlet var textField: UITextField! @IBOutlet var numberStepper: UIStepper! @IBOutlet var numberLabel: UILabel! @IBOutlet var userDefaultsLabel: UILabel! var settings: Settings! override func viewDidLoad() { super.viewDidLoad() load(0) } func updateViews() { flagSwitch.isOn = settings.flag textField.text = settings.title numberStepper.value = Double(settings.number) numberLabel.text = String(Int(numberStepper.value)) userDefaultsLabel.text = try! String(describing: settings.persistedDictionaryRepresentation()) } } // MARK: - Input controls actions extension ViewController { @IBAction func updateSettings(_ sender: Any) { settings.flag = flagSwitch.isOn settings.title = textField.text ?? "" settings.number = Int(numberStepper.value) updateViews() } @IBAction func donePressed(_ sender: Any) { textField.resignFirstResponder() } } // MARK: - Buttons actions extension ViewController { @IBAction func load(_ sender: Any) { settings = try! Settings(from: UserDefaultsStorage.standard, keyPrefix: "Settings") updateViews() } @IBAction func save(_ sender: Any) { try! settings.persist() updateViews() } @IBAction func reset(_ sender: Any) { try! settings.removeFromPersistentStorage() updateViews() } } ================================================ FILE: Example/PersistentStorageSerializable.xcodeproj/project.pbxproj ================================================ // !$*UTF8*$! { archiveVersion = 1; classes = { }; objectVersion = 46; objects = { /* Begin PBXBuildFile section */ 607FACD61AFB9204008FA782 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 607FACD51AFB9204008FA782 /* AppDelegate.swift */; }; 607FACD81AFB9204008FA782 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 607FACD71AFB9204008FA782 /* ViewController.swift */; }; 607FACDB1AFB9204008FA782 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 607FACD91AFB9204008FA782 /* Main.storyboard */; }; 607FACDD1AFB9204008FA782 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 607FACDC1AFB9204008FA782 /* Images.xcassets */; }; 607FACE01AFB9204008FA782 /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 607FACDE1AFB9204008FA782 /* LaunchScreen.xib */; }; 607FACEC1AFB9204008FA782 /* PersistentStorageSerializableTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 607FACEB1AFB9204008FA782 /* PersistentStorageSerializableTests.swift */; }; 80E924A82C6F4D136EF6DAFB /* Pods_PersistentStorageSerializable_iOSExample.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 095426B6186FB283A8442B6E /* Pods_PersistentStorageSerializable_iOSExample.framework */; }; 98D5D52F222783CA20C2F8FD /* Pods_PersistentStorageSerializable_Tests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C6F0D1E550D38F1ACE0CFCF6 /* Pods_PersistentStorageSerializable_Tests.framework */; }; AB2E65E91E97E506009A8531 /* Car.plist in Resources */ = {isa = PBXBuildFile; fileRef = AB2E65E81E97E506009A8531 /* Car.plist */; }; AB6AC3AF1E950D5300F735CB /* PersistentStorageMock.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB6AC3AD1E950C5E00F735CB /* PersistentStorageMock.swift */; }; AB6AC3B61E95513E00F735CB /* Settings.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB6AC3B51E95513E00F735CB /* Settings.swift */; }; AB6AC3C01E9680AE00F735CB /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB6AC3BF1E9680AE00F735CB /* AppDelegate.swift */; }; AB6AC3C21E9680AE00F735CB /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB6AC3C11E9680AE00F735CB /* ViewController.swift */; }; AB6AC3C41E9680AE00F735CB /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AB6AC3C31E9680AE00F735CB /* Assets.xcassets */; }; AB6AC3C71E9680AE00F735CB /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AB6AC3C51E9680AE00F735CB /* Main.storyboard */; }; AB6AC3CD1E96819C00F735CB /* AppSettings.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB6AC3CC1E96819C00F735CB /* AppSettings.swift */; }; AB76415C1E97CD57007279BE /* SupportedSerializableTypeTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB76415A1E97CD54007279BE /* SupportedSerializableTypeTests.swift */; }; B057D67654FF5F791A3E93A6 /* Pods_PersistentStorageSerializable_MacExample.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = B107F7FEBC35A8A1C3631674 /* Pods_PersistentStorageSerializable_MacExample.framework */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ 095426B6186FB283A8442B6E /* Pods_PersistentStorageSerializable_iOSExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_PersistentStorageSerializable_iOSExample.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 1430E68C73DA958AEE435B2B /* Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig"; path = "Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig"; sourceTree = ""; }; 2588AA89C5187E3CEA89DD6E /* Pods-PersistentStorageSerializable_iOSExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PersistentStorageSerializable_iOSExample.release.xcconfig"; path = "Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample.release.xcconfig"; sourceTree = ""; }; 410ED040FF5FC9E233E71DA9 /* Pods-PersistentStorageSerializable_MacExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PersistentStorageSerializable_MacExample.debug.xcconfig"; path = "Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample.debug.xcconfig"; sourceTree = ""; }; 607FACD01AFB9204008FA782 /* PersistentStorageSerializable_iOSExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = PersistentStorageSerializable_iOSExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; 607FACD41AFB9204008FA782 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 607FACD51AFB9204008FA782 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 607FACD71AFB9204008FA782 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; 607FACDA1AFB9204008FA782 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 607FACDC1AFB9204008FA782 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; 607FACDF1AFB9204008FA782 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; 607FACE51AFB9204008FA782 /* PersistentStorageSerializable_Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = PersistentStorageSerializable_Tests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 607FACEA1AFB9204008FA782 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 607FACEB1AFB9204008FA782 /* PersistentStorageSerializableTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PersistentStorageSerializableTests.swift; sourceTree = ""; }; 6C1240DEA24D615B61502A9B /* README.md */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = net.daringfireball.markdown; name = README.md; path = ../README.md; sourceTree = ""; }; 77A4C7A9C48761BFB96E9009 /* LICENSE */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = LICENSE; path = ../LICENSE; sourceTree = ""; }; AB2E65E81E97E506009A8531 /* Car.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Car.plist; sourceTree = ""; }; AB2E65EA1E98C6E2009A8531 /* ExamplesOfUsage.playground */ = {isa = PBXFileReference; lastKnownFileType = file.playground; path = ExamplesOfUsage.playground; sourceTree = ""; }; AB6AC3AD1E950C5E00F735CB /* PersistentStorageMock.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = PersistentStorageMock.swift; sourceTree = ""; }; AB6AC3B51E95513E00F735CB /* Settings.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Settings.swift; sourceTree = ""; }; AB6AC3BD1E9680AE00F735CB /* PersistentStorageSerializable_MacExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = PersistentStorageSerializable_MacExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; AB6AC3BF1E9680AE00F735CB /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; AB6AC3C11E9680AE00F735CB /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; AB6AC3C31E9680AE00F735CB /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; AB6AC3C61E9680AE00F735CB /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; AB6AC3C81E9680AE00F735CB /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; AB6AC3CC1E96819C00F735CB /* AppSettings.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppSettings.swift; sourceTree = ""; }; AB76415A1E97CD54007279BE /* SupportedSerializableTypeTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SupportedSerializableTypeTests.swift; sourceTree = ""; }; B107F7FEBC35A8A1C3631674 /* Pods_PersistentStorageSerializable_MacExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_PersistentStorageSerializable_MacExample.framework; sourceTree = BUILT_PRODUCTS_DIR; }; C6F0D1E550D38F1ACE0CFCF6 /* Pods_PersistentStorageSerializable_Tests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_PersistentStorageSerializable_Tests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; D0F7B87E59D17DF5674E4175 /* Pods-PersistentStorageSerializable_Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PersistentStorageSerializable_Tests.release.xcconfig"; path = "Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests.release.xcconfig"; sourceTree = ""; }; D61EE2F47F5FCAFA282DF7DD /* Pods-PersistentStorageSerializable_Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PersistentStorageSerializable_Tests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests.debug.xcconfig"; sourceTree = ""; }; DDAF776488859913631134E6 /* PersistentStorageSerializable.podspec */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = PersistentStorageSerializable.podspec; path = ../PersistentStorageSerializable.podspec; sourceTree = ""; }; E1CCB00B943B4FE159A27022 /* Pods-PersistentStorageSerializable_MacExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PersistentStorageSerializable_MacExample.release.xcconfig"; path = "Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample.release.xcconfig"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ 607FACCD1AFB9204008FA782 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 80E924A82C6F4D136EF6DAFB /* Pods_PersistentStorageSerializable_iOSExample.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 607FACE21AFB9204008FA782 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 98D5D52F222783CA20C2F8FD /* Pods_PersistentStorageSerializable_Tests.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; AB6AC3BA1E9680AE00F735CB /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( B057D67654FF5F791A3E93A6 /* Pods_PersistentStorageSerializable_MacExample.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ 607FACC71AFB9204008FA782 = { isa = PBXGroup; children = ( AB2E65EA1E98C6E2009A8531 /* ExamplesOfUsage.playground */, 607FACF51AFB993E008FA782 /* Podspec Metadata */, 607FACD21AFB9204008FA782 /* iOS Example for PersistentStorageSerializable */, AB6AC3BE1E9680AE00F735CB /* macOS Example for PersistentStorageSerializable */, 607FACE81AFB9204008FA782 /* Tests */, 607FACD11AFB9204008FA782 /* Products */, D03860B7B98A1F763B5BB4CC /* Pods */, 9A2B6143D980D7AC4AA0886D /* Frameworks */, ); sourceTree = ""; }; 607FACD11AFB9204008FA782 /* Products */ = { isa = PBXGroup; children = ( 607FACD01AFB9204008FA782 /* PersistentStorageSerializable_iOSExample.app */, 607FACE51AFB9204008FA782 /* PersistentStorageSerializable_Tests.xctest */, AB6AC3BD1E9680AE00F735CB /* PersistentStorageSerializable_MacExample.app */, ); name = Products; sourceTree = ""; }; 607FACD21AFB9204008FA782 /* iOS Example for PersistentStorageSerializable */ = { isa = PBXGroup; children = ( 607FACD51AFB9204008FA782 /* AppDelegate.swift */, 607FACD71AFB9204008FA782 /* ViewController.swift */, AB6AC3B51E95513E00F735CB /* Settings.swift */, 607FACD91AFB9204008FA782 /* Main.storyboard */, 607FACDC1AFB9204008FA782 /* Images.xcassets */, 607FACDE1AFB9204008FA782 /* LaunchScreen.xib */, 607FACD31AFB9204008FA782 /* Supporting Files */, ); name = "iOS Example for PersistentStorageSerializable"; path = PersistentStorageSerializable; sourceTree = ""; }; 607FACD31AFB9204008FA782 /* Supporting Files */ = { isa = PBXGroup; children = ( 607FACD41AFB9204008FA782 /* Info.plist */, ); name = "Supporting Files"; sourceTree = ""; }; 607FACE81AFB9204008FA782 /* Tests */ = { isa = PBXGroup; children = ( 607FACEB1AFB9204008FA782 /* PersistentStorageSerializableTests.swift */, AB76415A1E97CD54007279BE /* SupportedSerializableTypeTests.swift */, AB6AC3AD1E950C5E00F735CB /* PersistentStorageMock.swift */, AB2E65E81E97E506009A8531 /* Car.plist */, 607FACE91AFB9204008FA782 /* Supporting Files */, ); path = Tests; sourceTree = ""; }; 607FACE91AFB9204008FA782 /* Supporting Files */ = { isa = PBXGroup; children = ( 607FACEA1AFB9204008FA782 /* Info.plist */, ); name = "Supporting Files"; sourceTree = ""; }; 607FACF51AFB993E008FA782 /* Podspec Metadata */ = { isa = PBXGroup; children = ( DDAF776488859913631134E6 /* PersistentStorageSerializable.podspec */, 6C1240DEA24D615B61502A9B /* README.md */, 77A4C7A9C48761BFB96E9009 /* LICENSE */, ); name = "Podspec Metadata"; sourceTree = ""; }; 9A2B6143D980D7AC4AA0886D /* Frameworks */ = { isa = PBXGroup; children = ( C6F0D1E550D38F1ACE0CFCF6 /* Pods_PersistentStorageSerializable_Tests.framework */, B107F7FEBC35A8A1C3631674 /* Pods_PersistentStorageSerializable_MacExample.framework */, 095426B6186FB283A8442B6E /* Pods_PersistentStorageSerializable_iOSExample.framework */, ); name = Frameworks; sourceTree = ""; }; AB6AC3BE1E9680AE00F735CB /* macOS Example for PersistentStorageSerializable */ = { isa = PBXGroup; children = ( AB6AC3BF1E9680AE00F735CB /* AppDelegate.swift */, AB6AC3C11E9680AE00F735CB /* ViewController.swift */, AB6AC3CC1E96819C00F735CB /* AppSettings.swift */, AB6AC3C31E9680AE00F735CB /* Assets.xcassets */, AB6AC3C51E9680AE00F735CB /* Main.storyboard */, AB6AC3C81E9680AE00F735CB /* Info.plist */, ); name = "macOS Example for PersistentStorageSerializable"; path = PersistentStorageSerializable_MacExample; sourceTree = ""; }; D03860B7B98A1F763B5BB4CC /* Pods */ = { isa = PBXGroup; children = ( D61EE2F47F5FCAFA282DF7DD /* Pods-PersistentStorageSerializable_Tests.debug.xcconfig */, D0F7B87E59D17DF5674E4175 /* Pods-PersistentStorageSerializable_Tests.release.xcconfig */, 410ED040FF5FC9E233E71DA9 /* Pods-PersistentStorageSerializable_MacExample.debug.xcconfig */, E1CCB00B943B4FE159A27022 /* Pods-PersistentStorageSerializable_MacExample.release.xcconfig */, 1430E68C73DA958AEE435B2B /* Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig */, 2588AA89C5187E3CEA89DD6E /* Pods-PersistentStorageSerializable_iOSExample.release.xcconfig */, ); name = Pods; sourceTree = ""; }; /* End PBXGroup section */ /* Begin PBXNativeTarget section */ 607FACCF1AFB9204008FA782 /* PersistentStorageSerializable_iOSExample */ = { isa = PBXNativeTarget; buildConfigurationList = 607FACEF1AFB9204008FA782 /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable_iOSExample" */; buildPhases = ( 66755897DE9E279750DF07F9 /* [CP] Check Pods Manifest.lock */, 607FACCC1AFB9204008FA782 /* Sources */, 607FACCD1AFB9204008FA782 /* Frameworks */, 607FACCE1AFB9204008FA782 /* Resources */, 236D08738204335D7A43DEF1 /* [CP] Embed Pods Frameworks */, 27432223C0DD7682AC675BDF /* [CP] Copy Pods Resources */, ); buildRules = ( ); dependencies = ( ); name = PersistentStorageSerializable_iOSExample; productName = PersistentStorageSerializable; productReference = 607FACD01AFB9204008FA782 /* PersistentStorageSerializable_iOSExample.app */; productType = "com.apple.product-type.application"; }; 607FACE41AFB9204008FA782 /* PersistentStorageSerializable_Tests */ = { isa = PBXNativeTarget; buildConfigurationList = 607FACF21AFB9204008FA782 /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable_Tests" */; buildPhases = ( 82A9B6DE26A7AA265E46262D /* [CP] Check Pods Manifest.lock */, 607FACE11AFB9204008FA782 /* Sources */, 607FACE21AFB9204008FA782 /* Frameworks */, 607FACE31AFB9204008FA782 /* Resources */, 33157687998EEACBC2651DA7 /* [CP] Embed Pods Frameworks */, 389211693118A2DFD7B74393 /* [CP] Copy Pods Resources */, ); buildRules = ( ); dependencies = ( ); name = PersistentStorageSerializable_Tests; productName = Tests; productReference = 607FACE51AFB9204008FA782 /* PersistentStorageSerializable_Tests.xctest */; productType = "com.apple.product-type.bundle.unit-test"; }; AB6AC3BC1E9680AE00F735CB /* PersistentStorageSerializable_MacExample */ = { isa = PBXNativeTarget; buildConfigurationList = AB6AC3CB1E9680AE00F735CB /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable_MacExample" */; buildPhases = ( 83656AD5AD449BE38007FB5D /* [CP] Check Pods Manifest.lock */, AB6AC3B91E9680AE00F735CB /* Sources */, AB6AC3BA1E9680AE00F735CB /* Frameworks */, AB6AC3BB1E9680AE00F735CB /* Resources */, BB48EDF876C9F1A254792873 /* [CP] Embed Pods Frameworks */, 69E40D21BFAF5A6983432BE8 /* [CP] Copy Pods Resources */, ); buildRules = ( ); dependencies = ( ); name = PersistentStorageSerializable_MacExample; productName = PersistentStorageSerializable_MacExample; productReference = AB6AC3BD1E9680AE00F735CB /* PersistentStorageSerializable_MacExample.app */; productType = "com.apple.product-type.application"; }; /* End PBXNativeTarget section */ /* Begin PBXProject section */ 607FACC81AFB9204008FA782 /* Project object */ = { isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0830; LastUpgradeCheck = 0830; ORGANIZATIONNAME = CocoaPods; TargetAttributes = { 607FACCF1AFB9204008FA782 = { CreatedOnToolsVersion = 6.3.1; LastSwiftMigration = 0820; }; 607FACE41AFB9204008FA782 = { CreatedOnToolsVersion = 6.3.1; LastSwiftMigration = 0820; }; AB6AC3BC1E9680AE00F735CB = { CreatedOnToolsVersion = 8.3; ProvisioningStyle = Automatic; }; }; }; buildConfigurationList = 607FACCB1AFB9204008FA782 /* Build configuration list for PBXProject "PersistentStorageSerializable" */; compatibilityVersion = "Xcode 3.2"; developmentRegion = English; hasScannedForEncodings = 0; knownRegions = ( en, Base, ); mainGroup = 607FACC71AFB9204008FA782; productRefGroup = 607FACD11AFB9204008FA782 /* Products */; projectDirPath = ""; projectRoot = ""; targets = ( 607FACCF1AFB9204008FA782 /* PersistentStorageSerializable_iOSExample */, AB6AC3BC1E9680AE00F735CB /* PersistentStorageSerializable_MacExample */, 607FACE41AFB9204008FA782 /* PersistentStorageSerializable_Tests */, ); }; /* End PBXProject section */ /* Begin PBXResourcesBuildPhase section */ 607FACCE1AFB9204008FA782 /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( 607FACDB1AFB9204008FA782 /* Main.storyboard in Resources */, 607FACE01AFB9204008FA782 /* LaunchScreen.xib in Resources */, 607FACDD1AFB9204008FA782 /* Images.xcassets in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; 607FACE31AFB9204008FA782 /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( AB2E65E91E97E506009A8531 /* Car.plist in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; AB6AC3BB1E9680AE00F735CB /* Resources */ = { isa = PBXResourcesBuildPhase; buildActionMask = 2147483647; files = ( AB6AC3C41E9680AE00F735CB /* Assets.xcassets in Resources */, AB6AC3C71E9680AE00F735CB /* Main.storyboard in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXResourcesBuildPhase section */ /* Begin PBXShellScriptBuildPhase section */ 236D08738204335D7A43DEF1 /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Embed Pods Frameworks"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; 27432223C0DD7682AC675BDF /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Copy Pods Resources"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-resources.sh\"\n"; showEnvVarsInLog = 0; }; 33157687998EEACBC2651DA7 /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Embed Pods Frameworks"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; 389211693118A2DFD7B74393 /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Copy Pods Resources"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-resources.sh\"\n"; showEnvVarsInLog = 0; }; 66755897DE9E279750DF07F9 /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Check Pods Manifest.lock"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; 69E40D21BFAF5A6983432BE8 /* [CP] Copy Pods Resources */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Copy Pods Resources"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-resources.sh\"\n"; showEnvVarsInLog = 0; }; 82A9B6DE26A7AA265E46262D /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Check Pods Manifest.lock"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; 83656AD5AD449BE38007FB5D /* [CP] Check Pods Manifest.lock */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Check Pods Manifest.lock"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; showEnvVarsInLog = 0; }; BB48EDF876C9F1A254792873 /* [CP] Embed Pods Frameworks */ = { isa = PBXShellScriptBuildPhase; buildActionMask = 2147483647; files = ( ); inputPaths = ( ); name = "[CP] Embed Pods Frameworks"; outputPaths = ( ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-frameworks.sh\"\n"; showEnvVarsInLog = 0; }; /* End PBXShellScriptBuildPhase section */ /* Begin PBXSourcesBuildPhase section */ 607FACCC1AFB9204008FA782 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( AB6AC3B61E95513E00F735CB /* Settings.swift in Sources */, 607FACD81AFB9204008FA782 /* ViewController.swift in Sources */, 607FACD61AFB9204008FA782 /* AppDelegate.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 607FACE11AFB9204008FA782 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( AB6AC3AF1E950D5300F735CB /* PersistentStorageMock.swift in Sources */, 607FACEC1AFB9204008FA782 /* PersistentStorageSerializableTests.swift in Sources */, AB76415C1E97CD57007279BE /* SupportedSerializableTypeTests.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; AB6AC3B91E9680AE00F735CB /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( AB6AC3CD1E96819C00F735CB /* AppSettings.swift in Sources */, AB6AC3C21E9680AE00F735CB /* ViewController.swift in Sources */, AB6AC3C01E9680AE00F735CB /* AppDelegate.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXSourcesBuildPhase section */ /* Begin PBXVariantGroup section */ 607FACD91AFB9204008FA782 /* Main.storyboard */ = { isa = PBXVariantGroup; children = ( 607FACDA1AFB9204008FA782 /* Base */, ); name = Main.storyboard; sourceTree = ""; }; 607FACDE1AFB9204008FA782 /* LaunchScreen.xib */ = { isa = PBXVariantGroup; children = ( 607FACDF1AFB9204008FA782 /* Base */, ); name = LaunchScreen.xib; sourceTree = ""; }; AB6AC3C51E9680AE00F735CB /* Main.storyboard */ = { isa = PBXVariantGroup; children = ( AB6AC3C61E9680AE00F735CB /* Base */, ); name = Main.storyboard; sourceTree = ""; }; /* End PBXVariantGroup section */ /* Begin XCBuildConfiguration section */ 607FACED1AFB9204008FA782 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; GCC_NO_COMMON_BLOCKS = YES; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", "$(inherited)", ); GCC_SYMBOLS_PRIVATE_EXTERN = NO; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; }; name = Debug; }; 607FACEE1AFB9204008FA782 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INFINITE_RECURSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; CLANG_WARN_SUSPICIOUS_MOVE = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; ENABLE_NS_ASSERTIONS = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_NO_COMMON_BLOCKS = YES; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; VALIDATE_PRODUCT = YES; }; name = Release; }; 607FACF01AFB9204008FA782 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 1430E68C73DA958AEE435B2B /* Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; INFOPLIST_FILE = PersistentStorageSerializable/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; MODULE_NAME = ExampleApp; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_VERSION = 3.0; }; name = Debug; }; 607FACF11AFB9204008FA782 /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = 2588AA89C5187E3CEA89DD6E /* Pods-PersistentStorageSerializable_iOSExample.release.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; INFOPLIST_FILE = PersistentStorageSerializable/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; MODULE_NAME = ExampleApp; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_VERSION = 3.0; }; name = Release; }; 607FACF31AFB9204008FA782 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = D61EE2F47F5FCAFA282DF7DD /* Pods-PersistentStorageSerializable_Tests.debug.xcconfig */; buildSettings = { GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", "$(inherited)", ); INFOPLIST_FILE = Tests/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_VERSION = 3.0; }; name = Debug; }; 607FACF41AFB9204008FA782 /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = D0F7B87E59D17DF5674E4175 /* Pods-PersistentStorageSerializable_Tests.release.xcconfig */; buildSettings = { INFOPLIST_FILE = Tests/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.$(PRODUCT_NAME:rfc1034identifier)"; PRODUCT_NAME = "$(TARGET_NAME)"; SWIFT_VERSION = 3.0; }; name = Release; }; AB6AC3C91E9680AE00F735CB /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 410ED040FF5FC9E233E71DA9 /* Pods-PersistentStorageSerializable_MacExample.debug.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ANALYZER_NONNULL = YES; CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CODE_SIGN_IDENTITY = "Mac Developer"; COMBINE_HIDPI_IMAGES = YES; DEBUG_INFORMATION_FORMAT = dwarf; DEVELOPMENT_TEAM = ""; INFOPLIST_FILE = PersistentStorageSerializable_MacExample/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.PersistentStorageSerializable-MacExample"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; SDKROOT = macosx; SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; SWIFT_VERSION = 3.0; }; name = Debug; }; AB6AC3CA1E9680AE00F735CB /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = E1CCB00B943B4FE159A27022 /* Pods-PersistentStorageSerializable_MacExample.release.xcconfig */; buildSettings = { ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ANALYZER_NONNULL = YES; CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; CODE_SIGN_IDENTITY = "Mac Developer"; COMBINE_HIDPI_IMAGES = YES; DEVELOPMENT_TEAM = ""; INFOPLIST_FILE = PersistentStorageSerializable_MacExample/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.PersistentStorageSerializable-MacExample"; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; SDKROOT = macosx; SWIFT_VERSION = 3.0; }; name = Release; }; /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ 607FACCB1AFB9204008FA782 /* Build configuration list for PBXProject "PersistentStorageSerializable" */ = { isa = XCConfigurationList; buildConfigurations = ( 607FACED1AFB9204008FA782 /* Debug */, 607FACEE1AFB9204008FA782 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 607FACEF1AFB9204008FA782 /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable_iOSExample" */ = { isa = XCConfigurationList; buildConfigurations = ( 607FACF01AFB9204008FA782 /* Debug */, 607FACF11AFB9204008FA782 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 607FACF21AFB9204008FA782 /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable_Tests" */ = { isa = XCConfigurationList; buildConfigurations = ( 607FACF31AFB9204008FA782 /* Debug */, 607FACF41AFB9204008FA782 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; AB6AC3CB1E9680AE00F735CB /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable_MacExample" */ = { isa = XCConfigurationList; buildConfigurations = ( AB6AC3C91E9680AE00F735CB /* Debug */, AB6AC3CA1E9680AE00F735CB /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; /* End XCConfigurationList section */ }; rootObject = 607FACC81AFB9204008FA782 /* Project object */; } ================================================ FILE: Example/PersistentStorageSerializable.xcodeproj/project.xcworkspace/contents.xcworkspacedata ================================================ ================================================ FILE: Example/PersistentStorageSerializable.xcodeproj/xcshareddata/xcschemes/PersistentStorageSerializable-MacExample.xcscheme ================================================ ================================================ FILE: Example/PersistentStorageSerializable.xcodeproj/xcshareddata/xcschemes/PersistentStorageSerializable-Tests.xcscheme ================================================ ================================================ FILE: Example/PersistentStorageSerializable.xcodeproj/xcshareddata/xcschemes/PersistentStorageSerializable-iOSExample.xcscheme ================================================ ================================================ FILE: Example/PersistentStorageSerializable.xcworkspace/contents.xcworkspacedata ================================================ ================================================ FILE: Example/PersistentStorageSerializable_MacExample/AppDelegate.swift ================================================ // // AppDelegate.swift // PersistentStorageSerializable_MacExample // // Created by Ivan Rublev on 4/6/17. // Copyright © 2017 CocoaPods. All rights reserved. // import Cocoa @NSApplicationMain class AppDelegate: NSObject, NSApplicationDelegate { func applicationDidFinishLaunching(_ aNotification: Notification) { // Insert code here to initialize your application } func applicationWillTerminate(_ aNotification: Notification) { // Insert code here to tear down your application } } ================================================ FILE: Example/PersistentStorageSerializable_MacExample/AppSettings.swift ================================================ // // AppSettings.swift // PersistentStorageSerializable // // Created by Ivan Rublev on 4/6/17. // Copyright © 2017 CocoaPods. All rights reserved. // import Foundation import PersistentStorageSerializable final class AppSettings: NSObject, PersistentStorageSerializable { dynamic var flag = false dynamic var title = "Default text" dynamic var number = 1 // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! = PlistStorage(at: FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).last!.appendingPathComponent("storage.plist")) var persistentStorageKeyPrefix: String! = "AppSettings" } ================================================ FILE: Example/PersistentStorageSerializable_MacExample/Assets.xcassets/AppIcon.appiconset/Contents.json ================================================ { "images" : [ { "idiom" : "mac", "size" : "16x16", "scale" : "1x" }, { "idiom" : "mac", "size" : "16x16", "scale" : "2x" }, { "idiom" : "mac", "size" : "32x32", "scale" : "1x" }, { "idiom" : "mac", "size" : "32x32", "scale" : "2x" }, { "idiom" : "mac", "size" : "128x128", "scale" : "1x" }, { "idiom" : "mac", "size" : "128x128", "scale" : "2x" }, { "idiom" : "mac", "size" : "256x256", "scale" : "1x" }, { "idiom" : "mac", "size" : "256x256", "scale" : "2x" }, { "idiom" : "mac", "size" : "512x512", "scale" : "1x" }, { "idiom" : "mac", "size" : "512x512", "scale" : "2x" } ], "info" : { "version" : 1, "author" : "xcode" } } ================================================ FILE: Example/PersistentStorageSerializable_MacExample/Base.lproj/Main.storyboard ================================================ Default Left to Right Right to Left Default Left to Right Right to Left ================================================ FILE: Example/PersistentStorageSerializable_MacExample/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable $(EXECUTABLE_NAME) CFBundleIconFile CFBundleIdentifier $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName $(PRODUCT_NAME) CFBundlePackageType APPL CFBundleShortVersionString 1.0 CFBundleVersion 1 LSMinimumSystemVersion $(MACOSX_DEPLOYMENT_TARGET) NSHumanReadableCopyright Copyright © 2017 CocoaPods. All rights reserved. NSMainStoryboardFile Main NSPrincipalClass NSApplication ================================================ FILE: Example/PersistentStorageSerializable_MacExample/ViewController.swift ================================================ // // ViewController.swift // PersistentStorageSerializable_MacExample // // Created by Ivan Rublev on 4/6/17. // Copyright © 2017 CocoaPods. All rights reserved. // import Cocoa class ViewController: NSViewController { @IBOutlet var userDefaultsText: NSTextField! dynamic var settings = AppSettings() override func viewDidLoad() { super.viewDidLoad() load(0) } func updateUserDefaultsText() { userDefaultsText.stringValue = try! String(describing: settings.persistedDictionaryRepresentation()) } @IBAction func load(_ sender: Any) { view.window?.makeFirstResponder(nil) var loadedSettings = AppSettings() try! loadedSettings.pullFromPersistentStorage() settings = loadedSettings updateUserDefaultsText() } @IBAction func save(_ sender: Any) { view.window?.makeFirstResponder(nil) try! settings.pushToPersistentStorage() updateUserDefaultsText() } @IBAction func reset(_ sender: Any) { view.window?.makeFirstResponder(nil) try! settings.removeFromPersistentStorage() updateUserDefaultsText() } } ================================================ FILE: Example/Podfile ================================================ use_frameworks! target 'PersistentStorageSerializable_iOSExample' do platform :ios, '9.0' pod 'PersistentStorageSerializable', :path => '../' end target 'PersistentStorageSerializable_Tests' do platform :ios, '9.0' pod 'PersistentStorageSerializable', :path => '../' pod 'Quick', '~> 1.0.0' pod 'Nimble', '~> 5.1.1' end target 'PersistentStorageSerializable_MacExample' do platform :osx, '10.11' pod 'PersistentStorageSerializable', :path => '../' end ================================================ FILE: Example/Pods/Local Podspecs/PersistentStorageSerializable.podspec.json ================================================ { "name": "PersistentStorageSerializable", "version": "1.1.0", "summary": "Bunch of protocols to make a class or structure to be serializable to persistent system storage like UserDefaults or Keychain. Useful to store app configuration or settings.", "description": "Number of protocols from this pod helps to serialize swift class or structure to persistent storage like User Defaults or Keychain. The class/structure must contain properties of simple data type only. These types are: Data, String, Int, Float, Double, Bool, URL, Date, Array, or Dictionary.\nAdopt the PersistentStorageSerializable protocol from your struct. Then call pullFromUserDefaults() or pushToUserDefaults() on instance of your struct.", "homepage": "https://github.com/IvanRublev/PersistentStorageSerializable", "license": { "type": "MIT", "file": "LICENSE" }, "authors": { "IvanRublev": "ivan@ivanrublev.me" }, "source": { "git": "https://github.com/IvanRublev/PersistentStorageSerializable.git", "tag": "1.1.0" }, "platforms": { "ios": "9.0", "osx": "10.11" }, "source_files": "PersistentStorageSerializable/Classes/**/*", "frameworks": "Foundation", "dependencies": { "Reflection": [ "~> 0.14" ] } } ================================================ FILE: Example/Pods/Manifest.lock ================================================ PODS: - Nimble (5.1.1) - PersistentStorageSerializable (1.1.0): - Reflection (~> 0.14) - Quick (1.0.0) - Reflection (0.14.3) DEPENDENCIES: - Nimble (~> 5.1.1) - PersistentStorageSerializable (from `../`) - Quick (~> 1.0.0) EXTERNAL SOURCES: PersistentStorageSerializable: :path: "../" SPEC CHECKSUMS: Nimble: 415e3aa3267e7bc2c96b05fa814ddea7bb686a29 PersistentStorageSerializable: d941980a136f85a546b3378c6228526ad4fd7d51 Quick: 8024e4a47e6cc03a9d5245ef0948264fc6d27cff Reflection: 93327e50981227ac33c18274fcbaed33b1127811 PODFILE CHECKSUM: 1725b222e0b97edb7fa20facee56f57f70eaa39d COCOAPODS: 1.1.1 ================================================ FILE: Example/Pods/Nimble/LICENSE.md ================================================ Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright 2014 Quick Team Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ================================================ FILE: Example/Pods/Nimble/README.md ================================================ # Nimble Use Nimble to express the expected outcomes of Swift or Objective-C expressions. Inspired by [Cedar](https://github.com/pivotal/cedar). ```swift // Swift expect(1 + 1).to(equal(2)) expect(1.2).to(beCloseTo(1.1, within: 0.1)) expect(3) > 2 expect("seahorse").to(contain("sea")) expect(["Atlantic", "Pacific"]).toNot(contain("Mississippi")) expect(ocean.isClean).toEventually(beTruthy()) ``` # How to Use Nimble **Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)* - [Some Background: Expressing Outcomes Using Assertions in XCTest](#some-background-expressing-outcomes-using-assertions-in-xctest) - [Nimble: Expectations Using `expect(...).to`](#nimble-expectations-using-expectto) - [Custom Failure Messages](#custom-failure-messages) - [Type Checking](#type-checking) - [Operator Overloads](#operator-overloads) - [Lazily Computed Values](#lazily-computed-values) - [C Primitives](#c-primitives) - [Asynchronous Expectations](#asynchronous-expectations) - [Objective-C Support](#objective-c-support) - [Disabling Objective-C Shorthand](#disabling-objective-c-shorthand) - [Built-in Matcher Functions](#built-in-matcher-functions) - [Equivalence](#equivalence) - [Identity](#identity) - [Comparisons](#comparisons) - [Types/Classes](#typesclasses) - [Truthiness](#truthiness) - [Swift Assertions](#swift-assertions) - [Swift Error Handling](#swift-error-handling) - [Exceptions](#exceptions) - [Collection Membership](#collection-membership) - [Strings](#strings) - [Checking if all elements of a collection pass a condition](#checking-if-all-elements-of-a-collection-pass-a-condition) - [Verify collection count](#verify-collection-count) - [Verify a notification was posted](#verifying-a-notification-was-posted) - [Matching a value to any of a group of matchers](#matching-a-value-to-any-of-a-group-of-matchers) - [Writing Your Own Matchers](#writing-your-own-matchers) - [Lazy Evaluation](#lazy-evaluation) - [Type Checking via Swift Generics](#type-checking-via-swift-generics) - [Customizing Failure Messages](#customizing-failure-messages) - [Supporting Objective-C](#supporting-objective-c) - [Properly Handling `nil` in Objective-C Matchers](#properly-handling-nil-in-objective-c-matchers) - [Installing Nimble](#installing-nimble) - [Installing Nimble as a Submodule](#installing-nimble-as-a-submodule) - [Installing Nimble via CocoaPods](#installing-nimble-via-cocoapods) - [Using Nimble without XCTest](#using-nimble-without-xctest) # Some Background: Expressing Outcomes Using Assertions in XCTest Apple's Xcode includes the XCTest framework, which provides assertion macros to test whether code behaves properly. For example, to assert that `1 + 1 = 2`, XCTest has you write: ```swift // Swift XCTAssertEqual(1 + 1, 2, "expected one plus one to equal two") ``` Or, in Objective-C: ```objc // Objective-C XCTAssertEqual(1 + 1, 2, @"expected one plus one to equal two"); ``` XCTest assertions have a couple of drawbacks: 1. **Not enough macros.** There's no easy way to assert that a string contains a particular substring, or that a number is less than or equal to another. 2. **It's hard to write asynchronous tests.** XCTest forces you to write a lot of boilerplate code. Nimble addresses these concerns. # Nimble: Expectations Using `expect(...).to` Nimble allows you to express expectations using a natural, easily understood language: ```swift // Swift import Nimble expect(seagull.squawk).to(equal("Squee!")) ``` ```objc // Objective-C @import Nimble; expect(seagull.squawk).to(equal(@"Squee!")); ``` > The `expect` function autocompletes to include `file:` and `line:`, but these parameters are optional. Use the default values to have Xcode highlight the correct line when an expectation is not met. To perform the opposite expectation--to assert something is *not* equal--use `toNot` or `notTo`: ```swift // Swift import Nimble expect(seagull.squawk).toNot(equal("Oh, hello there!")) expect(seagull.squawk).notTo(equal("Oh, hello there!")) ``` ```objc // Objective-C @import Nimble; expect(seagull.squawk).toNot(equal(@"Oh, hello there!")); expect(seagull.squawk).notTo(equal(@"Oh, hello there!")); ``` ## Custom Failure Messages Would you like to add more information to the test's failure messages? Use the `description` optional argument to add your own text: ```swift // Swift expect(1 + 1).to(equal(3)) // failed - expected to equal <3>, got <2> expect(1 + 1).to(equal(3), description: "Make sure libKindergartenMath is loaded") // failed - Make sure libKindergartenMath is loaded // expected to equal <3>, got <2> ``` Or the *WithDescription version in Objective-C: ```objc // Objective-C @import Nimble; expect(@(1+1)).to(equal(@3)); // failed - expected to equal <3.0000>, got <2.0000> expect(@(1+1)).toWithDescription(equal(@3), @"Make sure libKindergartenMath is loaded"); // failed - Make sure libKindergartenMath is loaded // expected to equal <3.0000>, got <2.0000> ``` ## Type Checking Nimble makes sure you don't compare two types that don't match: ```swift // Swift // Does not compile: expect(1 + 1).to(equal("Squee!")) ``` > Nimble uses generics--only available in Swift--to ensure type correctness. That means type checking is not available when using Nimble in Objective-C. :sob: ## Operator Overloads Tired of so much typing? With Nimble, you can use overloaded operators like `==` for equivalence, or `>` for comparisons: ```swift // Swift // Passes if squawk does not equal "Hi!": expect(seagull.squawk) != "Hi!" // Passes if 10 is greater than 2: expect(10) > 2 ``` > Operator overloads are only available in Swift, so you won't be able to use this syntax in Objective-C. :broken_heart: ## Lazily Computed Values The `expect` function doesn't evaluate the value it's given until it's time to match. So Nimble can test whether an expression raises an exception once evaluated: ```swift // Swift // Note: Swift currently doesn't have exceptions. // Only Objective-C code can raise exceptions // that Nimble will catch. // (see https://github.com/Quick/Nimble/issues/220#issuecomment-172667064) let exception = NSException( name: NSInternalInconsistencyException, reason: "Not enough fish in the sea.", userInfo: ["something": "is fishy"]) expect { exception.raise() }.to(raiseException()) // Also, you can customize raiseException to be more specific expect { exception.raise() }.to(raiseException(named: NSInternalInconsistencyException)) expect { exception.raise() }.to(raiseException( named: NSInternalInconsistencyException, reason: "Not enough fish in the sea")) expect { exception.raise() }.to(raiseException( named: NSInternalInconsistencyException, reason: "Not enough fish in the sea", userInfo: ["something": "is fishy"])) ``` Objective-C works the same way, but you must use the `expectAction` macro when making an expectation on an expression that has no return value: ```objc // Objective-C NSException *exception = [NSException exceptionWithName:NSInternalInconsistencyException reason:@"Not enough fish in the sea." userInfo:nil]; expectAction(^{ [exception raise]; }).to(raiseException()); // Use the property-block syntax to be more specific. expectAction(^{ [exception raise]; }).to(raiseException().named(NSInternalInconsistencyException)); expectAction(^{ [exception raise]; }).to(raiseException(). named(NSInternalInconsistencyException). reason("Not enough fish in the sea")); expectAction(^{ [exception raise]; }).to(raiseException(). named(NSInternalInconsistencyException). reason("Not enough fish in the sea"). userInfo(@{@"something": @"is fishy"})); // You can also pass a block for custom matching of the raised exception expectAction(exception.raise()).to(raiseException().satisfyingBlock(^(NSException *exception) { expect(exception.name).to(beginWith(NSInternalInconsistencyException)); })); ``` ## C Primitives Some testing frameworks make it hard to test primitive C values. In Nimble, it just works: ```swift // Swift let actual: CInt = 1 let expectedValue: CInt = 1 expect(actual).to(equal(expectedValue)) ``` In fact, Nimble uses type inference, so you can write the above without explicitly specifying both types: ```swift // Swift expect(1 as CInt).to(equal(1)) ``` > In Objective-C, Nimble only supports Objective-C objects. To make expectations on primitive C values, wrap then in an object literal: ```objc expect(@(1 + 1)).to(equal(@2)); ``` ## Asynchronous Expectations In Nimble, it's easy to make expectations on values that are updated asynchronously. Just use `toEventually` or `toEventuallyNot`: ```swift // Swift dispatch_async(dispatch_get_main_queue()) { ocean.add("dolphins") ocean.add("whales") } expect(ocean).toEventually(contain("dolphins", "whales")) ``` ```objc // Objective-C dispatch_async(dispatch_get_main_queue(), ^{ [ocean add:@"dolphins"]; [ocean add:@"whales"]; }); expect(ocean).toEventually(contain(@"dolphins", @"whales")); ``` Note: toEventually triggers its polls on the main thread. Blocking the main thread will cause Nimble to stop the run loop. This can cause test pollution for whatever incomplete code that was running on the main thread. Blocking the main thread can be caused by blocking IO, calls to sleep(), deadlocks, and synchronous IPC. In the above example, `ocean` is constantly re-evaluated. If it ever contains dolphins and whales, the expectation passes. If `ocean` still doesn't contain them, even after being continuously re-evaluated for one whole second, the expectation fails. Sometimes it takes more than a second for a value to update. In those cases, use the `timeout` parameter: ```swift // Swift // Waits three seconds for ocean to contain "starfish": expect(ocean).toEventually(contain("starfish"), timeout: 3) // Evaluate someValue every 0.2 seconds repeatedly until it equals 100, or fails if it timeouts after 5.5 seconds. expect(someValue).toEventually(equal(100), timeout: 5.5, pollInterval: 0.2) ``` ```objc // Objective-C // Waits three seconds for ocean to contain "starfish": expect(ocean).withTimeout(3).toEventually(contain(@"starfish")); ``` You can also provide a callback by using the `waitUntil` function: ```swift // Swift waitUntil { done in // do some stuff that takes a while... NSThread.sleepForTimeInterval(0.5) done() } ``` ```objc // Objective-C waitUntil(^(void (^done)(void)){ // do some stuff that takes a while... [NSThread sleepForTimeInterval:0.5]; done(); }); ``` `waitUntil` also optionally takes a timeout parameter: ```swift // Swift waitUntil(timeout: 10) { done in // do some stuff that takes a while... NSThread.sleepForTimeInterval(1) done() } ``` ```objc // Objective-C waitUntilTimeout(10, ^(void (^done)(void)){ // do some stuff that takes a while... [NSThread sleepForTimeInterval:1]; done(); }); ``` Note: waitUntil triggers its timeout code on the main thread. Blocking the main thread will cause Nimble to stop the run loop to continue. This can cause test pollution for whatever incomplete code that was running on the main thread. Blocking the main thread can be caused by blocking IO, calls to sleep(), deadlocks, and synchronous IPC. In some cases (e.g. when running on slower machines) it can be useful to modify the default timeout and poll interval values. This can be done as follows: ```swift // Swift // Increase the global timeout to 5 seconds: Nimble.AsyncDefaults.Timeout = 5 // Slow the polling interval to 0.1 seconds: Nimble.AsyncDefaults.PollInterval = 0.1 ``` ## Objective-C Support Nimble has full support for Objective-C. However, there are two things to keep in mind when using Nimble in Objective-C: 1. All parameters passed to the `expect` function, as well as matcher functions like `equal`, must be Objective-C objects or can be converted into an `NSObject` equivalent: ```objc // Objective-C @import Nimble; expect(@(1 + 1)).to(equal(@2)); expect(@"Hello world").to(contain(@"world")); // Boxed as NSNumber * expect(2).to(equal(2)); expect(1.2).to(beLessThan(2.0)); expect(true).to(beTruthy()); // Boxed as NSString * expect("Hello world").to(equal("Hello world")); // Boxed as NSRange expect(NSMakeRange(1, 10)).to(equal(NSMakeRange(1, 10))); ``` 2. To make an expectation on an expression that does not return a value, such as `-[NSException raise]`, use `expectAction` instead of `expect`: ```objc // Objective-C expectAction(^{ [exception raise]; }).to(raiseException()); ``` The following types are currently converted to an `NSObject` type: - **C Numeric types** are converted to `NSNumber *` - `NSRange` is converted to `NSValue *` - `char *` is converted to `NSString *` For the following matchers: - `equal` - `beGreaterThan` - `beGreaterThanOrEqual` - `beLessThan` - `beLessThanOrEqual` - `beCloseTo` - `beTrue` - `beFalse` - `beTruthy` - `beFalsy` - `haveCount` If you would like to see more, [file an issue](https://github.com/Quick/Nimble/issues). ## Disabling Objective-C Shorthand Nimble provides a shorthand for expressing expectations using the `expect` function. To disable this shorthand in Objective-C, define the `NIMBLE_DISABLE_SHORT_SYNTAX` macro somewhere in your code before importing Nimble: ```objc #define NIMBLE_DISABLE_SHORT_SYNTAX 1 @import Nimble; NMB_expect(^{ return seagull.squawk; }, __FILE__, __LINE__).to(NMB_equal(@"Squee!")); ``` > Disabling the shorthand is useful if you're testing functions with names that conflict with Nimble functions, such as `expect` or `equal`. If that's not the case, there's no point in disabling the shorthand. # Built-in Matcher Functions Nimble includes a wide variety of matcher functions. ## Equivalence ```swift // Swift // Passes if actual is equivalent to expected: expect(actual).to(equal(expected)) expect(actual) == expected // Passes if actual is not equivalent to expected: expect(actual).toNot(equal(expected)) expect(actual) != expected ``` ```objc // Objective-C // Passes if actual is equivalent to expected: expect(actual).to(equal(expected)) // Passes if actual is not equivalent to expected: expect(actual).toNot(equal(expected)) ``` Values must be `Equatable`, `Comparable`, or subclasses of `NSObject`. `equal` will always fail when used to compare one or more `nil` values. ## Identity ```swift // Swift // Passes if actual has the same pointer address as expected: expect(actual).to(beIdenticalTo(expected)) expect(actual) === expected // Passes if actual does not have the same pointer address as expected: expect(actual).toNot(beIdenticalTo(expected)) expect(actual) !== expected ``` Its important to remember that `beIdenticalTo` only makes sense when comparing types with reference semantics, which have a notion of identity. In Swift, that means a `class`. This matcher will not work with types with value semantics such as `struct` or `enum`. If you need to compare two value types, you can either compare individual properties or if it makes sense to do so, make your type implement `Equatable` and use Nimble's equivalence matchers instead. ```objc // Objective-C // Passes if actual has the same pointer address as expected: expect(actual).to(beIdenticalTo(expected)); // Passes if actual does not have the same pointer address as expected: expect(actual).toNot(beIdenticalTo(expected)); ``` ## Comparisons ```swift // Swift expect(actual).to(beLessThan(expected)) expect(actual) < expected expect(actual).to(beLessThanOrEqualTo(expected)) expect(actual) <= expected expect(actual).to(beGreaterThan(expected)) expect(actual) > expected expect(actual).to(beGreaterThanOrEqualTo(expected)) expect(actual) >= expected ``` ```objc // Objective-C expect(actual).to(beLessThan(expected)); expect(actual).to(beLessThanOrEqualTo(expected)); expect(actual).to(beGreaterThan(expected)); expect(actual).to(beGreaterThanOrEqualTo(expected)); ``` > Values given to the comparison matchers above must implement `Comparable`. Because of how computers represent floating point numbers, assertions that two floating point numbers be equal will sometimes fail. To express that two numbers should be close to one another within a certain margin of error, use `beCloseTo`: ```swift // Swift expect(actual).to(beCloseTo(expected, within: delta)) ``` ```objc // Objective-C expect(actual).to(beCloseTo(expected).within(delta)); ``` For example, to assert that `10.01` is close to `10`, you can write: ```swift // Swift expect(10.01).to(beCloseTo(10, within: 0.1)) ``` ```objc // Objective-C expect(@(10.01)).to(beCloseTo(@10).within(0.1)); ``` There is also an operator shortcut available in Swift: ```swift // Swift expect(actual) ≈ expected expect(actual) ≈ (expected, delta) ``` (Type Option-x to get ≈ on a U.S. keyboard) The former version uses the default delta of 0.0001. Here is yet another way to do this: ```swift // Swift expect(actual) ≈ expected ± delta expect(actual) == expected ± delta ``` (Type Option-Shift-= to get ± on a U.S. keyboard) If you are comparing arrays of floating point numbers, you'll find the following useful: ```swift // Swift expect([0.0, 2.0]) ≈ [0.0001, 2.0001] expect([0.0, 2.0]).to(beCloseTo([0.1, 2.1], within: 0.1)) ``` > Values given to the `beCloseTo` matcher must be coercable into a `Double`. ## Types/Classes ```swift // Swift // Passes if instance is an instance of aClass: expect(instance).to(beAnInstanceOf(aClass)) // Passes if instance is an instance of aClass or any of its subclasses: expect(instance).to(beAKindOf(aClass)) ``` ```objc // Objective-C // Passes if instance is an instance of aClass: expect(instance).to(beAnInstanceOf(aClass)); // Passes if instance is an instance of aClass or any of its subclasses: expect(instance).to(beAKindOf(aClass)); ``` > Instances must be Objective-C objects: subclasses of `NSObject`, or Swift objects bridged to Objective-C with the `@objc` prefix. For example, to assert that `dolphin` is a kind of `Mammal`: ```swift // Swift expect(dolphin).to(beAKindOf(Mammal)) ``` ```objc // Objective-C expect(dolphin).to(beAKindOf([Mammal class])); ``` > `beAnInstanceOf` uses the `-[NSObject isMemberOfClass:]` method to test membership. `beAKindOf` uses `-[NSObject isKindOfClass:]`. ## Truthiness ```swift // Passes if actual is not nil, true, or an object with a boolean value of true: expect(actual).to(beTruthy()) // Passes if actual is only true (not nil or an object conforming to Boolean true): expect(actual).to(beTrue()) // Passes if actual is nil, false, or an object with a boolean value of false: expect(actual).to(beFalsy()) // Passes if actual is only false (not nil or an object conforming to Boolean false): expect(actual).to(beFalse()) // Passes if actual is nil: expect(actual).to(beNil()) ``` ```objc // Objective-C // Passes if actual is not nil, true, or an object with a boolean value of true: expect(actual).to(beTruthy()); // Passes if actual is only true (not nil or an object conforming to Boolean true): expect(actual).to(beTrue()); // Passes if actual is nil, false, or an object with a boolean value of false: expect(actual).to(beFalsy()); // Passes if actual is only false (not nil or an object conforming to Boolean false): expect(actual).to(beFalse()); // Passes if actual is nil: expect(actual).to(beNil()); ``` ## Swift Assertions If you're using Swift, you can use the `throwAssertion` matcher to check if an assertion is thrown (e.g. `fatalError()`). This is made possible by [@mattgallagher](https://github.com/mattgallagher)'s [CwlPreconditionTesting](https://github.com/mattgallagher/CwlPreconditionTesting) library. ```swift // Swift // Passes if somethingThatThrows() throws an assertion, such as calling fatalError() or precondition fails: expect { () -> Void in fatalError() }.to(throwAssertion()) expect { precondition(false) }.to(throwAssertion()) // Passes if throwing a NSError is not equal to throwing an assertion: expect { throw NSError(domain: "test", code: 0, userInfo: nil) }.toNot(throwAssertion()) // Passes if the post assertion code is not run: var reachedPoint1 = false var reachedPoint2 = false expect { reachedPoint1 = true precondition(false, "condition message") reachedPoint2 = true }.to(throwAssertion()) expect(reachedPoint1) == true expect(reachedPoint2) == false ``` Notes: * This feature is only available in Swift. * It is only supported for `x86_64` binaries, meaning _you cannot run this matcher on iOS devices, only simulators_. * The tvOS simulator is supported, but using a different mechanism, requiring you to turn off the `Debug executable` scheme setting for your tvOS scheme's Test configuration. ## Swift Error Handling If you're using Swift 2.0+, you can use the `throwError` matcher to check if an error is thrown. ```swift // Swift // Passes if somethingThatThrows() throws an ErrorProtocol: expect{ try somethingThatThrows() }.to(throwError()) // Passes if somethingThatThrows() throws an error with a given domain: expect{ try somethingThatThrows() }.to(throwError { (error: ErrorProtocol) in expect(error._domain).to(equal(NSCocoaErrorDomain)) }) // Passes if somethingThatThrows() throws an error with a given case: expect{ try somethingThatThrows() }.to(throwError(NSCocoaError.PropertyListReadCorruptError)) // Passes if somethingThatThrows() throws an error with a given type: expect{ try somethingThatThrows() }.to(throwError(errorType: NimbleError.self)) ``` If you are working directly with `ErrorProtocol` values, as is sometimes the case when using `Result` or `Promise` types, you can use the `matchError` matcher to check if the error is the same error is is supposed to be, without requiring explicit casting. ```swift // Swift let actual: ErrorProtocol = … // Passes if actual contains any error value from the NimbleErrorEnum type: expect(actual).to(matchError(NimbleErrorEnum)) // Passes if actual contains the Timeout value from the NimbleErrorEnum type: expect(actual).to(matchError(NimbleErrorEnum.Timeout)) // Passes if actual contains an NSError equal to the given one: expect(actual).to(matchError(NSError(domain: "err", code: 123, userInfo: nil))) ``` Note: This feature is only available in Swift. ## Exceptions ```swift // Swift // Passes if actual, when evaluated, raises an exception: expect(actual).to(raiseException()) // Passes if actual raises an exception with the given name: expect(actual).to(raiseException(named: name)) // Passes if actual raises an exception with the given name and reason: expect(actual).to(raiseException(named: name, reason: reason)) // Passes if actual raises an exception and it passes expectations in the block // (in this case, if name begins with 'a r') expect { exception.raise() }.to(raiseException { (exception: NSException) in expect(exception.name).to(beginWith("a r")) }) ``` ```objc // Objective-C // Passes if actual, when evaluated, raises an exception: expect(actual).to(raiseException()) // Passes if actual raises an exception with the given name expect(actual).to(raiseException().named(name)) // Passes if actual raises an exception with the given name and reason: expect(actual).to(raiseException().named(name).reason(reason)) // Passes if actual raises an exception and it passes expectations in the block // (in this case, if name begins with 'a r') expect(actual).to(raiseException().satisfyingBlock(^(NSException *exception) { expect(exception.name).to(beginWith(@"a r")); })); ``` Note: Swift currently doesn't have exceptions (see [#220](https://github.com/Quick/Nimble/issues/220#issuecomment-172667064)). Only Objective-C code can raise exceptions that Nimble will catch. ## Collection Membership ```swift // Swift // Passes if all of the expected values are members of actual: expect(actual).to(contain(expected...)) // Passes if actual is an empty collection (it contains no elements): expect(actual).to(beEmpty()) ``` ```objc // Objective-C // Passes if expected is a member of actual: expect(actual).to(contain(expected)); // Passes if actual is an empty collection (it contains no elements): expect(actual).to(beEmpty()); ``` > In Swift `contain` takes any number of arguments. The expectation passes if all of them are members of the collection. In Objective-C, `contain` only takes one argument [for now](https://github.com/Quick/Nimble/issues/27). For example, to assert that a list of sea creature names contains "dolphin" and "starfish": ```swift // Swift expect(["whale", "dolphin", "starfish"]).to(contain("dolphin", "starfish")) ``` ```objc // Objective-C expect(@[@"whale", @"dolphin", @"starfish"]).to(contain(@"dolphin")); expect(@[@"whale", @"dolphin", @"starfish"]).to(contain(@"starfish")); ``` > `contain` and `beEmpty` expect collections to be instances of `NSArray`, `NSSet`, or a Swift collection composed of `Equatable` elements. To test whether a set of elements is present at the beginning or end of an ordered collection, use `beginWith` and `endWith`: ```swift // Swift // Passes if the elements in expected appear at the beginning of actual: expect(actual).to(beginWith(expected...)) // Passes if the the elements in expected come at the end of actual: expect(actual).to(endWith(expected...)) ``` ```objc // Objective-C // Passes if the elements in expected appear at the beginning of actual: expect(actual).to(beginWith(expected)); // Passes if the the elements in expected come at the end of actual: expect(actual).to(endWith(expected)); ``` > `beginWith` and `endWith` expect collections to be instances of `NSArray`, or ordered Swift collections composed of `Equatable` elements. Like `contain`, in Objective-C `beginWith` and `endWith` only support a single argument [for now](https://github.com/Quick/Nimble/issues/27). ## Strings ```swift // Swift // Passes if actual contains substring expected: expect(actual).to(contain(expected)) // Passes if actual begins with substring: expect(actual).to(beginWith(expected)) // Passes if actual ends with substring: expect(actual).to(endWith(expected)) // Passes if actual is an empty string, "": expect(actual).to(beEmpty()) // Passes if actual matches the regular expression defined in expected: expect(actual).to(match(expected)) ``` ```objc // Objective-C // Passes if actual contains substring expected: expect(actual).to(contain(expected)); // Passes if actual begins with substring: expect(actual).to(beginWith(expected)); // Passes if actual ends with substring: expect(actual).to(endWith(expected)); // Passes if actual is an empty string, "": expect(actual).to(beEmpty()); // Passes if actual matches the regular expression defined in expected: expect(actual).to(match(expected)) ``` ## Checking if all elements of a collection pass a condition ```swift // Swift // with a custom function: expect([1,2,3,4]).to(allPass({$0 < 5})) // with another matcher: expect([1,2,3,4]).to(allPass(beLessThan(5))) ``` ```objc // Objective-C expect(@[@1, @2, @3,@4]).to(allPass(beLessThan(@5))); ``` For Swift the actual value has to be a Sequence, e.g. an array, a set or a custom seqence type. For Objective-C the actual value has to be a NSFastEnumeration, e.g. NSArray and NSSet, of NSObjects and only the variant which uses another matcher is available here. ## Verify collection count ```swift // Swift // passes if actual collection's count is equal to expected expect(actual).to(haveCount(expected)) // passes if actual collection's count is not equal to expected expect(actual).notTo(haveCount(expected)) ``` ```objc // Objective-C // passes if actual collection's count is equal to expected expect(actual).to(haveCount(expected)) // passes if actual collection's count is not equal to expected expect(actual).notTo(haveCount(expected)) ``` For Swift the actual value must be a `Collection` such as array, dictionary or set. For Objective-C the actual value has to be one of the following classes `NSArray`, `NSDictionary`, `NSSet`, `NSHashTable` or one of their subclasses. ## Foundation ### Verifying a Notification was posted ```swift // Swift let testNotification = Notification(name: "Foo", object: nil) // passes if the closure in expect { ... } posts a notification to the default // notification center. expect { NotificationCenter.default.postNotification(testNotification) }.to(postNotifications(equal([testNotification])) // passes if the closure in expect { ... } posts a notification to a given // notification center let notificationCenter = NotificationCenter() expect { notificationCenter.postNotification(testNotification) }.to(postNotifications(equal([testNotification]), fromNotificationCenter: notificationCenter)) ``` > This matcher is only available in Swift. ## Matching a value to any of a group of matchers ```swift // passes if actual is either less than 10 or greater than 20 expect(actual).to(satisfyAnyOf(beLessThan(10), beGreaterThan(20))) // can include any number of matchers -- the following will pass // **be careful** -- too many matchers can be the sign of an unfocused test expect(6).to(satisfyAnyOf(equal(2), equal(3), equal(4), equal(5), equal(6), equal(7))) // in Swift you also have the option to use the || operator to achieve a similar function expect(82).to(beLessThan(50) || beGreaterThan(80)) ``` ```objc // passes if actual is either less than 10 or greater than 20 expect(actual).to(satisfyAnyOf(beLessThan(@10), beGreaterThan(@20))) // can include any number of matchers -- the following will pass // **be careful** -- too many matchers can be the sign of an unfocused test expect(@6).to(satisfyAnyOf(equal(@2), equal(@3), equal(@4), equal(@5), equal(@6), equal(@7))) ``` Note: This matcher allows you to chain any number of matchers together. This provides flexibility, but if you find yourself chaining many matchers together in one test, consider whether you could instead refactor that single test into multiple, more precisely focused tests for better coverage. # Writing Your Own Matchers In Nimble, matchers are Swift functions that take an expected value and return a `MatcherFunc` closure. Take `equal`, for example: ```swift // Swift public func equal(expectedValue: T?) -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "equal <\(expectedValue)>" if let actualValue = try actualExpression.evaluate() { return actualValue == expectedValue } else { return false } } } ``` The return value of a `MatcherFunc` closure is a `Bool` that indicates whether the actual value matches the expectation: `true` if it does, or `false` if it doesn't. > The actual `equal` matcher function does not match when either `actual` or `expected` are nil; the example above has been edited for brevity. Since matchers are just Swift functions, you can define them anywhere: at the top of your test file, in a file shared by all of your tests, or in an Xcode project you distribute to others. > If you write a matcher you think everyone can use, consider adding it to Nimble's built-in set of matchers by sending a pull request! Or distribute it yourself via GitHub. For examples of how to write your own matchers, just check out the [`Matchers` directory](https://github.com/Quick/Nimble/tree/master/Sources/Nimble/Matchers) to see how Nimble's built-in set of matchers are implemented. You can also check out the tips below. ## Lazy Evaluation `actualExpression` is a lazy, memoized closure around the value provided to the `expect` function. The expression can either be a closure or a value directly passed to `expect(...)`. In order to determine whether that value matches, custom matchers should call `actualExpression.evaluate()`: ```swift // Swift public func beNil() -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be nil" return actualExpression.evaluate() == nil } } ``` In the above example, `actualExpression` is not `nil`--it is a closure that returns a value. The value it returns, which is accessed via the `evaluate()` method, may be `nil`. If that value is `nil`, the `beNil` matcher function returns `true`, indicating that the expectation passed. Use `expression.isClosure` to determine if the expression will be invoking a closure to produce its value. ## Type Checking via Swift Generics Using Swift's generics, matchers can constrain the type of the actual value passed to the `expect` function by modifying the return type. For example, the following matcher, `haveDescription`, only accepts actual values that implement the `Printable` protocol. It checks their `description` against the one provided to the matcher function, and passes if they are the same: ```swift // Swift public func haveDescription(description: String) -> MatcherFunc { return MatcherFunc { actual, failureMessage in return actual.evaluate().description == description } } ``` ## Customizing Failure Messages By default, Nimble outputs the following failure message when an expectation fails: ``` expected to match, got <\(actual)> ``` You can customize this message by modifying the `failureMessage` struct from within your `MatcherFunc` closure. To change the verb "match" to something else, update the `postfixMessage` property: ```swift // Swift // Outputs: expected to be under the sea, got <\(actual)> failureMessage.postfixMessage = "be under the sea" ``` You can change how the `actual` value is displayed by updating `failureMessage.actualValue`. Or, to remove it altogether, set it to `nil`: ```swift // Swift // Outputs: expected to be under the sea failureMessage.actualValue = nil failureMessage.postfixMessage = "be under the sea" ``` ## Supporting Objective-C To use a custom matcher written in Swift from Objective-C, you'll have to extend the `NMBObjCMatcher` class, adding a new class method for your custom matcher. The example below defines the class method `+[NMBObjCMatcher beNilMatcher]`: ```swift // Swift extension NMBObjCMatcher { public class func beNilMatcher() -> NMBObjCMatcher { return NMBObjCMatcher { actualBlock, failureMessage, location in let block = ({ actualBlock() as NSObject? }) let expr = Expression(expression: block, location: location) return beNil().matches(expr, failureMessage: failureMessage) } } } ``` The above allows you to use the matcher from Objective-C: ```objc // Objective-C expect(actual).to([NMBObjCMatcher beNilMatcher]()); ``` To make the syntax easier to use, define a C function that calls the class method: ```objc // Objective-C FOUNDATION_EXPORT id beNil() { return [NMBObjCMatcher beNilMatcher]; } ``` ### Properly Handling `nil` in Objective-C Matchers When supporting Objective-C, make sure you handle `nil` appropriately. Like [Cedar](https://github.com/pivotal/cedar/issues/100), **most matchers do not match with nil**. This is to bring prevent test writers from being surprised by `nil` values where they did not expect them. Nimble provides the `beNil` matcher function for test writer that want to make expectations on `nil` objects: ```objc // Objective-C expect(nil).to(equal(nil)); // fails expect(nil).to(beNil()); // passes ``` If your matcher does not want to match with nil, you use `NonNilMatcherFunc` and the `canMatchNil` constructor on `NMBObjCMatcher`. Using both types will automatically generate expected value failure messages when they're nil. ```swift public func beginWith(startingElement: T) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "begin with <\(startingElement)>" if let actualValue = actualExpression.evaluate() { var actualGenerator = actualValue.makeIterator() return actualGenerator.next() == startingElement } return false } } extension NMBObjCMatcher { public class func beginWithMatcher(expected: AnyObject) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let actual = actualExpression.evaluate() let expr = actualExpression.cast { $0 as? NMBOrderedCollection } return beginWith(expected).matches(expr, failureMessage: failureMessage) } } } ``` # Installing Nimble > Nimble can be used on its own, or in conjunction with its sister project, [Quick](https://github.com/Quick/Quick). To install both Quick and Nimble, follow [the installation instructions in the Quick Documentation](https://github.com/Quick/Quick/blob/master/Documentation/en-us/InstallingQuick.md). Nimble can currently be installed in one of two ways: using CocoaPods, or with git submodules. ## Installing Nimble as a Submodule To use Nimble as a submodule to test your macOS, iOS or tvOS applications, follow these 4 easy steps: 1. Clone the Nimble repository 2. Add Nimble.xcodeproj to the Xcode workspace for your project 3. Link Nimble.framework to your test target 4. Start writing expectations! For more detailed instructions on each of these steps, read [How to Install Quick](https://github.com/Quick/Quick#how-to-install-quick). Ignore the steps involving adding Quick to your project in order to install just Nimble. ## Installing Nimble via CocoaPods To use Nimble in CocoaPods to test your macOS, iOS or tvOS applications, add Nimble to your podfile and add the ```use_frameworks!``` line to enable Swift support for CocoaPods. ```ruby platform :ios, '8.0' source 'https://github.com/CocoaPods/Specs.git' # Whatever pods you need for your app go here target 'YOUR_APP_NAME_HERE_Tests', :exclusive => true do use_frameworks! pod 'Nimble', '~> 5.0.0' end ``` Finally run `pod install`. ## Using Nimble without XCTest Nimble is integrated with XCTest to allow it work well when used in Xcode test bundles, however it can also be used in a standalone app. After installing Nimble using one of the above methods, there are two additional steps required to make this work. 1. Create a custom assertion handler and assign an instance of it to the global `NimbleAssertionHandler` variable. For example: ```swift class MyAssertionHandler : AssertionHandler { func assert(assertion: Bool, message: FailureMessage, location: SourceLocation) { if (!assertion) { print("Expectation failed: \(message.stringValue)") } } } ``` ```swift // Somewhere before you use any assertions NimbleAssertionHandler = MyAssertionHandler() ``` 2. Add a post-build action to fix an issue with the Swift XCTest support library being unnecessarily copied into your app * Edit your scheme in Xcode, and navigate to Build -> Post-actions * Click the "+" icon and select "New Run Script Action" * Open the "Provide build settings from" dropdown and select your target * Enter the following script contents: ``` rm "${SWIFT_STDLIB_TOOL_DESTINATION_DIR}/libswiftXCTest.dylib" ``` You can now use Nimble assertions in your code and handle failures as you see fit. ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlCatchException/CwlCatchException/CwlCatchException.h ================================================ // // CwlCatchException.h // CwlCatchException // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // #import //! Project version number for CwlCatchException. FOUNDATION_EXPORT double CwlCatchExceptionVersionNumber; //! Project version string for CwlCatchException. FOUNDATION_EXPORT const unsigned char CwlCatchExceptionVersionString[]; __attribute__((visibility("hidden"))) NSException* __nullable catchExceptionOfKind(Class __nonnull type, __attribute__((noescape)) void (^ __nonnull inBlock)()); ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlCatchException/CwlCatchException/CwlCatchException.m ================================================ // // CwlCatchException.m // CwlAssertionTesting // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // #import "CwlCatchException.h" __attribute__((visibility("hidden"))) NSException* catchExceptionOfKind(Class __nonnull type, __attribute__((noescape)) void (^ __nonnull inBlock)()) { @try { inBlock(); } @catch (NSException *exception) { if ([exception isKindOfClass:type]) { return exception; } else { @throw; } } return nil; } ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlCatchException/CwlCatchException/CwlCatchException.swift ================================================ // // CwlCatchException.swift // CwlAssertionTesting // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // import Foundation // We can't simply cast to Self? in the catchInBlock method so we need this generic function wrapper to do the conversion for us. Mildly annoying. private func catchReturnTypeConverter(_ type: T.Type, block: () -> Void) -> T? { return catchExceptionOfKind(type, block) as? T } extension NSException { public static func catchException(in block: () -> Void) -> Self? { return catchReturnTypeConverter(self, block: block) } } ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlBadInstructionException.swift ================================================ // // CwlBadInstructionException.swift // CwlPreconditionTesting // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // import Foundation private func raiseBadInstructionException() { BadInstructionException().raise() } /// A simple NSException subclass. It's not required to subclass NSException (since the exception type is represented in the name) but this helps for identifying the exception through runtime type. @objc public class BadInstructionException: NSException { static var name: String = "com.cocoawithlove.BadInstruction" init() { super.init(name: NSExceptionName(rawValue: BadInstructionException.name), reason: nil, userInfo: nil) } required public init?(coder aDecoder: NSCoder) { super.init(coder: aDecoder) } /// An Objective-C callable function, invoked from the `mach_exc_server` callback function `catch_mach_exception_raise_state` to push the `raiseBadInstructionException` function onto the stack. public class func catch_mach_exception_raise_state(_ exception_port: mach_port_t, exception: exception_type_t, code: UnsafePointer, codeCnt: mach_msg_type_number_t, flavor: UnsafeMutablePointer, old_state: UnsafePointer, old_stateCnt: mach_msg_type_number_t, new_state: thread_state_t, new_stateCnt: UnsafeMutablePointer) -> kern_return_t { #if arch(x86_64) // Make sure we've been given enough memory if old_stateCnt != x86_THREAD_STATE64_COUNT || new_stateCnt.pointee < x86_THREAD_STATE64_COUNT { return KERN_INVALID_ARGUMENT } // Read the old thread state var state = old_state.withMemoryRebound(to: x86_thread_state64_t.self, capacity: 1) { return $0.pointee } // 1. Decrement the stack pointer state.__rsp -= __uint64_t(MemoryLayout.size) // 2. Save the old Instruction Pointer to the stack. if let pointer = UnsafeMutablePointer<__uint64_t>(bitPattern: UInt(state.__rsp)) { pointer.pointee = state.__rip } else { return KERN_INVALID_ARGUMENT } // 3. Set the Instruction Pointer to the new function's address var f: @convention(c) () -> Void = raiseBadInstructionException withUnsafePointer(to: &f) { state.__rip = $0.withMemoryRebound(to: __uint64_t.self, capacity: 1) { return $0.pointee } } // Write the new thread state new_state.withMemoryRebound(to: x86_thread_state64_t.self, capacity: 1) { $0.pointee = state } new_stateCnt.pointee = x86_THREAD_STATE64_COUNT return KERN_SUCCESS #else fatalError("Unavailable for this CPU architecture") #endif } } ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlCatchBadInstruction.h ================================================ // // CwlCatchBadInstruction.h // CwlPreconditionTesting // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // #if defined(__x86_64__) #import #import NS_ASSUME_NONNULL_BEGIN // The request_mach_exception_raise_t struct is passed to mach_msg which assumes its exact layout. To avoid problems with different layouts, we keep the definition in C rather than Swift. typedef struct { mach_msg_header_t Head; /* start of the kernel processed data */ mach_msg_body_t msgh_body; mach_msg_port_descriptor_t thread; mach_msg_port_descriptor_t task; /* end of the kernel processed data */ NDR_record_t NDR; exception_type_t exception; mach_msg_type_number_t codeCnt; int64_t code[2]; int flavor; mach_msg_type_number_t old_stateCnt; natural_t old_state[224]; } request_mach_exception_raise_t; // The reply_mach_exception_raise_state_t struct is passed to mach_msg which assumes its exact layout. To avoid problems with different layouts, we keep the definition in C rather than Swift. typedef struct { mach_msg_header_t Head; NDR_record_t NDR; kern_return_t RetCode; int flavor; mach_msg_type_number_t new_stateCnt; natural_t new_state[224]; } reply_mach_exception_raise_state_t; extern boolean_t mach_exc_server(mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP); NS_ASSUME_NONNULL_END #endif ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlCatchBadInstruction.m ================================================ // // CwlCatchBadInstruction.m // CwlPreconditionTesting // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // #if defined(__x86_64__) #import "CwlCatchBadInstruction.h" // Assuming the "PRODUCT_NAME" macro is defined, this will create the name of the Swift generated header file #define STRINGIZE_NO_EXPANSION(A) #A #define STRINGIZE_WITH_EXPANSION(A) STRINGIZE_NO_EXPANSION(A) #define SWIFT_INCLUDE STRINGIZE_WITH_EXPANSION(PRODUCT_NAME-Swift.h) // Include the Swift generated header file #import SWIFT_INCLUDE /// A basic function that receives callbacks from mach_exc_server and relays them to the Swift implemented BadInstructionException.catch_mach_exception_raise_state. kern_return_t catch_mach_exception_raise_state(mach_port_t exception_port, exception_type_t exception, const mach_exception_data_t code, mach_msg_type_number_t codeCnt, int *flavor, const thread_state_t old_state, mach_msg_type_number_t old_stateCnt, thread_state_t new_state, mach_msg_type_number_t *new_stateCnt) { return [BadInstructionException catch_mach_exception_raise_state:exception_port exception:exception code:code codeCnt:codeCnt flavor:flavor old_state:old_state old_stateCnt:old_stateCnt new_state:new_state new_stateCnt:new_stateCnt]; } // The mach port should be configured so that this function is never used. kern_return_t catch_mach_exception_raise(mach_port_t exception_port, mach_port_t thread, mach_port_t task, exception_type_t exception, mach_exception_data_t code, mach_msg_type_number_t codeCnt) { assert(false); return KERN_FAILURE; } // The mach port should be configured so that this function is never used. kern_return_t catch_mach_exception_raise_state_identity(mach_port_t exception_port, mach_port_t thread, mach_port_t task, exception_type_t exception, mach_exception_data_t code, mach_msg_type_number_t codeCnt, int *flavor, thread_state_t old_state, mach_msg_type_number_t old_stateCnt, thread_state_t new_state, mach_msg_type_number_t *new_stateCnt) { assert(false); return KERN_FAILURE; } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlCatchBadInstruction.swift ================================================ // // CwlCatchBadInstruction.swift // CwlPreconditionTesting // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // import Foundation #if arch(x86_64) private enum PthreadError: Error { case code(Int32) } private enum MachExcServer: Error { case code(kern_return_t) } /// A quick function for converting Mach error results into Swift errors private func kernCheck(_ f: () -> Int32) throws { let r = f() guard r == KERN_SUCCESS else { throw NSError(domain: NSMachErrorDomain, code: Int(r), userInfo: nil) } } extension execTypesCountTuple { mutating func pointer(in block: (UnsafeMutablePointer) -> R) -> R { return withUnsafeMutablePointer(to: &self) { p -> R in return p.withMemoryRebound(to: T.self, capacity: EXC_TYPES_COUNT) { ptr -> R in return block(ptr) } } } } extension request_mach_exception_raise_t { mutating func withMsgHeaderPointer(in block: (UnsafeMutablePointer) -> R) -> R { return withUnsafeMutablePointer(to: &self) { p -> R in return p.withMemoryRebound(to: mach_msg_header_t.self, capacity: 1) { ptr -> R in return block(ptr) } } } } extension reply_mach_exception_raise_state_t { mutating func withMsgHeaderPointer(in block: (UnsafeMutablePointer) -> R) -> R { return withUnsafeMutablePointer(to: &self) { p -> R in return p.withMemoryRebound(to: mach_msg_header_t.self, capacity: 1) { ptr -> R in return block(ptr) } } } } /// A structure used to store context associated with the Mach message port private struct MachContext { var masks = execTypesCountTuple() var count: mach_msg_type_number_t = 0 var ports = execTypesCountTuple() var behaviors = execTypesCountTuple() var flavors = execTypesCountTuple() var currentExceptionPort: mach_port_t = 0 var handlerThread: pthread_t? = nil mutating func withUnsafeMutablePointers(in block: (UnsafeMutablePointer, UnsafeMutablePointer, UnsafeMutablePointer, UnsafeMutablePointer) -> R) -> R { return masks.pointer { masksPtr in return ports.pointer { portsPtr in return behaviors.pointer { behaviorsPtr in return flavors.pointer { flavorsPtr in return block(masksPtr, portsPtr, behaviorsPtr, flavorsPtr) } } } } } } /// A function for receiving mach messages and parsing the first with mach_exc_server (and if any others are received, throwing them away). private func machMessageHandler(_ arg: UnsafeMutableRawPointer) -> UnsafeMutableRawPointer? { let context = arg.assumingMemoryBound(to: MachContext.self).pointee var request = request_mach_exception_raise_t() var reply = reply_mach_exception_raise_state_t() var handledfirstException = false repeat { do { // Request the next mach message from the port request.Head.msgh_local_port = context.currentExceptionPort request.Head.msgh_size = UInt32(MemoryLayout.size) try kernCheck { request.withMsgHeaderPointer { requestPtr in mach_msg(requestPtr, MACH_RCV_MSG | MACH_RCV_INTERRUPT, 0, request.Head.msgh_size, context.currentExceptionPort, 0, UInt32(MACH_PORT_NULL)) } } // Prepare the reply structure reply.Head.msgh_bits = MACH_MSGH_BITS(MACH_MSGH_BITS_REMOTE(request.Head.msgh_bits), 0) reply.Head.msgh_local_port = UInt32(MACH_PORT_NULL) reply.Head.msgh_remote_port = request.Head.msgh_remote_port reply.Head.msgh_size = UInt32(MemoryLayout.size) reply.NDR = NDR_record if !handledfirstException { // Use the MiG generated server to invoke our handler for the request and fill in the rest of the reply structure guard request.withMsgHeaderPointer(in: { requestPtr in reply.withMsgHeaderPointer { replyPtr in mach_exc_server(requestPtr, replyPtr) } }) != 0 else { throw MachExcServer.code(reply.RetCode) } handledfirstException = true } else { // If multiple fatal errors occur, don't handle subsquent errors (let the program crash) reply.RetCode = KERN_FAILURE } // Send the reply try kernCheck { reply.withMsgHeaderPointer { replyPtr in mach_msg(replyPtr, MACH_SEND_MSG, reply.Head.msgh_size, 0, UInt32(MACH_PORT_NULL), 0, UInt32(MACH_PORT_NULL)) } } } catch let error as NSError where (error.domain == NSMachErrorDomain && (error.code == Int(MACH_RCV_PORT_CHANGED) || error.code == Int(MACH_RCV_INVALID_NAME))) { // Port was already closed before we started or closed while we were listening. // This means the controlling thread shut down. return nil } catch { // Should never be reached but this is testing code, don't try to recover, just abort fatalError("Mach message error: \(error)") } } while true } /// Run the provided block. If a mach "BAD_INSTRUCTION" exception is raised, catch it and return a BadInstructionException (which captures stack information about the throw site, if desired). Otherwise return nil. /// NOTE: This function is only intended for use in test harnesses – use in a distributed build is almost certainly a bad choice. If a "BAD_INSTRUCTION" exception is raised, the block will be exited before completion via Objective-C exception. The risks associated with an Objective-C exception apply here: most Swift/Objective-C functions are *not* exception-safe. Memory may be leaked and the program will not necessarily be left in a safe state. /// - parameter block: a function without parameters that will be run /// - returns: if an EXC_BAD_INSTRUCTION is raised during the execution of `block` then a BadInstructionException will be returned, otherwise `nil`. public func catchBadInstruction(in block: () -> Void) -> BadInstructionException? { var context = MachContext() var result: BadInstructionException? = nil do { var handlerThread: pthread_t? = nil defer { // 8. Wait for the thread to terminate *if* we actually made it to the creation point // The mach port should be destroyed *before* calling pthread_join to avoid a deadlock. if handlerThread != nil { pthread_join(handlerThread!, nil) } } try kernCheck { // 1. Create the mach port mach_port_allocate(mach_task_self_, MACH_PORT_RIGHT_RECEIVE, &context.currentExceptionPort) } defer { // 7. Cleanup the mach port mach_port_destroy(mach_task_self_, context.currentExceptionPort) } try kernCheck { // 2. Configure the mach port mach_port_insert_right(mach_task_self_, context.currentExceptionPort, context.currentExceptionPort, MACH_MSG_TYPE_MAKE_SEND) } try kernCheck { context.withUnsafeMutablePointers { masksPtr, portsPtr, behaviorsPtr, flavorsPtr in // 3. Apply the mach port as the handler for this thread thread_swap_exception_ports(mach_thread_self(), EXC_MASK_BAD_INSTRUCTION, context.currentExceptionPort, Int32(bitPattern: UInt32(EXCEPTION_STATE) | MACH_EXCEPTION_CODES), x86_THREAD_STATE64, masksPtr, &context.count, portsPtr, behaviorsPtr, flavorsPtr) } } defer { context.withUnsafeMutablePointers { masksPtr, portsPtr, behaviorsPtr, flavorsPtr in // 6. Unapply the mach port _ = thread_swap_exception_ports(mach_thread_self(), EXC_MASK_BAD_INSTRUCTION, 0, EXCEPTION_DEFAULT, THREAD_STATE_NONE, masksPtr, &context.count, portsPtr, behaviorsPtr, flavorsPtr) } } try withUnsafeMutablePointer(to: &context) { c throws in // 4. Create the thread let e = pthread_create(&handlerThread, nil, machMessageHandler, c) guard e == 0 else { throw PthreadError.code(e) } // 5. Run the block result = BadInstructionException.catchException(in: block) } } catch { // Should never be reached but this is testing code, don't try to recover, just abort fatalError("Mach port error: \(error)") } return result } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlDarwinDefinitions.swift ================================================ // // CwlDarwinDefinitions.swift // CwlPreconditionTesting // // Created by Matt Gallagher on 2016/01/10. // Copyright © 2016 Matt Gallagher ( http://cocoawithlove.com ). All rights reserved. // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice appear in all copies. // // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY // SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR // IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. // import Darwin #if arch(x86_64) // From /usr/include/mach/port.h // #define MACH_PORT_RIGHT_RECEIVE ((mach_port_right_t) 1) let MACH_PORT_RIGHT_RECEIVE: mach_port_right_t = 1 // From /usr/include/mach/message.h // #define MACH_MSG_TYPE_MAKE_SEND 20 /* Must hold receive right */ // #define MACH_MSGH_BITS_REMOTE(bits) \ // ((bits) & MACH_MSGH_BITS_REMOTE_MASK) // #define MACH_MSGH_BITS(remote, local) /* legacy */ \ // ((remote) | ((local) << 8)) let MACH_MSG_TYPE_MAKE_SEND: UInt32 = 20 func MACH_MSGH_BITS_REMOTE(_ bits: UInt32) -> UInt32 { return bits & UInt32(MACH_MSGH_BITS_REMOTE_MASK) } func MACH_MSGH_BITS(_ remote: UInt32, _ local: UInt32) -> UInt32 { return ((remote) | ((local) << 8)) } // From /usr/include/mach/exception_types.h // #define EXC_BAD_INSTRUCTION 2 /* Instruction failed */ // #define EXC_MASK_BAD_INSTRUCTION (1 << EXC_BAD_INSTRUCTION) // #define EXCEPTION_DEFAULT 1 let EXC_BAD_INSTRUCTION: UInt32 = 2 let EXC_MASK_BAD_INSTRUCTION: UInt32 = 1 << EXC_BAD_INSTRUCTION let EXCEPTION_DEFAULT: Int32 = 1 // From /usr/include/mach/i386/thread_status.h // #define THREAD_STATE_NONE 13 // #define x86_THREAD_STATE64_COUNT ((mach_msg_type_number_t) \ // ( sizeof (x86_thread_state64_t) / sizeof (int) )) let THREAD_STATE_NONE: Int32 = 13 let x86_THREAD_STATE64_COUNT = UInt32(MemoryLayout.size / MemoryLayout.size) let EXC_TYPES_COUNT = 14 struct execTypesCountTuple { // From /usr/include/mach/i386/exception.h // #define EXC_TYPES_COUNT 14 /* incl. illegal exception 0 */ var value: (T,T,T,T,T,T,T,T,T,T,T,T,T,T) = (0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0) init() { } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/mach_excServer.c ================================================ /* * IDENTIFICATION: * stub generated Mon Jan 11 00:24:26 2016 * with a MiG generated by bootstrap_cmds-93 * OPTIONS: */ /* Module mach_exc */ #if defined(__x86_64__) #define __MIG_check__Request__mach_exc_subsystem__ 1 #include "mach_excServer.h" #ifndef mig_internal #define mig_internal static __inline__ #endif /* mig_internal */ #ifndef mig_external #define mig_external #endif /* mig_external */ #if !defined(__MigTypeCheck) && defined(TypeCheck) #define __MigTypeCheck TypeCheck /* Legacy setting */ #endif /* !defined(__MigTypeCheck) */ #if !defined(__MigKernelSpecificCode) && defined(_MIG_KERNEL_SPECIFIC_CODE_) #define __MigKernelSpecificCode _MIG_KERNEL_SPECIFIC_CODE_ /* Legacy setting */ #endif /* !defined(__MigKernelSpecificCode) */ #ifndef LimitCheck #define LimitCheck 0 #endif /* LimitCheck */ #ifndef min #define min(a,b) ( ((a) < (b))? (a): (b) ) #endif /* min */ #if !defined(_WALIGN_) #define _WALIGN_(x) (((x) + 3) & ~3) #endif /* !defined(_WALIGN_) */ #if !defined(_WALIGNSZ_) #define _WALIGNSZ_(x) _WALIGN_(sizeof(x)) #endif /* !defined(_WALIGNSZ_) */ #ifndef UseStaticTemplates #define UseStaticTemplates 0 #endif /* UseStaticTemplates */ #ifndef __DeclareRcvRpc #define __DeclareRcvRpc(_NUM_, _NAME_) #endif /* __DeclareRcvRpc */ #ifndef __BeforeRcvRpc #define __BeforeRcvRpc(_NUM_, _NAME_) #endif /* __BeforeRcvRpc */ #ifndef __AfterRcvRpc #define __AfterRcvRpc(_NUM_, _NAME_) #endif /* __AfterRcvRpc */ #ifndef __DeclareRcvSimple #define __DeclareRcvSimple(_NUM_, _NAME_) #endif /* __DeclareRcvSimple */ #ifndef __BeforeRcvSimple #define __BeforeRcvSimple(_NUM_, _NAME_) #endif /* __BeforeRcvSimple */ #ifndef __AfterRcvSimple #define __AfterRcvSimple(_NUM_, _NAME_) #endif /* __AfterRcvSimple */ #define novalue void #define msgh_request_port msgh_local_port #define MACH_MSGH_BITS_REQUEST(bits) MACH_MSGH_BITS_LOCAL(bits) #define msgh_reply_port msgh_remote_port #define MACH_MSGH_BITS_REPLY(bits) MACH_MSGH_BITS_REMOTE(bits) #define MIG_RETURN_ERROR(X, code) {\ ((mig_reply_error_t *)X)->RetCode = code;\ ((mig_reply_error_t *)X)->NDR = NDR_record;\ return;\ } /* Forward Declarations */ mig_internal novalue _Xmach_exception_raise (mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP); mig_internal novalue _Xmach_exception_raise_state (mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP); mig_internal novalue _Xmach_exception_raise_state_identity (mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP); #if ( __MigTypeCheck ) #if __MIG_check__Request__mach_exc_subsystem__ #if !defined(__MIG_check__Request__mach_exception_raise_t__defined) #define __MIG_check__Request__mach_exception_raise_t__defined mig_internal kern_return_t __MIG_check__Request__mach_exception_raise_t(__attribute__((__unused__)) __Request__mach_exception_raise_t *In0P) { typedef __Request__mach_exception_raise_t __Request; #if __MigTypeCheck unsigned int msgh_size; #endif /* __MigTypeCheck */ #if __MigTypeCheck msgh_size = In0P->Head.msgh_size; if (!(In0P->Head.msgh_bits & MACH_MSGH_BITS_COMPLEX) || (In0P->msgh_body.msgh_descriptor_count != 2) || (msgh_size < (mach_msg_size_t)(sizeof(__Request) - 16)) || (msgh_size > (mach_msg_size_t)sizeof(__Request))) return MIG_BAD_ARGUMENTS; #endif /* __MigTypeCheck */ #if __MigTypeCheck if (In0P->thread.type != MACH_MSG_PORT_DESCRIPTOR || In0P->thread.disposition != 17) return MIG_TYPE_ERROR; #endif /* __MigTypeCheck */ #if __MigTypeCheck if (In0P->task.type != MACH_MSG_PORT_DESCRIPTOR || In0P->task.disposition != 17) return MIG_TYPE_ERROR; #endif /* __MigTypeCheck */ #if defined(__NDR_convert__int_rep__Request__mach_exception_raise_t__codeCnt__defined) if (In0P->NDR.int_rep != NDR_record.int_rep) __NDR_convert__int_rep__Request__mach_exception_raise_t__codeCnt(&In0P->codeCnt, In0P->NDR.int_rep); #endif /* __NDR_convert__int_rep__Request__mach_exception_raise_t__codeCnt__defined */ #if __MigTypeCheck if ( In0P->codeCnt > 2 ) return MIG_BAD_ARGUMENTS; if (((msgh_size - (mach_msg_size_t)(sizeof(__Request) - 16)) / 8 < In0P->codeCnt) || (msgh_size != (mach_msg_size_t)(sizeof(__Request) - 16) + (8 * In0P->codeCnt))) return MIG_BAD_ARGUMENTS; #endif /* __MigTypeCheck */ return MACH_MSG_SUCCESS; } #endif /* !defined(__MIG_check__Request__mach_exception_raise_t__defined) */ #endif /* __MIG_check__Request__mach_exc_subsystem__ */ #endif /* ( __MigTypeCheck ) */ /* Routine mach_exception_raise */ mig_internal novalue _Xmach_exception_raise (mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP) { #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; /* start of the kernel processed data */ mach_msg_body_t msgh_body; mach_msg_port_descriptor_t thread; mach_msg_port_descriptor_t task; /* end of the kernel processed data */ NDR_record_t NDR; exception_type_t exception; mach_msg_type_number_t codeCnt; int64_t code[2]; mach_msg_trailer_t trailer; } Request __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif typedef __Request__mach_exception_raise_t __Request; typedef __Reply__mach_exception_raise_t Reply __attribute__((unused)); /* * typedef struct { * mach_msg_header_t Head; * NDR_record_t NDR; * kern_return_t RetCode; * } mig_reply_error_t; */ Request *In0P = (Request *) InHeadP; Reply *OutP = (Reply *) OutHeadP; #ifdef __MIG_check__Request__mach_exception_raise_t__defined kern_return_t check_result; #endif /* __MIG_check__Request__mach_exception_raise_t__defined */ __DeclareRcvRpc(2405, "mach_exception_raise") __BeforeRcvRpc(2405, "mach_exception_raise") #if defined(__MIG_check__Request__mach_exception_raise_t__defined) check_result = __MIG_check__Request__mach_exception_raise_t((__Request *)In0P); if (check_result != MACH_MSG_SUCCESS) { MIG_RETURN_ERROR(OutP, check_result); } #endif /* defined(__MIG_check__Request__mach_exception_raise_t__defined) */ OutP->RetCode = catch_mach_exception_raise(In0P->Head.msgh_request_port, In0P->thread.name, In0P->task.name, In0P->exception, In0P->code, In0P->codeCnt); OutP->NDR = NDR_record; __AfterRcvRpc(2405, "mach_exception_raise") } #if ( __MigTypeCheck ) #if __MIG_check__Request__mach_exc_subsystem__ #if !defined(__MIG_check__Request__mach_exception_raise_state_t__defined) #define __MIG_check__Request__mach_exception_raise_state_t__defined mig_internal kern_return_t __MIG_check__Request__mach_exception_raise_state_t(__attribute__((__unused__)) __Request__mach_exception_raise_state_t *In0P, __attribute__((__unused__)) __Request__mach_exception_raise_state_t **In1PP) { typedef __Request__mach_exception_raise_state_t __Request; __Request *In1P; #if __MigTypeCheck unsigned int msgh_size; #endif /* __MigTypeCheck */ unsigned int msgh_size_delta; #if __MigTypeCheck msgh_size = In0P->Head.msgh_size; if ((In0P->Head.msgh_bits & MACH_MSGH_BITS_COMPLEX) || (msgh_size < (mach_msg_size_t)(sizeof(__Request) - 912)) || (msgh_size > (mach_msg_size_t)sizeof(__Request))) return MIG_BAD_ARGUMENTS; #endif /* __MigTypeCheck */ #if defined(__NDR_convert__int_rep__Request__mach_exception_raise_state_t__codeCnt__defined) if (In0P->NDR.int_rep != NDR_record.int_rep) __NDR_convert__int_rep__Request__mach_exception_raise_state_t__codeCnt(&In0P->codeCnt, In0P->NDR.int_rep); #endif /* __NDR_convert__int_rep__Request__mach_exception_raise_state_t__codeCnt__defined */ msgh_size_delta = (8 * In0P->codeCnt); #if __MigTypeCheck if ( In0P->codeCnt > 2 ) return MIG_BAD_ARGUMENTS; if (((msgh_size - (mach_msg_size_t)(sizeof(__Request) - 912)) / 8 < In0P->codeCnt) || (msgh_size < (mach_msg_size_t)(sizeof(__Request) - 912) + (8 * In0P->codeCnt))) return MIG_BAD_ARGUMENTS; msgh_size -= msgh_size_delta; #endif /* __MigTypeCheck */ *In1PP = In1P = (__Request *) ((pointer_t) In0P + msgh_size_delta - 16); #if defined(__NDR_convert__int_rep__Request__mach_exception_raise_state_t__old_stateCnt__defined) if (In0P->NDR.int_rep != NDR_record.int_rep) __NDR_convert__int_rep__Request__mach_exception_raise_state_t__old_stateCnt(&In1P->old_stateCnt, In1P->NDR.int_rep); #endif /* __NDR_convert__int_rep__Request__mach_exception_raise_state_t__old_stateCnt__defined */ #if __MigTypeCheck if ( In1P->old_stateCnt > 224 ) return MIG_BAD_ARGUMENTS; if (((msgh_size - (mach_msg_size_t)(sizeof(__Request) - 912)) / 4 < In1P->old_stateCnt) || (msgh_size != (mach_msg_size_t)(sizeof(__Request) - 912) + (4 * In1P->old_stateCnt))) return MIG_BAD_ARGUMENTS; #endif /* __MigTypeCheck */ return MACH_MSG_SUCCESS; } #endif /* !defined(__MIG_check__Request__mach_exception_raise_state_t__defined) */ #endif /* __MIG_check__Request__mach_exc_subsystem__ */ #endif /* ( __MigTypeCheck ) */ /* Routine mach_exception_raise_state */ mig_internal novalue _Xmach_exception_raise_state (mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP) { #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; NDR_record_t NDR; exception_type_t exception; mach_msg_type_number_t codeCnt; int64_t code[2]; int flavor; mach_msg_type_number_t old_stateCnt; natural_t old_state[224]; mach_msg_trailer_t trailer; } Request __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif typedef __Request__mach_exception_raise_state_t __Request; typedef __Reply__mach_exception_raise_state_t Reply __attribute__((unused)); /* * typedef struct { * mach_msg_header_t Head; * NDR_record_t NDR; * kern_return_t RetCode; * } mig_reply_error_t; */ Request *In0P = (Request *) InHeadP; Request *In1P; Reply *OutP = (Reply *) OutHeadP; #ifdef __MIG_check__Request__mach_exception_raise_state_t__defined kern_return_t check_result; #endif /* __MIG_check__Request__mach_exception_raise_state_t__defined */ __DeclareRcvRpc(2406, "mach_exception_raise_state") __BeforeRcvRpc(2406, "mach_exception_raise_state") #if defined(__MIG_check__Request__mach_exception_raise_state_t__defined) check_result = __MIG_check__Request__mach_exception_raise_state_t((__Request *)In0P, (__Request **)&In1P); if (check_result != MACH_MSG_SUCCESS) { MIG_RETURN_ERROR(OutP, check_result); } #endif /* defined(__MIG_check__Request__mach_exception_raise_state_t__defined) */ OutP->new_stateCnt = 224; OutP->RetCode = catch_mach_exception_raise_state(In0P->Head.msgh_request_port, In0P->exception, In0P->code, In0P->codeCnt, &In1P->flavor, In1P->old_state, In1P->old_stateCnt, OutP->new_state, &OutP->new_stateCnt); if (OutP->RetCode != KERN_SUCCESS) { MIG_RETURN_ERROR(OutP, OutP->RetCode); } OutP->NDR = NDR_record; OutP->flavor = In1P->flavor; OutP->Head.msgh_size = (mach_msg_size_t)(sizeof(Reply) - 896) + (((4 * OutP->new_stateCnt))); __AfterRcvRpc(2406, "mach_exception_raise_state") } #if ( __MigTypeCheck ) #if __MIG_check__Request__mach_exc_subsystem__ #if !defined(__MIG_check__Request__mach_exception_raise_state_identity_t__defined) #define __MIG_check__Request__mach_exception_raise_state_identity_t__defined mig_internal kern_return_t __MIG_check__Request__mach_exception_raise_state_identity_t(__attribute__((__unused__)) __Request__mach_exception_raise_state_identity_t *In0P, __attribute__((__unused__)) __Request__mach_exception_raise_state_identity_t **In1PP) { typedef __Request__mach_exception_raise_state_identity_t __Request; __Request *In1P; #if __MigTypeCheck unsigned int msgh_size; #endif /* __MigTypeCheck */ unsigned int msgh_size_delta; #if __MigTypeCheck msgh_size = In0P->Head.msgh_size; if (!(In0P->Head.msgh_bits & MACH_MSGH_BITS_COMPLEX) || (In0P->msgh_body.msgh_descriptor_count != 2) || (msgh_size < (mach_msg_size_t)(sizeof(__Request) - 912)) || (msgh_size > (mach_msg_size_t)sizeof(__Request))) return MIG_BAD_ARGUMENTS; #endif /* __MigTypeCheck */ #if __MigTypeCheck if (In0P->thread.type != MACH_MSG_PORT_DESCRIPTOR || In0P->thread.disposition != 17) return MIG_TYPE_ERROR; #endif /* __MigTypeCheck */ #if __MigTypeCheck if (In0P->task.type != MACH_MSG_PORT_DESCRIPTOR || In0P->task.disposition != 17) return MIG_TYPE_ERROR; #endif /* __MigTypeCheck */ #if defined(__NDR_convert__int_rep__Request__mach_exception_raise_state_identity_t__codeCnt__defined) if (In0P->NDR.int_rep != NDR_record.int_rep) __NDR_convert__int_rep__Request__mach_exception_raise_state_identity_t__codeCnt(&In0P->codeCnt, In0P->NDR.int_rep); #endif /* __NDR_convert__int_rep__Request__mach_exception_raise_state_identity_t__codeCnt__defined */ msgh_size_delta = (8 * In0P->codeCnt); #if __MigTypeCheck if ( In0P->codeCnt > 2 ) return MIG_BAD_ARGUMENTS; if (((msgh_size - (mach_msg_size_t)(sizeof(__Request) - 912)) / 8 < In0P->codeCnt) || (msgh_size < (mach_msg_size_t)(sizeof(__Request) - 912) + (8 * In0P->codeCnt))) return MIG_BAD_ARGUMENTS; msgh_size -= msgh_size_delta; #endif /* __MigTypeCheck */ *In1PP = In1P = (__Request *) ((pointer_t) In0P + msgh_size_delta - 16); #if defined(__NDR_convert__int_rep__Request__mach_exception_raise_state_identity_t__old_stateCnt__defined) if (In0P->NDR.int_rep != NDR_record.int_rep) __NDR_convert__int_rep__Request__mach_exception_raise_state_identity_t__old_stateCnt(&In1P->old_stateCnt, In1P->NDR.int_rep); #endif /* __NDR_convert__int_rep__Request__mach_exception_raise_state_identity_t__old_stateCnt__defined */ #if __MigTypeCheck if ( In1P->old_stateCnt > 224 ) return MIG_BAD_ARGUMENTS; if (((msgh_size - (mach_msg_size_t)(sizeof(__Request) - 912)) / 4 < In1P->old_stateCnt) || (msgh_size != (mach_msg_size_t)(sizeof(__Request) - 912) + (4 * In1P->old_stateCnt))) return MIG_BAD_ARGUMENTS; #endif /* __MigTypeCheck */ return MACH_MSG_SUCCESS; } #endif /* !defined(__MIG_check__Request__mach_exception_raise_state_identity_t__defined) */ #endif /* __MIG_check__Request__mach_exc_subsystem__ */ #endif /* ( __MigTypeCheck ) */ /* Routine mach_exception_raise_state_identity */ mig_internal novalue _Xmach_exception_raise_state_identity (mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP) { #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; /* start of the kernel processed data */ mach_msg_body_t msgh_body; mach_msg_port_descriptor_t thread; mach_msg_port_descriptor_t task; /* end of the kernel processed data */ NDR_record_t NDR; exception_type_t exception; mach_msg_type_number_t codeCnt; int64_t code[2]; int flavor; mach_msg_type_number_t old_stateCnt; natural_t old_state[224]; mach_msg_trailer_t trailer; } Request __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif typedef __Request__mach_exception_raise_state_identity_t __Request; typedef __Reply__mach_exception_raise_state_identity_t Reply __attribute__((unused)); /* * typedef struct { * mach_msg_header_t Head; * NDR_record_t NDR; * kern_return_t RetCode; * } mig_reply_error_t; */ Request *In0P = (Request *) InHeadP; Request *In1P; Reply *OutP = (Reply *) OutHeadP; #ifdef __MIG_check__Request__mach_exception_raise_state_identity_t__defined kern_return_t check_result; #endif /* __MIG_check__Request__mach_exception_raise_state_identity_t__defined */ __DeclareRcvRpc(2407, "mach_exception_raise_state_identity") __BeforeRcvRpc(2407, "mach_exception_raise_state_identity") #if defined(__MIG_check__Request__mach_exception_raise_state_identity_t__defined) check_result = __MIG_check__Request__mach_exception_raise_state_identity_t((__Request *)In0P, (__Request **)&In1P); if (check_result != MACH_MSG_SUCCESS) { MIG_RETURN_ERROR(OutP, check_result); } #endif /* defined(__MIG_check__Request__mach_exception_raise_state_identity_t__defined) */ OutP->new_stateCnt = 224; OutP->RetCode = catch_mach_exception_raise_state_identity(In0P->Head.msgh_request_port, In0P->thread.name, In0P->task.name, In0P->exception, In0P->code, In0P->codeCnt, &In1P->flavor, In1P->old_state, In1P->old_stateCnt, OutP->new_state, &OutP->new_stateCnt); if (OutP->RetCode != KERN_SUCCESS) { MIG_RETURN_ERROR(OutP, OutP->RetCode); } OutP->NDR = NDR_record; OutP->flavor = In1P->flavor; OutP->Head.msgh_size = (mach_msg_size_t)(sizeof(Reply) - 896) + (((4 * OutP->new_stateCnt))); __AfterRcvRpc(2407, "mach_exception_raise_state_identity") } /* Description of this subsystem, for use in direct RPC */ const struct catch_mach_exc_subsystem catch_mach_exc_subsystem = { mach_exc_server_routine, 2405, 2408, (mach_msg_size_t)sizeof(union __ReplyUnion__catch_mach_exc_subsystem), (vm_address_t)0, { { (mig_impl_routine_t) 0, (mig_stub_routine_t) _Xmach_exception_raise, 6, 0, (routine_arg_descriptor_t)0, (mach_msg_size_t)sizeof(__Reply__mach_exception_raise_t)}, { (mig_impl_routine_t) 0, (mig_stub_routine_t) _Xmach_exception_raise_state, 9, 0, (routine_arg_descriptor_t)0, (mach_msg_size_t)sizeof(__Reply__mach_exception_raise_state_t)}, { (mig_impl_routine_t) 0, (mig_stub_routine_t) _Xmach_exception_raise_state_identity, 11, 0, (routine_arg_descriptor_t)0, (mach_msg_size_t)sizeof(__Reply__mach_exception_raise_state_identity_t)}, } }; mig_external boolean_t mach_exc_server (mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP) { /* * typedef struct { * mach_msg_header_t Head; * NDR_record_t NDR; * kern_return_t RetCode; * } mig_reply_error_t; */ register mig_routine_t routine; OutHeadP->msgh_bits = MACH_MSGH_BITS(MACH_MSGH_BITS_REPLY(InHeadP->msgh_bits), 0); OutHeadP->msgh_remote_port = InHeadP->msgh_reply_port; /* Minimal size: routine() will update it if different */ OutHeadP->msgh_size = (mach_msg_size_t)sizeof(mig_reply_error_t); OutHeadP->msgh_local_port = MACH_PORT_NULL; OutHeadP->msgh_id = InHeadP->msgh_id + 100; if ((InHeadP->msgh_id > 2407) || (InHeadP->msgh_id < 2405) || ((routine = catch_mach_exc_subsystem.routine[InHeadP->msgh_id - 2405].stub_routine) == 0)) { ((mig_reply_error_t *)OutHeadP)->NDR = NDR_record; ((mig_reply_error_t *)OutHeadP)->RetCode = MIG_BAD_ID; return FALSE; } (*routine) (InHeadP, OutHeadP); return TRUE; } mig_external mig_routine_t mach_exc_server_routine (mach_msg_header_t *InHeadP) { register int msgh_id; msgh_id = InHeadP->msgh_id - 2405; if ((msgh_id > 2) || (msgh_id < 0)) return 0; return catch_mach_exc_subsystem.routine[msgh_id].stub_routine; } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/mach_excServer.h ================================================ #ifndef _mach_exc_server_ #define _mach_exc_server_ /* Module mach_exc */ #include #include #include #include #include #include #include #include #include /* BEGIN VOUCHER CODE */ #ifndef KERNEL #if defined(__has_include) #if __has_include() #ifndef USING_VOUCHERS #define USING_VOUCHERS #endif #ifndef __VOUCHER_FORWARD_TYPE_DECLS__ #define __VOUCHER_FORWARD_TYPE_DECLS__ #ifdef __cplusplus extern "C" { #endif extern boolean_t voucher_mach_msg_set(mach_msg_header_t *msg) __attribute__((weak_import)); #ifdef __cplusplus } #endif #endif // __VOUCHER_FORWARD_TYPE_DECLS__ #endif // __has_include() #endif // __has_include #endif // !KERNEL /* END VOUCHER CODE */ #ifdef AUTOTEST #ifndef FUNCTION_PTR_T #define FUNCTION_PTR_T typedef void (*function_ptr_t)(mach_port_t, char *, mach_msg_type_number_t); typedef struct { char *name; function_ptr_t function; } function_table_entry; typedef function_table_entry *function_table_t; #endif /* FUNCTION_PTR_T */ #endif /* AUTOTEST */ #ifndef mach_exc_MSG_COUNT #define mach_exc_MSG_COUNT 3 #endif /* mach_exc_MSG_COUNT */ #include #include #include #include #ifdef __BeforeMigServerHeader __BeforeMigServerHeader #endif /* __BeforeMigServerHeader */ /* Routine mach_exception_raise */ #ifdef mig_external mig_external #else extern #endif /* mig_external */ kern_return_t catch_mach_exception_raise ( mach_port_t exception_port, mach_port_t thread, mach_port_t task, exception_type_t exception, mach_exception_data_t code, mach_msg_type_number_t codeCnt ); /* Routine mach_exception_raise_state */ #ifdef mig_external mig_external #else extern #endif /* mig_external */ kern_return_t catch_mach_exception_raise_state ( mach_port_t exception_port, exception_type_t exception, const mach_exception_data_t code, mach_msg_type_number_t codeCnt, int *flavor, const thread_state_t old_state, mach_msg_type_number_t old_stateCnt, thread_state_t new_state, mach_msg_type_number_t *new_stateCnt ); /* Routine mach_exception_raise_state_identity */ #ifdef mig_external mig_external #else extern #endif /* mig_external */ kern_return_t catch_mach_exception_raise_state_identity ( mach_port_t exception_port, mach_port_t thread, mach_port_t task, exception_type_t exception, mach_exception_data_t code, mach_msg_type_number_t codeCnt, int *flavor, thread_state_t old_state, mach_msg_type_number_t old_stateCnt, thread_state_t new_state, mach_msg_type_number_t *new_stateCnt ); #ifdef mig_external mig_external #else extern #endif /* mig_external */ boolean_t mach_exc_server( mach_msg_header_t *InHeadP, mach_msg_header_t *OutHeadP); #ifdef mig_external mig_external #else extern #endif /* mig_external */ mig_routine_t mach_exc_server_routine( mach_msg_header_t *InHeadP); /* Description of this subsystem, for use in direct RPC */ extern const struct catch_mach_exc_subsystem { mig_server_routine_t server; /* Server routine */ mach_msg_id_t start; /* Min routine number */ mach_msg_id_t end; /* Max routine number + 1 */ unsigned int maxsize; /* Max msg size */ vm_address_t reserved; /* Reserved */ struct routine_descriptor /*Array of routine descriptors */ routine[3]; } catch_mach_exc_subsystem; /* typedefs for all requests */ #ifndef __Request__mach_exc_subsystem__defined #define __Request__mach_exc_subsystem__defined #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; /* start of the kernel processed data */ mach_msg_body_t msgh_body; mach_msg_port_descriptor_t thread; mach_msg_port_descriptor_t task; /* end of the kernel processed data */ NDR_record_t NDR; exception_type_t exception; mach_msg_type_number_t codeCnt; int64_t code[2]; } __Request__mach_exception_raise_t __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; NDR_record_t NDR; exception_type_t exception; mach_msg_type_number_t codeCnt; int64_t code[2]; int flavor; mach_msg_type_number_t old_stateCnt; natural_t old_state[224]; } __Request__mach_exception_raise_state_t __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; /* start of the kernel processed data */ mach_msg_body_t msgh_body; mach_msg_port_descriptor_t thread; mach_msg_port_descriptor_t task; /* end of the kernel processed data */ NDR_record_t NDR; exception_type_t exception; mach_msg_type_number_t codeCnt; int64_t code[2]; int flavor; mach_msg_type_number_t old_stateCnt; natural_t old_state[224]; } __Request__mach_exception_raise_state_identity_t __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif #endif /* !__Request__mach_exc_subsystem__defined */ /* union of all requests */ #ifndef __RequestUnion__catch_mach_exc_subsystem__defined #define __RequestUnion__catch_mach_exc_subsystem__defined union __RequestUnion__catch_mach_exc_subsystem { __Request__mach_exception_raise_t Request_mach_exception_raise; __Request__mach_exception_raise_state_t Request_mach_exception_raise_state; __Request__mach_exception_raise_state_identity_t Request_mach_exception_raise_state_identity; }; #endif /* __RequestUnion__catch_mach_exc_subsystem__defined */ /* typedefs for all replies */ #ifndef __Reply__mach_exc_subsystem__defined #define __Reply__mach_exc_subsystem__defined #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; NDR_record_t NDR; kern_return_t RetCode; } __Reply__mach_exception_raise_t __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; NDR_record_t NDR; kern_return_t RetCode; int flavor; mach_msg_type_number_t new_stateCnt; natural_t new_state[224]; } __Reply__mach_exception_raise_state_t __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif #ifdef __MigPackStructs #pragma pack(4) #endif typedef struct { mach_msg_header_t Head; NDR_record_t NDR; kern_return_t RetCode; int flavor; mach_msg_type_number_t new_stateCnt; natural_t new_state[224]; } __Reply__mach_exception_raise_state_identity_t __attribute__((unused)); #ifdef __MigPackStructs #pragma pack() #endif #endif /* !__Reply__mach_exc_subsystem__defined */ /* union of all replies */ #ifndef __ReplyUnion__catch_mach_exc_subsystem__defined #define __ReplyUnion__catch_mach_exc_subsystem__defined union __ReplyUnion__catch_mach_exc_subsystem { __Reply__mach_exception_raise_t Reply_mach_exception_raise; __Reply__mach_exception_raise_state_t Reply_mach_exception_raise_state; __Reply__mach_exception_raise_state_identity_t Reply_mach_exception_raise_state_identity; }; #endif /* __RequestUnion__catch_mach_exc_subsystem__defined */ #ifndef subsystem_to_name_map_mach_exc #define subsystem_to_name_map_mach_exc \ { "mach_exception_raise", 2405 },\ { "mach_exception_raise_state", 2406 },\ { "mach_exception_raise_state_identity", 2407 } #endif #ifdef __AfterMigServerHeader __AfterMigServerHeader #endif /* __AfterMigServerHeader */ #endif /* _mach_exc_server_ */ ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Adapters/AdapterProtocols.swift ================================================ import Foundation /// Protocol for the assertion handler that Nimble uses for all expectations. public protocol AssertionHandler { func assert(_ assertion: Bool, message: FailureMessage, location: SourceLocation) } /// Global backing interface for assertions that Nimble creates. /// Defaults to a private test handler that passes through to XCTest. /// /// If XCTest is not available, you must assign your own assertion handler /// before using any matchers, otherwise Nimble will abort the program. /// /// @see AssertionHandler public var NimbleAssertionHandler: AssertionHandler = { () -> AssertionHandler in return isXCTestAvailable() ? NimbleXCTestHandler() : NimbleXCTestUnavailableHandler() }() ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Adapters/AssertionDispatcher.swift ================================================ /// AssertionDispatcher allows multiple AssertionHandlers to receive /// assertion messages. /// /// @warning Does not fully dispatch if one of the handlers raises an exception. /// This is possible with XCTest-based assertion handlers. /// public class AssertionDispatcher: AssertionHandler { let handlers: [AssertionHandler] public init(handlers: [AssertionHandler]) { self.handlers = handlers } public func assert(_ assertion: Bool, message: FailureMessage, location: SourceLocation) { for handler in handlers { handler.assert(assertion, message: message, location: location) } } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Adapters/AssertionRecorder.swift ================================================ import Foundation /// A data structure that stores information about an assertion when /// AssertionRecorder is set as the Nimble assertion handler. /// /// @see AssertionRecorder /// @see AssertionHandler public struct AssertionRecord: CustomStringConvertible { /// Whether the assertion succeeded or failed public let success: Bool /// The failure message the assertion would display on failure. public let message: FailureMessage /// The source location the expectation occurred on. public let location: SourceLocation public var description: String { return "AssertionRecord { success=\(success), message='\(message.stringValue)', location=\(location) }" } } /// An AssertionHandler that silently records assertions that Nimble makes. /// This is useful for testing failure messages for matchers. /// /// @see AssertionHandler public class AssertionRecorder : AssertionHandler { /// All the assertions that were captured by this recorder public var assertions = [AssertionRecord]() public init() {} public func assert(_ assertion: Bool, message: FailureMessage, location: SourceLocation) { assertions.append( AssertionRecord( success: assertion, message: message, location: location)) } } /// Allows you to temporarily replace the current Nimble assertion handler with /// the one provided for the scope of the closure. /// /// Once the closure finishes, then the original Nimble assertion handler is restored. /// /// @see AssertionHandler public func withAssertionHandler(_ tempAssertionHandler: AssertionHandler, closure: @escaping () throws -> Void) { let environment = NimbleEnvironment.activeInstance let oldRecorder = environment.assertionHandler let capturer = NMBExceptionCapture(handler: nil, finally: ({ environment.assertionHandler = oldRecorder })) environment.assertionHandler = tempAssertionHandler capturer.tryBlock { try! closure() } } /// Captures expectations that occur in the given closure. Note that all /// expectations will still go through to the default Nimble handler. /// /// This can be useful if you want to gather information about expectations /// that occur within a closure. /// /// @param silently expectations are no longer send to the default Nimble /// assertion handler when this is true. Defaults to false. /// /// @see gatherFailingExpectations public func gatherExpectations(silently: Bool = false, closure: @escaping () -> Void) -> [AssertionRecord] { let previousRecorder = NimbleEnvironment.activeInstance.assertionHandler let recorder = AssertionRecorder() let handlers: [AssertionHandler] if silently { handlers = [recorder] } else { handlers = [recorder, previousRecorder] } let dispatcher = AssertionDispatcher(handlers: handlers) withAssertionHandler(dispatcher, closure: closure) return recorder.assertions } /// Captures failed expectations that occur in the given closure. Note that all /// expectations will still go through to the default Nimble handler. /// /// This can be useful if you want to gather information about failed /// expectations that occur within a closure. /// /// @param silently expectations are no longer send to the default Nimble /// assertion handler when this is true. Defaults to false. /// /// @see gatherExpectations /// @see raiseException source for an example use case. public func gatherFailingExpectations(silently: Bool = false, closure: @escaping () -> Void) -> [AssertionRecord] { let assertions = gatherExpectations(silently: silently, closure: closure) return assertions.filter { assertion in !assertion.success } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Adapters/NMBExpectation.swift ================================================ import Foundation #if _runtime(_ObjC) internal struct ObjCMatcherWrapper : Matcher { let matcher: NMBMatcher func matches(_ actualExpression: Expression, failureMessage: FailureMessage) -> Bool { return matcher.matches( ({ try! actualExpression.evaluate() }), failureMessage: failureMessage, location: actualExpression.location) } func doesNotMatch(_ actualExpression: Expression, failureMessage: FailureMessage) -> Bool { return matcher.doesNotMatch( ({ try! actualExpression.evaluate() }), failureMessage: failureMessage, location: actualExpression.location) } } // Equivalent to Expectation, but for Nimble's Objective-C interface public class NMBExpectation : NSObject { internal let _actualBlock: () -> NSObject! internal var _negative: Bool internal let _file: FileString internal let _line: UInt internal var _timeout: TimeInterval = 1.0 public init(actualBlock: @escaping () -> NSObject!, negative: Bool, file: FileString, line: UInt) { self._actualBlock = actualBlock self._negative = negative self._file = file self._line = line } private var expectValue: Expectation { return expect(_file, line: _line){ self._actualBlock() as NSObject? } } public var withTimeout: (TimeInterval) -> NMBExpectation { return ({ timeout in self._timeout = timeout return self }) } public var to: (NMBMatcher) -> Void { return ({ matcher in self.expectValue.to(ObjCMatcherWrapper(matcher: matcher)) }) } public var toWithDescription: (NMBMatcher, String) -> Void { return ({ matcher, description in self.expectValue.to(ObjCMatcherWrapper(matcher: matcher), description: description) }) } public var toNot: (NMBMatcher) -> Void { return ({ matcher in self.expectValue.toNot( ObjCMatcherWrapper(matcher: matcher) ) }) } public var toNotWithDescription: (NMBMatcher, String) -> Void { return ({ matcher, description in self.expectValue.toNot( ObjCMatcherWrapper(matcher: matcher), description: description ) }) } public var notTo: (NMBMatcher) -> Void { return toNot } public var notToWithDescription: (NMBMatcher, String) -> Void { return toNotWithDescription } public var toEventually: (NMBMatcher) -> Void { return ({ matcher in self.expectValue.toEventually( ObjCMatcherWrapper(matcher: matcher), timeout: self._timeout, description: nil ) }) } public var toEventuallyWithDescription: (NMBMatcher, String) -> Void { return ({ matcher, description in self.expectValue.toEventually( ObjCMatcherWrapper(matcher: matcher), timeout: self._timeout, description: description ) }) } public var toEventuallyNot: (NMBMatcher) -> Void { return ({ matcher in self.expectValue.toEventuallyNot( ObjCMatcherWrapper(matcher: matcher), timeout: self._timeout, description: nil ) }) } public var toEventuallyNotWithDescription: (NMBMatcher, String) -> Void { return ({ matcher, description in self.expectValue.toEventuallyNot( ObjCMatcherWrapper(matcher: matcher), timeout: self._timeout, description: description ) }) } public var toNotEventually: (NMBMatcher) -> Void { return toEventuallyNot } public var toNotEventuallyWithDescription: (NMBMatcher, String) -> Void { return toEventuallyNotWithDescription } public class func failWithMessage(_ message: String, file: FileString, line: UInt) { fail(message, location: SourceLocation(file: file, line: line)) } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Adapters/NMBObjCMatcher.swift ================================================ import Foundation #if _runtime(_ObjC) public typealias MatcherBlock = (_ actualExpression: Expression, _ failureMessage: FailureMessage) -> Bool public typealias FullMatcherBlock = (_ actualExpression: Expression, _ failureMessage: FailureMessage, _ shouldNotMatch: Bool) -> Bool public class NMBObjCMatcher : NSObject, NMBMatcher { let _match: MatcherBlock let _doesNotMatch: MatcherBlock let canMatchNil: Bool public init(canMatchNil: Bool, matcher: @escaping MatcherBlock, notMatcher: @escaping MatcherBlock) { self.canMatchNil = canMatchNil self._match = matcher self._doesNotMatch = notMatcher } public convenience init(matcher: @escaping MatcherBlock) { self.init(canMatchNil: true, matcher: matcher) } public convenience init(canMatchNil: Bool, matcher: @escaping MatcherBlock) { self.init(canMatchNil: canMatchNil, matcher: matcher, notMatcher: ({ actualExpression, failureMessage in return !matcher(actualExpression, failureMessage) })) } public convenience init(matcher: @escaping FullMatcherBlock) { self.init(canMatchNil: true, matcher: matcher) } public convenience init(canMatchNil: Bool, matcher: @escaping FullMatcherBlock) { self.init(canMatchNil: canMatchNil, matcher: ({ actualExpression, failureMessage in return matcher(actualExpression, failureMessage, false) }), notMatcher: ({ actualExpression, failureMessage in return matcher(actualExpression, failureMessage, true) })) } private func canMatch(_ actualExpression: Expression, failureMessage: FailureMessage) -> Bool { do { if !canMatchNil { if try actualExpression.evaluate() == nil { failureMessage.postfixActual = " (use beNil() to match nils)" return false } } } catch let error { failureMessage.actualValue = "an unexpected error thrown: \(error)" return false } return true } public func matches(_ actualBlock: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool { let expr = Expression(expression: actualBlock, location: location) let result = _match( expr, failureMessage) if self.canMatch(Expression(expression: actualBlock, location: location), failureMessage: failureMessage) { return result } else { return false } } public func doesNotMatch(_ actualBlock: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool { let expr = Expression(expression: actualBlock, location: location) let result = _doesNotMatch( expr, failureMessage) if self.canMatch(Expression(expression: actualBlock, location: location), failureMessage: failureMessage) { return result } else { return false } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Adapters/NimbleEnvironment.swift ================================================ import Dispatch import Foundation /// "Global" state of Nimble is stored here. Only DSL functions should access / be aware of this /// class' existance internal class NimbleEnvironment { static var activeInstance: NimbleEnvironment { get { let env = Thread.current.threadDictionary["NimbleEnvironment"] if let env = env as? NimbleEnvironment { return env } else { let newEnv = NimbleEnvironment() self.activeInstance = newEnv return newEnv } } set { Thread.current.threadDictionary["NimbleEnvironment"] = newValue } } // TODO: eventually migrate the global to this environment value var assertionHandler: AssertionHandler { get { return NimbleAssertionHandler } set { NimbleAssertionHandler = newValue } } var suppressTVOSAssertionWarning: Bool = false var awaiter: Awaiter init() { let timeoutQueue: DispatchQueue if #available(OSX 10.10, *) { timeoutQueue = DispatchQueue.global(qos: .userInitiated) } else { timeoutQueue = DispatchQueue.global(priority: .high) } awaiter = Awaiter( waitLock: AssertionWaitLock(), asyncQueue: .main, timeoutQueue: timeoutQueue) } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Adapters/NimbleXCTestHandler.swift ================================================ import Foundation import XCTest /// Default handler for Nimble. This assertion handler passes failures along to /// XCTest. public class NimbleXCTestHandler : AssertionHandler { public func assert(_ assertion: Bool, message: FailureMessage, location: SourceLocation) { if !assertion { recordFailure("\(message.stringValue)\n", location: location) } } } /// Alternative handler for Nimble. This assertion handler passes failures along /// to XCTest by attempting to reduce the failure message size. public class NimbleShortXCTestHandler: AssertionHandler { public func assert(_ assertion: Bool, message: FailureMessage, location: SourceLocation) { if !assertion { let msg: String if let actual = message.actualValue { msg = "got: \(actual) \(message.postfixActual)" } else { msg = "expected \(message.to) \(message.postfixMessage)" } recordFailure("\(msg)\n", location: location) } } } /// Fallback handler in case XCTest is unavailable. This assertion handler will abort /// the program if it is invoked. class NimbleXCTestUnavailableHandler : AssertionHandler { func assert(_ assertion: Bool, message: FailureMessage, location: SourceLocation) { fatalError("XCTest is not available and no custom assertion handler was configured. Aborting.") } } #if _runtime(_ObjC) /// Helper class providing access to the currently executing XCTestCase instance, if any @objc final internal class CurrentTestCaseTracker: NSObject, XCTestObservation { @objc static let sharedInstance = CurrentTestCaseTracker() private(set) var currentTestCase: XCTestCase? @objc func testCaseWillStart(_ testCase: XCTestCase) { currentTestCase = testCase } @objc func testCaseDidFinish(_ testCase: XCTestCase) { currentTestCase = nil } } #endif func isXCTestAvailable() -> Bool { #if _runtime(_ObjC) // XCTest is weakly linked and so may not be present return NSClassFromString("XCTestCase") != nil #else return true #endif } private func recordFailure(_ message: String, location: SourceLocation) { #if _runtime(_ObjC) if let testCase = CurrentTestCaseTracker.sharedInstance.currentTestCase { testCase.recordFailure(withDescription: message, inFile: location.file, atLine: location.line, expected: true) } else { let msg = "Attempted to report a test failure to XCTest while no test case was running. " + "The failure was:\n\"\(message)\"\nIt occurred at: \(location.file):\(location.line)" NSException(name: .internalInconsistencyException, reason: msg, userInfo: nil).raise() } #else XCTFail("\(message)\n", file: location.file, line: location.line) #endif } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/DSL+Wait.swift ================================================ import Dispatch import Foundation private enum ErrorResult { case exception(NSException) case error(Error) case none } /// Only classes, protocols, methods, properties, and subscript declarations can be /// bridges to Objective-C via the @objc keyword. This class encapsulates callback-style /// asynchronous waiting logic so that it may be called from Objective-C and Swift. internal class NMBWait: NSObject { internal class func until( timeout: TimeInterval, file: FileString = #file, line: UInt = #line, action: @escaping (@escaping () -> Void) -> Void) -> Void { return throwableUntil(timeout: timeout, file: file, line: line) { done in action(done) } } // Using a throwable closure makes this method not objc compatible. internal class func throwableUntil( timeout: TimeInterval, file: FileString = #file, line: UInt = #line, action: @escaping (@escaping () -> Void) throws -> Void) -> Void { let awaiter = NimbleEnvironment.activeInstance.awaiter let leeway = timeout / 2.0 let result = awaiter.performBlock { (done: @escaping (ErrorResult) -> Void) throws -> Void in DispatchQueue.main.async { let capture = NMBExceptionCapture( handler: ({ exception in done(.exception(exception)) }), finally: ({ }) ) capture.tryBlock { do { try action() { done(.none) } } catch let e { done(.error(e)) } } } }.timeout(timeout, forcefullyAbortTimeout: leeway).wait("waitUntil(...)", file: file, line: line) switch result { case .incomplete: internalError("Reached .incomplete state for waitUntil(...).") case .blockedRunLoop: fail(blockedRunLoopErrorMessageFor("-waitUntil()", leeway: leeway), file: file, line: line) case .timedOut: let pluralize = (timeout == 1 ? "" : "s") fail("Waited more than \(timeout) second\(pluralize)", file: file, line: line) case let .raisedException(exception): fail("Unexpected exception raised: \(exception)") case let .errorThrown(error): fail("Unexpected error thrown: \(error)") case .completed(.exception(let exception)): fail("Unexpected exception raised: \(exception)") case .completed(.error(let error)): fail("Unexpected error thrown: \(error)") case .completed(.none): // success break } } #if _runtime(_ObjC) @objc(untilFile:line:action:) internal class func until(_ file: FileString = #file, line: UInt = #line, action: @escaping (() -> Void) -> Void) -> Void { until(timeout: 1, file: file, line: line, action: action) } #else internal class func until(_ file: FileString = #file, line: UInt = #line, action: @escaping (() -> Void) -> Void) -> Void { until(timeout: 1, file: file, line: line, action: action) } #endif } internal func blockedRunLoopErrorMessageFor(_ fnName: String, leeway: TimeInterval) -> String { return "\(fnName) timed out but was unable to run the timeout handler because the main thread is unresponsive (\(leeway) seconds is allow after the wait times out). Conditions that may cause this include processing blocking IO on the main thread, calls to sleep(), deadlocks, and synchronous IPC. Nimble forcefully stopped run loop which may cause future failures in test run." } /// Wait asynchronously until the done closure is called or the timeout has been reached. /// /// @discussion /// Call the done() closure to indicate the waiting has completed. /// /// This function manages the main run loop (`NSRunLoop.mainRunLoop()`) while this function /// is executing. Any attempts to touch the run loop may cause non-deterministic behavior. public func waitUntil(timeout: TimeInterval = 1, file: FileString = #file, line: UInt = #line, action: @escaping (@escaping () -> Void) -> Void) -> Void { NMBWait.until(timeout: timeout, file: file, line: line, action: action) } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/DSL.swift ================================================ import Foundation /// Make an expectation on a given actual value. The value given is lazily evaluated. public func expect(_ expression: @autoclosure @escaping () throws -> T?, file: FileString = #file, line: UInt = #line) -> Expectation { return Expectation( expression: Expression( expression: expression, location: SourceLocation(file: file, line: line), isClosure: true)) } /// Make an expectation on a given actual value. The closure is lazily invoked. public func expect(_ file: FileString = #file, line: UInt = #line, expression: @escaping () throws -> T?) -> Expectation { return Expectation( expression: Expression( expression: expression, location: SourceLocation(file: file, line: line), isClosure: true)) } /// Always fails the test with a message and a specified location. public func fail(_ message: String, location: SourceLocation) { let handler = NimbleEnvironment.activeInstance.assertionHandler handler.assert(false, message: FailureMessage(stringValue: message), location: location) } /// Always fails the test with a message. public func fail(_ message: String, file: FileString = #file, line: UInt = #line) { fail(message, location: SourceLocation(file: file, line: line)) } /// Always fails the test. public func fail(_ file: FileString = #file, line: UInt = #line) { fail("fail() always fails", file: file, line: line) } /// Like Swift's precondition(), but raises NSExceptions instead of sigaborts internal func nimblePrecondition( _ expr: @autoclosure() -> Bool, _ name: @autoclosure() -> String, _ message: @autoclosure() -> String, file: StaticString = #file, line: UInt = #line) { let result = expr() if !result { #if _runtime(_ObjC) let e = NSException( name: NSExceptionName(name()), reason: message(), userInfo: nil) e.raise() #else preconditionFailure("\(name()) - \(message())", file: file, line: line) #endif } } internal func internalError(_ msg: String, file: FileString = #file, line: UInt = #line) -> Never { fatalError( "Nimble Bug Found: \(msg) at \(file):\(line).\n" + "Please file a bug to Nimble: https://github.com/Quick/Nimble/issues with the " + "code snippet that caused this error." ) } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Expectation.swift ================================================ import Foundation internal func expressionMatches(_ expression: Expression, matcher: U, to: String, description: String?) -> (Bool, FailureMessage) where U: Matcher, U.ValueType == T { let msg = FailureMessage() msg.userDescription = description msg.to = to do { let pass = try matcher.matches(expression, failureMessage: msg) if msg.actualValue == "" { msg.actualValue = "<\(stringify(try expression.evaluate()))>" } return (pass, msg) } catch let error { msg.actualValue = "an unexpected error thrown: <\(error)>" return (false, msg) } } internal func expressionDoesNotMatch(_ expression: Expression, matcher: U, toNot: String, description: String?) -> (Bool, FailureMessage) where U: Matcher, U.ValueType == T { let msg = FailureMessage() msg.userDescription = description msg.to = toNot do { let pass = try matcher.doesNotMatch(expression, failureMessage: msg) if msg.actualValue == "" { msg.actualValue = "<\(stringify(try expression.evaluate()))>" } return (pass, msg) } catch let error { msg.actualValue = "an unexpected error thrown: <\(error)>" return (false, msg) } } public struct Expectation { public let expression: Expression public func verify(_ pass: Bool, _ message: FailureMessage) { let handler = NimbleEnvironment.activeInstance.assertionHandler handler.assert(pass, message: message, location: expression.location) } /// Tests the actual value using a matcher to match. public func to(_ matcher: U, description: String? = nil) where U: Matcher, U.ValueType == T { let (pass, msg) = expressionMatches(expression, matcher: matcher, to: "to", description: description) verify(pass, msg) } /// Tests the actual value using a matcher to not match. public func toNot(_ matcher: U, description: String? = nil) where U: Matcher, U.ValueType == T { let (pass, msg) = expressionDoesNotMatch(expression, matcher: matcher, toNot: "to not", description: description) verify(pass, msg) } /// Tests the actual value using a matcher to not match. /// /// Alias to toNot(). public func notTo(_ matcher: U, description: String? = nil) where U: Matcher, U.ValueType == T { toNot(matcher, description: description) } // see: // - AsyncMatcherWrapper for extension // - NMBExpectation for Objective-C interface } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Expression.swift ================================================ import Foundation // Memoizes the given closure, only calling the passed // closure once; even if repeat calls to the returned closure internal func memoizedClosure(_ closure: @escaping () throws -> T) -> (Bool) throws -> T { var cache: T? return ({ withoutCaching in if (withoutCaching || cache == nil) { cache = try closure() } return cache! }) } /// Expression represents the closure of the value inside expect(...). /// Expressions are memoized by default. This makes them safe to call /// evaluate() multiple times without causing a re-evaluation of the underlying /// closure. /// /// @warning Since the closure can be any code, Objective-C code may choose /// to raise an exception. Currently, Expression does not memoize /// exception raising. /// /// This provides a common consumable API for matchers to utilize to allow /// Nimble to change internals to how the captured closure is managed. public struct Expression { internal let _expression: (Bool) throws -> T? internal let _withoutCaching: Bool public let location: SourceLocation public let isClosure: Bool /// Creates a new expression struct. Normally, expect(...) will manage this /// creation process. The expression is memoized. /// /// @param expression The closure that produces a given value. /// @param location The source location that this closure originates from. /// @param isClosure A bool indicating if the captured expression is a /// closure or internally produced closure. Some matchers /// may require closures. For example, toEventually() /// requires an explicit closure. This gives Nimble /// flexibility if @autoclosure behavior changes between /// Swift versions. Nimble internals always sets this true. public init(expression: @escaping () throws -> T?, location: SourceLocation, isClosure: Bool = true) { self._expression = memoizedClosure(expression) self.location = location self._withoutCaching = false self.isClosure = isClosure } /// Creates a new expression struct. Normally, expect(...) will manage this /// creation process. /// /// @param expression The closure that produces a given value. /// @param location The source location that this closure originates from. /// @param withoutCaching Indicates if the struct should memoize the given /// closure's result. Subsequent evaluate() calls will /// not call the given closure if this is true. /// @param isClosure A bool indicating if the captured expression is a /// closure or internally produced closure. Some matchers /// may require closures. For example, toEventually() /// requires an explicit closure. This gives Nimble /// flexibility if @autoclosure behavior changes between /// Swift versions. Nimble internals always sets this true. public init(memoizedExpression: @escaping (Bool) throws -> T?, location: SourceLocation, withoutCaching: Bool, isClosure: Bool = true) { self._expression = memoizedExpression self.location = location self._withoutCaching = withoutCaching self.isClosure = isClosure } /// Returns a new Expression from the given expression. Identical to a map() /// on this type. This should be used only to typecast the Expression's /// closure value. /// /// The returned expression will preserve location and isClosure. /// /// @param block The block that can cast the current Expression value to a /// new type. public func cast(_ block: @escaping (T?) throws -> U?) -> Expression { return Expression(expression: ({ try block(self.evaluate()) }), location: self.location, isClosure: self.isClosure) } public func evaluate() throws -> T? { return try self._expression(_withoutCaching) } public func withoutCaching() -> Expression { return Expression(memoizedExpression: self._expression, location: location, withoutCaching: true, isClosure: isClosure) } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/FailureMessage.swift ================================================ import Foundation /// Encapsulates the failure message that matchers can report to the end user. /// /// This is shared state between Nimble and matchers that mutate this value. public class FailureMessage: NSObject { public var expected: String = "expected" public var actualValue: String? = "" // empty string -> use default; nil -> exclude public var to: String = "to" public var postfixMessage: String = "match" public var postfixActual: String = "" /// An optional message that will be appended as a new line and provides additional details /// about the failure. This message will only be visible in the issue navigator / in logs but /// not directly in the source editor since only a single line is presented there. public var extendedMessage: String? = nil public var userDescription: String? = nil public var stringValue: String { get { if let value = _stringValueOverride { return value } else { return computeStringValue() } } set { _stringValueOverride = newValue } } internal var _stringValueOverride: String? public override init() { } public init(stringValue: String) { _stringValueOverride = stringValue } internal func stripNewlines(_ str: String) -> String { let whitespaces = CharacterSet.whitespacesAndNewlines return str .components(separatedBy: "\n") .map { line in line.trimmingCharacters(in: whitespaces) } .joined(separator: "") } internal func computeStringValue() -> String { var value = "\(expected) \(to) \(postfixMessage)" if let actualValue = actualValue { value = "\(expected) \(to) \(postfixMessage), got \(actualValue)\(postfixActual)" } value = stripNewlines(value) if let extendedMessage = extendedMessage { value += "\n\(stripNewlines(extendedMessage))" } if let userDescription = userDescription { return "\(userDescription)\n\(value)" } return value } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/AllPass.swift ================================================ import Foundation public func allPass (_ passFunc: @escaping (T?) -> Bool) -> NonNilMatcherFunc where U: Sequence, U.Iterator.Element == T { return allPass("pass a condition", passFunc) } public func allPass (_ passName: String, _ passFunc: @escaping (T?) -> Bool) -> NonNilMatcherFunc where U: Sequence, U.Iterator.Element == T { return createAllPassMatcher() { expression, failureMessage in failureMessage.postfixMessage = passName return passFunc(try expression.evaluate()) } } public func allPass (_ matcher: V) -> NonNilMatcherFunc where U: Sequence, V: Matcher, U.Iterator.Element == V.ValueType { return createAllPassMatcher() { try matcher.matches($0, failureMessage: $1) } } private func createAllPassMatcher (_ elementEvaluator: @escaping (Expression, FailureMessage) throws -> Bool) -> NonNilMatcherFunc where U: Sequence, U.Iterator.Element == T { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.actualValue = nil if let actualValue = try actualExpression.evaluate() { for currentElement in actualValue { let exp = Expression( expression: {currentElement}, location: actualExpression.location) if try !elementEvaluator(exp, failureMessage) { failureMessage.postfixMessage = "all \(failureMessage.postfixMessage)," + " but failed first at element <\(stringify(currentElement))>" + " in <\(stringify(actualValue))>" return false } } failureMessage.postfixMessage = "all \(failureMessage.postfixMessage)" } else { failureMessage.postfixMessage = "all pass (use beNil() to match nils)" return false } return true } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func allPassMatcher(_ matcher: NMBObjCMatcher) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let location = actualExpression.location let actualValue = try! actualExpression.evaluate() var nsObjects = [NSObject]() var collectionIsUsable = true if let value = actualValue as? NSFastEnumeration { let generator = NSFastEnumerationIterator(value) while let obj = generator.next() { if let nsObject = obj as? NSObject { nsObjects.append(nsObject) } else { collectionIsUsable = false break } } } else { collectionIsUsable = false } if !collectionIsUsable { failureMessage.postfixMessage = "allPass only works with NSFastEnumeration (NSArray, NSSet, ...) of NSObjects" failureMessage.expected = "" failureMessage.to = "" return false } let expr = Expression(expression: ({ nsObjects }), location: location) let elementEvaluator: (Expression, FailureMessage) -> Bool = { expression, failureMessage in return matcher.matches( {try! expression.evaluate()}, failureMessage: failureMessage, location: expr.location) } return try! createAllPassMatcher(elementEvaluator).matches( expr, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/AsyncMatcherWrapper.swift ================================================ import Foundation /// If you are running on a slower machine, it could be useful to increase the default timeout value /// or slow down poll interval. Default timeout interval is 1, and poll interval is 0.01. public struct AsyncDefaults { public static var Timeout: TimeInterval = 1 public static var PollInterval: TimeInterval = 0.01 } internal struct AsyncMatcherWrapper: Matcher where U: Matcher, U.ValueType == T { let fullMatcher: U let timeoutInterval: TimeInterval let pollInterval: TimeInterval init(fullMatcher: U, timeoutInterval: TimeInterval = AsyncDefaults.Timeout, pollInterval: TimeInterval = AsyncDefaults.PollInterval) { self.fullMatcher = fullMatcher self.timeoutInterval = timeoutInterval self.pollInterval = pollInterval } func matches(_ actualExpression: Expression, failureMessage: FailureMessage) -> Bool { let uncachedExpression = actualExpression.withoutCaching() let fnName = "expect(...).toEventually(...)" let result = pollBlock( pollInterval: pollInterval, timeoutInterval: timeoutInterval, file: actualExpression.location.file, line: actualExpression.location.line, fnName: fnName) { try self.fullMatcher.matches(uncachedExpression, failureMessage: failureMessage) } switch (result) { case let .completed(isSuccessful): return isSuccessful case .timedOut: return false case let .errorThrown(error): failureMessage.actualValue = "an unexpected error thrown: <\(error)>" return false case let .raisedException(exception): failureMessage.actualValue = "an unexpected exception thrown: <\(exception)>" return false case .blockedRunLoop: failureMessage.postfixMessage += " (timed out, but main thread was unresponsive)." return false case .incomplete: internalError("Reached .incomplete state for toEventually(...).") } } func doesNotMatch(_ actualExpression: Expression, failureMessage: FailureMessage) -> Bool { let uncachedExpression = actualExpression.withoutCaching() let result = pollBlock( pollInterval: pollInterval, timeoutInterval: timeoutInterval, file: actualExpression.location.file, line: actualExpression.location.line, fnName: "expect(...).toEventuallyNot(...)") { try self.fullMatcher.doesNotMatch(uncachedExpression, failureMessage: failureMessage) } switch (result) { case let .completed(isSuccessful): return isSuccessful case .timedOut: return false case let .errorThrown(error): failureMessage.actualValue = "an unexpected error thrown: <\(error)>" return false case let .raisedException(exception): failureMessage.actualValue = "an unexpected exception thrown: <\(exception)>" return false case .blockedRunLoop: failureMessage.postfixMessage += " (timed out, but main thread was unresponsive)." return false case .incomplete: internalError("Reached .incomplete state for toEventuallyNot(...).") } } } private let toEventuallyRequiresClosureError = FailureMessage(stringValue: "expect(...).toEventually(...) requires an explicit closure (eg - expect { ... }.toEventually(...) )\nSwift 1.2 @autoclosure behavior has changed in an incompatible way for Nimble to function") extension Expectation { /// Tests the actual value using a matcher to match by checking continuously /// at each pollInterval until the timeout is reached. /// /// @discussion /// This function manages the main run loop (`NSRunLoop.mainRunLoop()`) while this function /// is executing. Any attempts to touch the run loop may cause non-deterministic behavior. public func toEventually(_ matcher: U, timeout: TimeInterval = AsyncDefaults.Timeout, pollInterval: TimeInterval = AsyncDefaults.PollInterval, description: String? = nil) where U: Matcher, U.ValueType == T { if expression.isClosure { let (pass, msg) = expressionMatches( expression, matcher: AsyncMatcherWrapper( fullMatcher: matcher, timeoutInterval: timeout, pollInterval: pollInterval), to: "to eventually", description: description ) verify(pass, msg) } else { verify(false, toEventuallyRequiresClosureError) } } /// Tests the actual value using a matcher to not match by checking /// continuously at each pollInterval until the timeout is reached. /// /// @discussion /// This function manages the main run loop (`NSRunLoop.mainRunLoop()`) while this function /// is executing. Any attempts to touch the run loop may cause non-deterministic behavior. public func toEventuallyNot(_ matcher: U, timeout: TimeInterval = AsyncDefaults.Timeout, pollInterval: TimeInterval = AsyncDefaults.PollInterval, description: String? = nil) where U: Matcher, U.ValueType == T { if expression.isClosure { let (pass, msg) = expressionDoesNotMatch( expression, matcher: AsyncMatcherWrapper( fullMatcher: matcher, timeoutInterval: timeout, pollInterval: pollInterval), toNot: "to eventually not", description: description ) verify(pass, msg) } else { verify(false, toEventuallyRequiresClosureError) } } /// Tests the actual value using a matcher to not match by checking /// continuously at each pollInterval until the timeout is reached. /// /// Alias of toEventuallyNot() /// /// @discussion /// This function manages the main run loop (`NSRunLoop.mainRunLoop()`) while this function /// is executing. Any attempts to touch the run loop may cause non-deterministic behavior. public func toNotEventually(_ matcher: U, timeout: TimeInterval = AsyncDefaults.Timeout, pollInterval: TimeInterval = AsyncDefaults.PollInterval, description: String? = nil) where U: Matcher, U.ValueType == T { return toEventuallyNot(matcher, timeout: timeout, pollInterval: pollInterval, description: description) } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeAKindOf.swift ================================================ import Foundation #if _runtime(_ObjC) // A Nimble matcher that catches attempts to use beAKindOf with non Objective-C types public func beAKindOf(_ expectedClass: Any) -> NonNilMatcherFunc { return NonNilMatcherFunc {actualExpression, failureMessage in failureMessage.stringValue = "beAKindOf only works on Objective-C types since" + " the Swift compiler will automatically type check Swift-only types." + " This expectation is redundant." return false } } /// A Nimble matcher that succeeds when the actual value is an instance of the given class. /// @see beAnInstanceOf if you want to match against the exact class public func beAKindOf(_ expectedClass: AnyClass) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in let instance = try actualExpression.evaluate() if let validInstance = instance { failureMessage.actualValue = "<\(String(describing: type(of: validInstance))) instance>" } else { failureMessage.actualValue = "" } failureMessage.postfixMessage = "be a kind of \(String(describing: expectedClass))" return instance != nil && instance!.isKind(of: expectedClass) } } extension NMBObjCMatcher { public class func beAKindOfMatcher(_ expected: AnyClass) -> NMBMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in return try! beAKindOf(expected).matches(actualExpression, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeAnInstanceOf.swift ================================================ import Foundation // A Nimble matcher that catches attempts to use beAnInstanceOf with non Objective-C types public func beAnInstanceOf(_ expectedClass: Any) -> NonNilMatcherFunc { return NonNilMatcherFunc {actualExpression, failureMessage in failureMessage.stringValue = "beAnInstanceOf only works on Objective-C types since" + " the Swift compiler will automatically type check Swift-only types." + " This expectation is redundant." return false } } /// A Nimble matcher that succeeds when the actual value is an instance of the given class. /// @see beAKindOf if you want to match against subclasses public func beAnInstanceOf(_ expectedClass: AnyClass) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in let instance = try actualExpression.evaluate() if let validInstance = instance { failureMessage.actualValue = "<\(String(describing: type(of: validInstance))) instance>" } else { failureMessage.actualValue = "" } failureMessage.postfixMessage = "be an instance of \(String(describing: expectedClass))" #if _runtime(_ObjC) return instance != nil && instance!.isMember(of: expectedClass) #else return instance != nil && type(of: instance!) == expectedClass #endif } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beAnInstanceOfMatcher(_ expected: AnyClass) -> NMBMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in return try! beAnInstanceOf(expected).matches(actualExpression, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeCloseTo.swift ================================================ import Foundation internal let DefaultDelta = 0.0001 internal func isCloseTo(_ actualValue: NMBDoubleConvertible?, expectedValue: NMBDoubleConvertible, delta: Double, failureMessage: FailureMessage) -> Bool { failureMessage.postfixMessage = "be close to <\(stringify(expectedValue))> (within \(stringify(delta)))" failureMessage.actualValue = "<\(stringify(actualValue))>" return actualValue != nil && abs(actualValue!.doubleValue - expectedValue.doubleValue) < delta } /// A Nimble matcher that succeeds when a value is close to another. This is used for floating /// point values which can have imprecise results when doing arithmetic on them. /// /// @see equal public func beCloseTo(_ expectedValue: Double, within delta: Double = DefaultDelta) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in return isCloseTo(try actualExpression.evaluate(), expectedValue: expectedValue, delta: delta, failureMessage: failureMessage) } } /// A Nimble matcher that succeeds when a value is close to another. This is used for floating /// point values which can have imprecise results when doing arithmetic on them. /// /// @see equal public func beCloseTo(_ expectedValue: NMBDoubleConvertible, within delta: Double = DefaultDelta) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in return isCloseTo(try actualExpression.evaluate(), expectedValue: expectedValue, delta: delta, failureMessage: failureMessage) } } #if _runtime(_ObjC) public class NMBObjCBeCloseToMatcher : NSObject, NMBMatcher { var _expected: NSNumber var _delta: CDouble init(expected: NSNumber, within: CDouble) { _expected = expected _delta = within } public func matches(_ actualExpression: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool { let actualBlock: () -> NMBDoubleConvertible? = ({ return actualExpression() as? NMBDoubleConvertible }) let expr = Expression(expression: actualBlock, location: location) let matcher = beCloseTo(self._expected, within: self._delta) return try! matcher.matches(expr, failureMessage: failureMessage) } public func doesNotMatch(_ actualExpression: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool { let actualBlock: () -> NMBDoubleConvertible? = ({ return actualExpression() as? NMBDoubleConvertible }) let expr = Expression(expression: actualBlock, location: location) let matcher = beCloseTo(self._expected, within: self._delta) return try! matcher.doesNotMatch(expr, failureMessage: failureMessage) } public var within: (CDouble) -> NMBObjCBeCloseToMatcher { return ({ delta in return NMBObjCBeCloseToMatcher(expected: self._expected, within: delta) }) } } extension NMBObjCMatcher { public class func beCloseToMatcher(_ expected: NSNumber, within: CDouble) -> NMBObjCBeCloseToMatcher { return NMBObjCBeCloseToMatcher(expected: expected, within: within) } } #endif public func beCloseTo(_ expectedValues: [Double], within delta: Double = DefaultDelta) -> NonNilMatcherFunc <[Double]> { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be close to <\(stringify(expectedValues))> (each within \(stringify(delta)))" if let actual = try actualExpression.evaluate() { failureMessage.actualValue = "<\(stringify(actual))>" if actual.count != expectedValues.count { return false } else { for (index, actualItem) in actual.enumerated() { if fabs(actualItem - expectedValues[index]) > delta { return false } } return true } } return false } } // MARK: - Operators infix operator ≈ : ComparisonPrecedence public func ≈(lhs: Expectation<[Double]>, rhs: [Double]) { lhs.to(beCloseTo(rhs)) } public func ≈(lhs: Expectation, rhs: NMBDoubleConvertible) { lhs.to(beCloseTo(rhs)) } public func ≈(lhs: Expectation, rhs: (expected: NMBDoubleConvertible, delta: Double)) { lhs.to(beCloseTo(rhs.expected, within: rhs.delta)) } public func ==(lhs: Expectation, rhs: (expected: NMBDoubleConvertible, delta: Double)) { lhs.to(beCloseTo(rhs.expected, within: rhs.delta)) } // make this higher precedence than exponents so the Doubles either end aren't pulled in // unexpectantly precedencegroup PlusMinusOperatorPrecedence { higherThan: BitwiseShiftPrecedence } infix operator ± : PlusMinusOperatorPrecedence public func ±(lhs: NMBDoubleConvertible, rhs: Double) -> (expected: NMBDoubleConvertible, delta: Double) { return (expected: lhs, delta: rhs) } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeEmpty.swift ================================================ import Foundation /// A Nimble matcher that succeeds when a value is "empty". For collections, this /// means the are no items in that collection. For strings, it is an empty string. public func beEmpty() -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be empty" let actualSeq = try actualExpression.evaluate() if actualSeq == nil { return true } var generator = actualSeq!.makeIterator() return generator.next() == nil } } /// A Nimble matcher that succeeds when a value is "empty". For collections, this /// means the are no items in that collection. For strings, it is an empty string. public func beEmpty() -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be empty" let actualString = try actualExpression.evaluate() return actualString == nil || NSString(string: actualString!).length == 0 } } /// A Nimble matcher that succeeds when a value is "empty". For collections, this /// means the are no items in that collection. For NSString instances, it is an empty string. public func beEmpty() -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be empty" let actualString = try actualExpression.evaluate() return actualString == nil || actualString!.length == 0 } } // Without specific overrides, beEmpty() is ambiguous for NSDictionary, NSArray, // etc, since they conform to Sequence as well as NMBCollection. /// A Nimble matcher that succeeds when a value is "empty". For collections, this /// means the are no items in that collection. For strings, it is an empty string. public func beEmpty() -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be empty" let actualDictionary = try actualExpression.evaluate() return actualDictionary == nil || actualDictionary!.count == 0 } } /// A Nimble matcher that succeeds when a value is "empty". For collections, this /// means the are no items in that collection. For strings, it is an empty string. public func beEmpty() -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be empty" let actualArray = try actualExpression.evaluate() return actualArray == nil || actualArray!.count == 0 } } /// A Nimble matcher that succeeds when a value is "empty". For collections, this /// means the are no items in that collection. For strings, it is an empty string. public func beEmpty() -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be empty" let actual = try actualExpression.evaluate() return actual == nil || actual!.count == 0 } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beEmptyMatcher() -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let location = actualExpression.location let actualValue = try! actualExpression.evaluate() failureMessage.postfixMessage = "be empty" if let value = actualValue as? NMBCollection { let expr = Expression(expression: ({ value as NMBCollection }), location: location) return try! beEmpty().matches(expr, failureMessage: failureMessage) } else if let value = actualValue as? NSString { let expr = Expression(expression: ({ value as String }), location: location) return try! beEmpty().matches(expr, failureMessage: failureMessage) } else if let actualValue = actualValue { failureMessage.postfixMessage = "be empty (only works for NSArrays, NSSets, NSIndexSets, NSDictionaries, NSHashTables, and NSStrings)" failureMessage.actualValue = "\(String(describing: type(of: actualValue))) type" } return false } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeGreaterThan.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is greater than the expected value. public func beGreaterThan(_ expectedValue: T?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be greater than <\(stringify(expectedValue))>" if let actual = try actualExpression.evaluate(), let expected = expectedValue { return actual > expected } return false } } /// A Nimble matcher that succeeds when the actual value is greater than the expected value. public func beGreaterThan(_ expectedValue: NMBComparable?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be greater than <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() let matches = actualValue != nil && actualValue!.NMB_compare(expectedValue) == ComparisonResult.orderedDescending return matches } } public func >(lhs: Expectation, rhs: T) { lhs.to(beGreaterThan(rhs)) } public func >(lhs: Expectation, rhs: NMBComparable?) { lhs.to(beGreaterThan(rhs)) } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beGreaterThanMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let expr = actualExpression.cast { $0 as? NMBComparable } return try! beGreaterThan(expected).matches(expr, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeGreaterThanOrEqualTo.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is greater than /// or equal to the expected value. public func beGreaterThanOrEqualTo(_ expectedValue: T?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be greater than or equal to <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() if let actual = actualValue, let expected = expectedValue { return actual >= expected } return false } } /// A Nimble matcher that succeeds when the actual value is greater than /// or equal to the expected value. public func beGreaterThanOrEqualTo(_ expectedValue: T?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be greater than or equal to <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() let matches = actualValue != nil && actualValue!.NMB_compare(expectedValue) != ComparisonResult.orderedAscending return matches } } public func >=(lhs: Expectation, rhs: T) { lhs.to(beGreaterThanOrEqualTo(rhs)) } public func >=(lhs: Expectation, rhs: T) { lhs.to(beGreaterThanOrEqualTo(rhs)) } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beGreaterThanOrEqualToMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let expr = actualExpression.cast { $0 as? NMBComparable } return try! beGreaterThanOrEqualTo(expected).matches(expr, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeIdenticalTo.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is the same instance /// as the expected instance. public func beIdenticalTo(_ expected: Any?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in #if os(Linux) let actual = try actualExpression.evaluate() as? AnyObject #else let actual = try actualExpression.evaluate() as AnyObject? #endif failureMessage.actualValue = "\(identityAsString(actual))" failureMessage.postfixMessage = "be identical to \(identityAsString(expected))" #if os(Linux) return actual === (expected as? AnyObject) && actual !== nil #else return actual === (expected as AnyObject?) && actual !== nil #endif } } public func ===(lhs: Expectation, rhs: Any?) { lhs.to(beIdenticalTo(rhs)) } public func !==(lhs: Expectation, rhs: Any?) { lhs.toNot(beIdenticalTo(rhs)) } /// A Nimble matcher that succeeds when the actual value is the same instance /// as the expected instance. /// /// Alias for "beIdenticalTo". public func be(_ expected: Any?) -> NonNilMatcherFunc { return beIdenticalTo(expected) } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beIdenticalToMatcher(_ expected: NSObject?) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let aExpr = actualExpression.cast { $0 as Any? } return try! beIdenticalTo(expected).matches(aExpr, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeLessThan.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is less than the expected value. public func beLessThan(_ expectedValue: T?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be less than <\(stringify(expectedValue))>" if let actual = try actualExpression.evaluate(), let expected = expectedValue { return actual < expected } return false } } /// A Nimble matcher that succeeds when the actual value is less than the expected value. public func beLessThan(_ expectedValue: NMBComparable?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be less than <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() let matches = actualValue != nil && actualValue!.NMB_compare(expectedValue) == ComparisonResult.orderedAscending return matches } } public func <(lhs: Expectation, rhs: T) { lhs.to(beLessThan(rhs)) } public func <(lhs: Expectation, rhs: NMBComparable?) { lhs.to(beLessThan(rhs)) } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beLessThanMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let expr = actualExpression.cast { $0 as? NMBComparable } return try! beLessThan(expected).matches(expr, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeLessThanOrEqual.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is less than /// or equal to the expected value. public func beLessThanOrEqualTo(_ expectedValue: T?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be less than or equal to <\(stringify(expectedValue))>" if let actual = try actualExpression.evaluate(), let expected = expectedValue { return actual <= expected } return false } } /// A Nimble matcher that succeeds when the actual value is less than /// or equal to the expected value. public func beLessThanOrEqualTo(_ expectedValue: T?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be less than or equal to <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() return actualValue != nil && actualValue!.NMB_compare(expectedValue) != ComparisonResult.orderedDescending } } public func <=(lhs: Expectation, rhs: T) { lhs.to(beLessThanOrEqualTo(rhs)) } public func <=(lhs: Expectation, rhs: T) { lhs.to(beLessThanOrEqualTo(rhs)) } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beLessThanOrEqualToMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil:false) { actualExpression, failureMessage in let expr = actualExpression.cast { $0 as? NMBComparable } return try! beLessThanOrEqualTo(expected).matches(expr, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeLogical.swift ================================================ import Foundation extension Int8: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).int8Value } } extension UInt8: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).uint8Value } } extension Int16: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).int16Value } } extension UInt16: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).uint16Value } } extension Int32: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).int32Value } } extension UInt32: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).uint32Value } } extension Int64: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).int64Value } } extension UInt64: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).uint64Value } } extension Float: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).floatValue } } extension Double: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).doubleValue } } extension Int: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).intValue } } extension UInt: ExpressibleByBooleanLiteral { public init(booleanLiteral value: Bool) { self = NSNumber(value: value).uintValue } } internal func matcherWithFailureMessage(_ matcher: NonNilMatcherFunc, postprocessor: @escaping (FailureMessage) -> Void) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in defer { postprocessor(failureMessage) } return try matcher.matcher(actualExpression, failureMessage) } } // MARK: beTrue() / beFalse() /// A Nimble matcher that succeeds when the actual value is exactly true. /// This matcher will not match against nils. public func beTrue() -> NonNilMatcherFunc { return matcherWithFailureMessage(equal(true)) { failureMessage in failureMessage.postfixMessage = "be true" } } /// A Nimble matcher that succeeds when the actual value is exactly false. /// This matcher will not match against nils. public func beFalse() -> NonNilMatcherFunc { return matcherWithFailureMessage(equal(false)) { failureMessage in failureMessage.postfixMessage = "be false" } } // MARK: beTruthy() / beFalsy() /// A Nimble matcher that succeeds when the actual value is not logically false. public func beTruthy() -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be truthy" let actualValue = try actualExpression.evaluate() if let actualValue = actualValue { // FIXME: This is a workaround to SR-2290. // See: // - https://bugs.swift.org/browse/SR-2290 // - https://github.com/norio-nomura/Nimble/pull/5#issuecomment-237835873 if let number = actualValue as? NSNumber { return number.boolValue == true } return actualValue == (true as T) } return actualValue != nil } } /// A Nimble matcher that succeeds when the actual value is logically false. /// This matcher will match against nils. public func beFalsy() -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be falsy" let actualValue = try actualExpression.evaluate() if let actualValue = actualValue { // FIXME: This is a workaround to SR-2290. // See: // - https://bugs.swift.org/browse/SR-2290 // - https://github.com/norio-nomura/Nimble/pull/5#issuecomment-237835873 if let number = actualValue as? NSNumber { return number.boolValue == false } return actualValue == (false as T) } return actualValue == nil } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beTruthyMatcher() -> NMBObjCMatcher { return NMBObjCMatcher { actualExpression, failureMessage in let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false } return try! beTruthy().matches(expr, failureMessage: failureMessage) } } public class func beFalsyMatcher() -> NMBObjCMatcher { return NMBObjCMatcher { actualExpression, failureMessage in let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false } return try! beFalsy().matches(expr, failureMessage: failureMessage) } } public class func beTrueMatcher() -> NMBObjCMatcher { return NMBObjCMatcher { actualExpression, failureMessage in let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false } return try! beTrue().matches(expr, failureMessage: failureMessage) } } public class func beFalseMatcher() -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false } return try! beFalse().matches(expr, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeNil.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is nil. public func beNil() -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be nil" let actualValue = try actualExpression.evaluate() return actualValue == nil } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beNilMatcher() -> NMBObjCMatcher { return NMBObjCMatcher { actualExpression, failureMessage in return try! beNil().matches(actualExpression, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeVoid.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is Void. public func beVoid() -> MatcherFunc<()> { return MatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "be void" let actualValue: ()? = try actualExpression.evaluate() return actualValue != nil } } public func ==(lhs: Expectation<()>, rhs: ()) { lhs.to(beVoid()) } public func !=(lhs: Expectation<()>, rhs: ()) { lhs.toNot(beVoid()) } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/BeginWith.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual sequence's first element /// is equal to the expected value. public func beginWith(_ startingElement: T) -> NonNilMatcherFunc where S.Iterator.Element == T { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "begin with <\(startingElement)>" if let actualValue = try actualExpression.evaluate() { var actualGenerator = actualValue.makeIterator() return actualGenerator.next() == startingElement } return false } } /// A Nimble matcher that succeeds when the actual collection's first element /// is equal to the expected object. public func beginWith(_ startingElement: Any) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "begin with <\(startingElement)>" guard let collection = try actualExpression.evaluate() else { return false } guard collection.count > 0 else { return false } #if os(Linux) guard let collectionValue = collection.object(at: 0) as? NSObject else { return false } #else let collectionValue = collection.object(at: 0) as AnyObject #endif return collectionValue.isEqual(startingElement) } } /// A Nimble matcher that succeeds when the actual string contains expected substring /// where the expected substring's location is zero. public func beginWith(_ startingSubstring: String) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "begin with <\(startingSubstring)>" if let actual = try actualExpression.evaluate() { let range = actual.range(of: startingSubstring) return range != nil && range!.lowerBound == actual.startIndex } return false } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func beginWithMatcher(_ expected: Any) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let actual = try! actualExpression.evaluate() if let _ = actual as? String { let expr = actualExpression.cast { $0 as? String } return try! beginWith(expected as! String).matches(expr, failureMessage: failureMessage) } else { let expr = actualExpression.cast { $0 as? NMBOrderedCollection } return try! beginWith(expected).matches(expr, failureMessage: failureMessage) } } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/Contain.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual sequence contains the expected value. public func contain(_ items: T...) -> NonNilMatcherFunc where S.Iterator.Element == T { return contain(items) } public func contain(_ items: [T]) -> NonNilMatcherFunc where S.Iterator.Element == T { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "contain <\(arrayAsString(items))>" if let actual = try actualExpression.evaluate() { return items.all { return actual.contains($0) } } return false } } /// A Nimble matcher that succeeds when the actual string contains the expected substring. public func contain(_ substrings: String...) -> NonNilMatcherFunc { return contain(substrings) } public func contain(_ substrings: [String]) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "contain <\(arrayAsString(substrings))>" if let actual = try actualExpression.evaluate() { return substrings.all { let range = actual.range(of: $0) return range != nil && !range!.isEmpty } } return false } } /// A Nimble matcher that succeeds when the actual string contains the expected substring. public func contain(_ substrings: NSString...) -> NonNilMatcherFunc { return contain(substrings) } public func contain(_ substrings: [NSString]) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "contain <\(arrayAsString(substrings))>" if let actual = try actualExpression.evaluate() { return substrings.all { actual.range(of: $0.description).length != 0 } } return false } } /// A Nimble matcher that succeeds when the actual collection contains the expected object. public func contain(_ items: Any?...) -> NonNilMatcherFunc { return contain(items) } public func contain(_ items: [Any?]) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "contain <\(arrayAsString(items))>" guard let actual = try actualExpression.evaluate() else { return false } return items.all { item in return item != nil && actual.contains(item!) } } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func containMatcher(_ expected: [NSObject]) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let location = actualExpression.location let actualValue = try! actualExpression.evaluate() if let value = actualValue as? NMBContainer { let expr = Expression(expression: ({ value as NMBContainer }), location: location) // A straightforward cast on the array causes this to crash, so we have to cast the individual items let expectedOptionals: [Any?] = expected.map({ $0 as Any? }) return try! contain(expectedOptionals).matches(expr, failureMessage: failureMessage) } else if let value = actualValue as? NSString { let expr = Expression(expression: ({ value as String }), location: location) return try! contain(expected as! [String]).matches(expr, failureMessage: failureMessage) } else if actualValue != nil { failureMessage.postfixMessage = "contain <\(arrayAsString(expected))> (only works for NSArrays, NSSets, NSHashTables, and NSStrings)" } else { failureMessage.postfixMessage = "contain <\(arrayAsString(expected))>" } return false } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/EndWith.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual sequence's last element /// is equal to the expected value. public func endWith(_ endingElement: T) -> NonNilMatcherFunc where S.Iterator.Element == T { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "end with <\(endingElement)>" if let actualValue = try actualExpression.evaluate() { var actualGenerator = actualValue.makeIterator() var lastItem: T? var item: T? repeat { lastItem = item item = actualGenerator.next() } while(item != nil) return lastItem == endingElement } return false } } /// A Nimble matcher that succeeds when the actual collection's last element /// is equal to the expected object. public func endWith(_ endingElement: Any) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "end with <\(endingElement)>" guard let collection = try actualExpression.evaluate() else { return false } guard collection.count > 0 else { return false } #if os(Linux) guard let collectionValue = collection.object(at: collection.count - 1) as? NSObject else { return false } #else let collectionValue = collection.object(at: collection.count - 1) as AnyObject #endif return collectionValue.isEqual(endingElement) } } /// A Nimble matcher that succeeds when the actual string contains the expected substring /// where the expected substring's location is the actual string's length minus the /// expected substring's length. public func endWith(_ endingSubstring: String) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "end with <\(endingSubstring)>" if let collection = try actualExpression.evaluate() { return collection.hasSuffix(endingSubstring) } return false } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func endWithMatcher(_ expected: Any) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let actual = try! actualExpression.evaluate() if let _ = actual as? String { let expr = actualExpression.cast { $0 as? String } return try! endWith(expected as! String).matches(expr, failureMessage: failureMessage) } else { let expr = actualExpression.cast { $0 as? NMBOrderedCollection } return try! endWith(expected).matches(expr, failureMessage: failureMessage) } } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/Equal.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value is equal to the expected value. /// Values can support equal by supporting the Equatable protocol. /// /// @see beCloseTo if you want to match imprecise types (eg - floats, doubles). public func equal(_ expectedValue: T?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "equal <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() let matches = actualValue == expectedValue && expectedValue != nil if expectedValue == nil || actualValue == nil { if expectedValue == nil { failureMessage.postfixActual = " (use beNil() to match nils)" } return false } return matches } } /// A Nimble matcher that succeeds when the actual value is equal to the expected value. /// Values can support equal by supporting the Equatable protocol. /// /// @see beCloseTo if you want to match imprecise types (eg - floats, doubles). public func equal(_ expectedValue: [T: C]?) -> NonNilMatcherFunc<[T: C]> { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "equal <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() if expectedValue == nil || actualValue == nil { if expectedValue == nil { failureMessage.postfixActual = " (use beNil() to match nils)" } return false } return expectedValue! == actualValue! } } /// A Nimble matcher that succeeds when the actual collection is equal to the expected collection. /// Items must implement the Equatable protocol. public func equal(_ expectedValue: [T]?) -> NonNilMatcherFunc<[T]> { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "equal <\(stringify(expectedValue))>" let actualValue = try actualExpression.evaluate() if expectedValue == nil || actualValue == nil { if expectedValue == nil { failureMessage.postfixActual = " (use beNil() to match nils)" } return false } return expectedValue! == actualValue! } } /// A Nimble matcher allowing comparison of collection with optional type public func equal(_ expectedValue: [T?]) -> NonNilMatcherFunc<[T?]> { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "equal <\(stringify(expectedValue))>" if let actualValue = try actualExpression.evaluate() { if expectedValue.count != actualValue.count { return false } for (index, item) in actualValue.enumerated() { let otherItem = expectedValue[index] if item == nil && otherItem == nil { continue } else if item == nil && otherItem != nil { return false } else if item != nil && otherItem == nil { return false } else if item! != otherItem! { return false } } return true } else { failureMessage.postfixActual = " (use beNil() to match nils)" } return false } } /// A Nimble matcher that succeeds when the actual set is equal to the expected set. public func equal(_ expectedValue: Set?) -> NonNilMatcherFunc> { return equal(expectedValue, stringify: { stringify($0) }) } /// A Nimble matcher that succeeds when the actual set is equal to the expected set. public func equal(_ expectedValue: Set?) -> NonNilMatcherFunc> { return equal(expectedValue, stringify: { if let set = $0 { return stringify(Array(set).sorted { $0 < $1 }) } else { return "nil" } }) } private func equal(_ expectedValue: Set?, stringify: @escaping (Set?) -> String) -> NonNilMatcherFunc> { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "equal <\(stringify(expectedValue))>" if let expectedValue = expectedValue { if let actualValue = try actualExpression.evaluate() { failureMessage.actualValue = "<\(stringify(actualValue))>" if expectedValue == actualValue { return true } let missing = expectedValue.subtracting(actualValue) if missing.count > 0 { failureMessage.postfixActual += ", missing <\(stringify(missing))>" } let extra = actualValue.subtracting(expectedValue) if extra.count > 0 { failureMessage.postfixActual += ", extra <\(stringify(extra))>" } } } else { failureMessage.postfixActual = " (use beNil() to match nils)" } return false } } public func ==(lhs: Expectation, rhs: T?) { lhs.to(equal(rhs)) } public func !=(lhs: Expectation, rhs: T?) { lhs.toNot(equal(rhs)) } public func ==(lhs: Expectation<[T]>, rhs: [T]?) { lhs.to(equal(rhs)) } public func !=(lhs: Expectation<[T]>, rhs: [T]?) { lhs.toNot(equal(rhs)) } public func ==(lhs: Expectation>, rhs: Set?) { lhs.to(equal(rhs)) } public func !=(lhs: Expectation>, rhs: Set?) { lhs.toNot(equal(rhs)) } public func ==(lhs: Expectation>, rhs: Set?) { lhs.to(equal(rhs)) } public func !=(lhs: Expectation>, rhs: Set?) { lhs.toNot(equal(rhs)) } public func ==(lhs: Expectation<[T: C]>, rhs: [T: C]?) { lhs.to(equal(rhs)) } public func !=(lhs: Expectation<[T: C]>, rhs: [T: C]?) { lhs.toNot(equal(rhs)) } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func equalMatcher(_ expected: NSObject) -> NMBMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in return try! equal(expected).matches(actualExpression, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/HaveCount.swift ================================================ import Foundation // The `haveCount` matchers do not print the full string representation of the collection value, // instead they only print the type name and the expected count. This makes it easier to understand // the reason for failed expectations. See: https://github.com/Quick/Nimble/issues/308. // The representation of the collection content is provided in a new line as an `extendedMessage`. /// A Nimble matcher that succeeds when the actual Collection's count equals /// the expected value public func haveCount(_ expectedValue: T.IndexDistance) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in if let actualValue = try actualExpression.evaluate() { failureMessage.postfixMessage = "have \(prettyCollectionType(actualValue)) with count \(stringify(expectedValue))" let result = expectedValue == actualValue.count failureMessage.actualValue = "\(actualValue.count)" failureMessage.extendedMessage = "Actual Value: \(stringify(actualValue))" return result } else { return false } } } /// A Nimble matcher that succeeds when the actual collection's count equals /// the expected value public func haveCount(_ expectedValue: Int) -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in if let actualValue = try actualExpression.evaluate() { failureMessage.postfixMessage = "have \(prettyCollectionType(actualValue)) with count \(stringify(expectedValue))" let result = expectedValue == actualValue.count failureMessage.actualValue = "\(actualValue.count)" failureMessage.extendedMessage = "Actual Value: \(stringify(actualValue))" return result } else { return false } } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func haveCountMatcher(_ expected: NSNumber) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let location = actualExpression.location let actualValue = try! actualExpression.evaluate() if let value = actualValue as? NMBCollection { let expr = Expression(expression: ({ value as NMBCollection}), location: location) return try! haveCount(expected.intValue).matches(expr, failureMessage: failureMessage) } else if let actualValue = actualValue { failureMessage.postfixMessage = "get type of NSArray, NSSet, NSDictionary, or NSHashTable" failureMessage.actualValue = "\(String(describing: type(of: actualValue)))" } return false } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/Match.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual string satisfies the regular expression /// described by the expected string. public func match(_ expectedValue: String?) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in failureMessage.postfixMessage = "match <\(stringify(expectedValue))>" if let actual = try actualExpression.evaluate() { if let regexp = expectedValue { return actual.range(of: regexp, options: .regularExpression) != nil } } return false } } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func matchMatcher(_ expected: NSString) -> NMBMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in let actual = actualExpression.cast { $0 as? String } return try! match(expected.description).matches(actual, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/MatchError.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual expression evaluates to an /// error from the specified case. /// /// Errors are tried to be compared by their implementation of Equatable, /// otherwise they fallback to comparision by _domain and _code. public func matchError(_ error: T) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in let actualError: Error? = try actualExpression.evaluate() setFailureMessageForError(failureMessage, postfixMessageVerb: "match", actualError: actualError, error: error) return errorMatchesNonNilFieldsOrClosure(actualError, error: error) } } /// A Nimble matcher that succeeds when the actual expression evaluates to an /// error of the specified type public func matchError(_ errorType: T.Type) -> NonNilMatcherFunc { return NonNilMatcherFunc { actualExpression, failureMessage in let actualError: Error? = try actualExpression.evaluate() setFailureMessageForError(failureMessage, postfixMessageVerb: "match", actualError: actualError, errorType: errorType) return errorMatchesNonNilFieldsOrClosure(actualError, errorType: errorType) } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/MatcherFunc.swift ================================================ /// A convenience API to build matchers that don't need special negation /// behavior. The toNot() behavior is the negation of to(). /// /// @see NonNilMatcherFunc if you prefer to have this matcher fail when nil /// values are recieved in an expectation. /// /// You may use this when implementing your own custom matchers. /// /// Use the Matcher protocol instead of this type to accept custom matchers as /// input parameters. /// @see allPass for an example that uses accepts other matchers as input. public struct MatcherFunc: Matcher { public let matcher: (Expression, FailureMessage) throws -> Bool public init(_ matcher: @escaping (Expression, FailureMessage) throws -> Bool) { self.matcher = matcher } public func matches(_ actualExpression: Expression, failureMessage: FailureMessage) throws -> Bool { return try matcher(actualExpression, failureMessage) } public func doesNotMatch(_ actualExpression: Expression, failureMessage: FailureMessage) throws -> Bool { return try !matcher(actualExpression, failureMessage) } } /// A convenience API to build matchers that don't need special negation /// behavior. The toNot() behavior is the negation of to(). /// /// Unlike MatcherFunc, this will always fail if an expectation contains nil. /// This applies regardless of using to() or toNot(). /// /// You may use this when implementing your own custom matchers. /// /// Use the Matcher protocol instead of this type to accept custom matchers as /// input parameters. /// @see allPass for an example that uses accepts other matchers as input. public struct NonNilMatcherFunc: Matcher { public let matcher: (Expression, FailureMessage) throws -> Bool public init(_ matcher: @escaping (Expression, FailureMessage) throws -> Bool) { self.matcher = matcher } public func matches(_ actualExpression: Expression, failureMessage: FailureMessage) throws -> Bool { let pass = try matcher(actualExpression, failureMessage) if try attachNilErrorIfNeeded(actualExpression, failureMessage: failureMessage) { return false } return pass } public func doesNotMatch(_ actualExpression: Expression, failureMessage: FailureMessage) throws -> Bool { let pass = try !matcher(actualExpression, failureMessage) if try attachNilErrorIfNeeded(actualExpression, failureMessage: failureMessage) { return false } return pass } internal func attachNilErrorIfNeeded(_ actualExpression: Expression, failureMessage: FailureMessage) throws -> Bool { if try actualExpression.evaluate() == nil { failureMessage.postfixActual = " (use beNil() to match nils)" return true } return false } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/MatcherProtocols.swift ================================================ import Foundation // `CGFloat` is in Foundation (swift-corelibs-foundation) on Linux. #if _runtime(_ObjC) import CoreGraphics #endif /// Implement this protocol to implement a custom matcher for Swift public protocol Matcher { associatedtype ValueType func matches(_ actualExpression: Expression, failureMessage: FailureMessage) throws -> Bool func doesNotMatch(_ actualExpression: Expression, failureMessage: FailureMessage) throws -> Bool } #if _runtime(_ObjC) /// Objective-C interface to the Swift variant of Matcher. @objc public protocol NMBMatcher { func matches(_ actualBlock: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool func doesNotMatch(_ actualBlock: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool } #endif #if _runtime(_ObjC) /// Protocol for types that support contain() matcher. @objc public protocol NMBContainer { @objc(containsObject:) func contains(_ anObject: Any) -> Bool } // FIXME: NSHashTable can not conform to NMBContainer since swift-DEVELOPMENT-SNAPSHOT-2016-04-25-a //extension NSHashTable : NMBContainer {} // Corelibs Foundation does not include this class yet #else public protocol NMBContainer { func contains(_ anObject: Any) -> Bool } #endif extension NSArray : NMBContainer {} extension NSSet : NMBContainer {} #if _runtime(_ObjC) /// Protocol for types that support only beEmpty(), haveCount() matchers @objc public protocol NMBCollection { var count: Int { get } } extension NSHashTable : NMBCollection {} // Corelibs Foundation does not include these classes yet extension NSMapTable : NMBCollection {} #else public protocol NMBCollection { var count: Int { get } } #endif extension NSSet : NMBCollection {} extension NSIndexSet : NMBCollection {} extension NSDictionary : NMBCollection {} #if _runtime(_ObjC) /// Protocol for types that support beginWith(), endWith(), beEmpty() matchers @objc public protocol NMBOrderedCollection : NMBCollection { @objc(objectAtIndex:) func object(at index: Int) -> Any } #else public protocol NMBOrderedCollection : NMBCollection { func object(at index: Int) -> Any } #endif extension NSArray : NMBOrderedCollection {} public protocol NMBDoubleConvertible { var doubleValue: CDouble { get } } extension Double : NMBDoubleConvertible { public var doubleValue: CDouble { return self } } extension Float : NMBDoubleConvertible { public var doubleValue: CDouble { return CDouble(self) } } extension CGFloat: NMBDoubleConvertible { public var doubleValue: CDouble { return CDouble(self) } } extension NSNumber : NMBDoubleConvertible { } private let dateFormatter: DateFormatter = { let formatter = DateFormatter() formatter.dateFormat = "yyyy-MM-dd HH:mm:ss.SSSS" formatter.locale = Locale(identifier: "en_US_POSIX") return formatter }() extension Date: NMBDoubleConvertible { public var doubleValue: CDouble { return self.timeIntervalSinceReferenceDate } } extension NSDate: NMBDoubleConvertible { public var doubleValue: CDouble { return self.timeIntervalSinceReferenceDate } } extension Date: TestOutputStringConvertible { public var testDescription: String { return dateFormatter.string(from: self) } } extension NSDate: TestOutputStringConvertible { public var testDescription: String { return dateFormatter.string(from: Date(timeIntervalSinceReferenceDate: self.timeIntervalSinceReferenceDate)) } } /// Protocol for types to support beLessThan(), beLessThanOrEqualTo(), /// beGreaterThan(), beGreaterThanOrEqualTo(), and equal() matchers. /// /// Types that conform to Swift's Comparable protocol will work implicitly too #if _runtime(_ObjC) @objc public protocol NMBComparable { func NMB_compare(_ otherObject: NMBComparable!) -> ComparisonResult } #else // This should become obsolete once Corelibs Foundation adds Comparable conformance to NSNumber public protocol NMBComparable { func NMB_compare(_ otherObject: NMBComparable!) -> ComparisonResult } #endif extension NSNumber : NMBComparable { public func NMB_compare(_ otherObject: NMBComparable!) -> ComparisonResult { return compare(otherObject as! NSNumber) } } extension NSString : NMBComparable { public func NMB_compare(_ otherObject: NMBComparable!) -> ComparisonResult { return compare(otherObject as! String) } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/PostNotification.swift ================================================ import Foundation internal class NotificationCollector { private(set) var observedNotifications: [Notification] private let notificationCenter: NotificationCenter #if _runtime(_ObjC) private var token: AnyObject? #else private var token: NSObjectProtocol? #endif required init(notificationCenter: NotificationCenter) { self.notificationCenter = notificationCenter self.observedNotifications = [] } func startObserving() { self.token = self.notificationCenter.addObserver(forName: nil, object: nil, queue: nil) { // linux-swift gets confused by .append(n) [weak self] n in self?.observedNotifications.append(n) } } deinit { #if _runtime(_ObjC) if let token = self.token { self.notificationCenter.removeObserver(token) } #else if let token = self.token as? AnyObject { self.notificationCenter.removeObserver(token) } #endif } } private let mainThread = pthread_self() let notificationCenterDefault = NotificationCenter.default public func postNotifications( _ notificationsMatcher: T, fromNotificationCenter center: NotificationCenter = notificationCenterDefault) -> MatcherFunc where T: Matcher, T.ValueType == [Notification] { let _ = mainThread // Force lazy-loading of this value let collector = NotificationCollector(notificationCenter: center) collector.startObserving() var once: Bool = false return MatcherFunc { actualExpression, failureMessage in let collectorNotificationsExpression = Expression(memoizedExpression: { _ in return collector.observedNotifications }, location: actualExpression.location, withoutCaching: true) assert(pthread_equal(mainThread, pthread_self()) != 0, "Only expecting closure to be evaluated on main thread.") if !once { once = true _ = try actualExpression.evaluate() } let match = try notificationsMatcher.matches(collectorNotificationsExpression, failureMessage: failureMessage) if collector.observedNotifications.isEmpty { failureMessage.actualValue = "no notifications" } else { failureMessage.actualValue = "<\(stringify(collector.observedNotifications))>" } return match } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/RaisesException.swift ================================================ import Foundation // This matcher requires the Objective-C, and being built by Xcode rather than the Swift Package Manager #if _runtime(_ObjC) && !SWIFT_PACKAGE /// A Nimble matcher that succeeds when the actual expression raises an /// exception with the specified name, reason, and/or userInfo. /// /// Alternatively, you can pass a closure to do any arbitrary custom matching /// to the raised exception. The closure only gets called when an exception /// is raised. /// /// nil arguments indicates that the matcher should not attempt to match against /// that parameter. public func raiseException( named: String? = nil, reason: String? = nil, userInfo: NSDictionary? = nil, closure: ((NSException) -> Void)? = nil) -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in var exception: NSException? let capture = NMBExceptionCapture(handler: ({ e in exception = e }), finally: nil) capture.tryBlock { _ = try! actualExpression.evaluate() return } setFailureMessageForException(failureMessage, exception: exception, named: named, reason: reason, userInfo: userInfo, closure: closure) return exceptionMatchesNonNilFieldsOrClosure(exception, named: named, reason: reason, userInfo: userInfo, closure: closure) } } internal func setFailureMessageForException( _ failureMessage: FailureMessage, exception: NSException?, named: String?, reason: String?, userInfo: NSDictionary?, closure: ((NSException) -> Void)?) { failureMessage.postfixMessage = "raise exception" if let named = named { failureMessage.postfixMessage += " with name <\(named)>" } if let reason = reason { failureMessage.postfixMessage += " with reason <\(reason)>" } if let userInfo = userInfo { failureMessage.postfixMessage += " with userInfo <\(userInfo)>" } if let _ = closure { failureMessage.postfixMessage += " that satisfies block" } if named == nil && reason == nil && userInfo == nil && closure == nil { failureMessage.postfixMessage = "raise any exception" } if let exception = exception { failureMessage.actualValue = "\(String(describing: type(of: exception))) { name=\(exception.name), reason='\(stringify(exception.reason))', userInfo=\(stringify(exception.userInfo)) }" } else { failureMessage.actualValue = "no exception" } } internal func exceptionMatchesNonNilFieldsOrClosure( _ exception: NSException?, named: String?, reason: String?, userInfo: NSDictionary?, closure: ((NSException) -> Void)?) -> Bool { var matches = false if let exception = exception { matches = true if let named = named, exception.name.rawValue != named { matches = false } if reason != nil && exception.reason != reason { matches = false } if let userInfo = userInfo, let exceptionUserInfo = exception.userInfo, (exceptionUserInfo as NSDictionary) != userInfo { matches = false } if let closure = closure { let assertions = gatherFailingExpectations { closure(exception) } let messages = assertions.map { $0.message } if messages.count > 0 { matches = false } } } return matches } public class NMBObjCRaiseExceptionMatcher : NSObject, NMBMatcher { internal var _name: String? internal var _reason: String? internal var _userInfo: NSDictionary? internal var _block: ((NSException) -> Void)? internal init(name: String?, reason: String?, userInfo: NSDictionary?, block: ((NSException) -> Void)?) { _name = name _reason = reason _userInfo = userInfo _block = block } public func matches(_ actualBlock: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool { let block: () -> Any? = ({ _ = actualBlock(); return nil }) let expr = Expression(expression: block, location: location) return try! raiseException( named: _name, reason: _reason, userInfo: _userInfo, closure: _block ).matches(expr, failureMessage: failureMessage) } public func doesNotMatch(_ actualBlock: @escaping () -> NSObject!, failureMessage: FailureMessage, location: SourceLocation) -> Bool { return !matches(actualBlock, failureMessage: failureMessage, location: location) } public var named: (_ name: String) -> NMBObjCRaiseExceptionMatcher { return ({ name in return NMBObjCRaiseExceptionMatcher( name: name, reason: self._reason, userInfo: self._userInfo, block: self._block ) }) } public var reason: (_ reason: String?) -> NMBObjCRaiseExceptionMatcher { return ({ reason in return NMBObjCRaiseExceptionMatcher( name: self._name, reason: reason, userInfo: self._userInfo, block: self._block ) }) } public var userInfo: (_ userInfo: NSDictionary?) -> NMBObjCRaiseExceptionMatcher { return ({ userInfo in return NMBObjCRaiseExceptionMatcher( name: self._name, reason: self._reason, userInfo: userInfo, block: self._block ) }) } public var satisfyingBlock: (_ block: ((NSException) -> Void)?) -> NMBObjCRaiseExceptionMatcher { return ({ block in return NMBObjCRaiseExceptionMatcher( name: self._name, reason: self._reason, userInfo: self._userInfo, block: block ) }) } } extension NMBObjCMatcher { public class func raiseExceptionMatcher() -> NMBObjCRaiseExceptionMatcher { return NMBObjCRaiseExceptionMatcher(name: nil, reason: nil, userInfo: nil, block: nil) } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/SatisfyAnyOf.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual value matches with any of the matchers /// provided in the variable list of matchers. public func satisfyAnyOf(_ matchers: U...) -> NonNilMatcherFunc where U: Matcher, U.ValueType == T { return satisfyAnyOf(matchers) } internal func satisfyAnyOf(_ matchers: [U]) -> NonNilMatcherFunc where U: Matcher, U.ValueType == T { return NonNilMatcherFunc { actualExpression, failureMessage in let postfixMessages = NSMutableArray() var matches = false for matcher in matchers { if try matcher.matches(actualExpression, failureMessage: failureMessage) { matches = true } postfixMessages.add(NSString(string: "{\(failureMessage.postfixMessage)}")) } failureMessage.postfixMessage = "match one of: " + postfixMessages.componentsJoined(by: ", or ") if let actualValue = try actualExpression.evaluate() { failureMessage.actualValue = "\(actualValue)" } return matches } } public func ||(left: NonNilMatcherFunc, right: NonNilMatcherFunc) -> NonNilMatcherFunc { return satisfyAnyOf(left, right) } public func ||(left: MatcherFunc, right: MatcherFunc) -> NonNilMatcherFunc { return satisfyAnyOf(left, right) } #if _runtime(_ObjC) extension NMBObjCMatcher { public class func satisfyAnyOfMatcher(_ matchers: [NMBObjCMatcher]) -> NMBObjCMatcher { return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in if matchers.isEmpty { failureMessage.stringValue = "satisfyAnyOf must be called with at least one matcher" return false } var elementEvaluators = [NonNilMatcherFunc]() for matcher in matchers { let elementEvaluator: (Expression, FailureMessage) -> Bool = { expression, failureMessage in return matcher.matches( {try! expression.evaluate()}, failureMessage: failureMessage, location: actualExpression.location) } elementEvaluators.append(NonNilMatcherFunc(elementEvaluator)) } return try! satisfyAnyOf(elementEvaluators).matches(actualExpression, failureMessage: failureMessage) } } } #endif ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/ThrowAssertion.swift ================================================ import Foundation public func throwAssertion() -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in #if arch(x86_64) && _runtime(_ObjC) && !SWIFT_PACKAGE failureMessage.postfixMessage = "throw an assertion" failureMessage.actualValue = nil var succeeded = true let caughtException: BadInstructionException? = catchBadInstruction { #if os(tvOS) if (!NimbleEnvironment.activeInstance.suppressTVOSAssertionWarning) { print() print("[Nimble Warning]: If you're getting stuck on a debugger breakpoint for a " + "fatal error while using throwAssertion(), please disable 'Debug Executable' " + "in your scheme. Go to 'Edit Scheme > Test > Info' and uncheck " + "'Debug Executable'. If you've already done that, suppress this warning " + "by setting `NimbleEnvironment.activeInstance.suppressTVOSAssertionWarning = true`. " + "This is required because the standard methods of catching assertions " + "(mach APIs) are unavailable for tvOS. Instead, the same mechanism the " + "debugger uses is the fallback method for tvOS." ) print() NimbleEnvironment.activeInstance.suppressTVOSAssertionWarning = true } #endif do { try actualExpression.evaluate() } catch let error { succeeded = false failureMessage.postfixMessage += "; threw error instead <\(error)>" } } if !succeeded { return false } if caughtException == nil { return false } return true #elseif SWIFT_PACKAGE fatalError("The throwAssertion Nimble matcher does not currently support Swift CLI." + " You can silence this error by placing the test case inside an #if !SWIFT_PACKAGE" + " conditional statement") #else fatalError("The throwAssertion Nimble matcher can only run on x86_64 platforms with " + "Objective-C (e.g. Mac, iPhone 5s or later simulators). You can silence this error " + "by placing the test case inside an #if arch(x86_64) or _runtime(_ObjC) conditional statement") #endif } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Matchers/ThrowError.swift ================================================ import Foundation /// A Nimble matcher that succeeds when the actual expression throws an /// error of the specified type or from the specified case. /// /// Errors are tried to be compared by their implementation of Equatable, /// otherwise they fallback to comparision by _domain and _code. /// /// Alternatively, you can pass a closure to do any arbitrary custom matching /// to the thrown error. The closure only gets called when an error was thrown. /// /// nil arguments indicates that the matcher should not attempt to match against /// that parameter. public func throwError( _ error: T? = nil, errorType: T.Type? = nil, closure: ((T) -> Void)? = nil) -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in var actualError: Error? do { _ = try actualExpression.evaluate() } catch let catchedError { actualError = catchedError } setFailureMessageForError(failureMessage, actualError: actualError, error: error, errorType: errorType, closure: closure) return errorMatchesNonNilFieldsOrClosure(actualError, error: error, errorType: errorType, closure: closure) } } /// A Nimble matcher that succeeds when the actual expression throws any /// error or when the passed closures' arbitrary custom matching succeeds. /// /// This duplication to it's generic adequate is required to allow to receive /// values of the existential type `Error` in the closure. /// /// The closure only gets called when an error was thrown. public func throwError( closure: ((Error) -> Void)? = nil) -> MatcherFunc { return MatcherFunc { actualExpression, failureMessage in var actualError: Error? do { _ = try actualExpression.evaluate() } catch let catchedError { actualError = catchedError } setFailureMessageForError(failureMessage, actualError: actualError, closure: closure) return errorMatchesNonNilFieldsOrClosure(actualError, closure: closure) } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Nimble.h ================================================ #import #import "NMBExceptionCapture.h" #import "NMBStringify.h" #import "DSL.h" #import "CwlCatchException.h" #import "CwlCatchBadInstruction.h" #if !TARGET_OS_TV #import "mach_excServer.h" #endif FOUNDATION_EXPORT double NimbleVersionNumber; FOUNDATION_EXPORT const unsigned char NimbleVersionString[]; ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Utils/Async.swift ================================================ import CoreFoundation import Dispatch import Foundation #if !_runtime(_ObjC) import CDispatch #endif private let timeoutLeeway = DispatchTimeInterval.milliseconds(1) private let pollLeeway = DispatchTimeInterval.milliseconds(1) /// Stores debugging information about callers internal struct WaitingInfo: CustomStringConvertible { let name: String let file: FileString let lineNumber: UInt var description: String { return "\(name) at \(file):\(lineNumber)" } } internal protocol WaitLock { func acquireWaitingLock(_ fnName: String, file: FileString, line: UInt) func releaseWaitingLock() func isWaitingLocked() -> Bool } internal class AssertionWaitLock: WaitLock { private var currentWaiter: WaitingInfo? = nil init() { } func acquireWaitingLock(_ fnName: String, file: FileString, line: UInt) { let info = WaitingInfo(name: fnName, file: file, lineNumber: line) #if _runtime(_ObjC) let isMainThread = Thread.isMainThread #else let isMainThread = _CFIsMainThread() #endif nimblePrecondition( isMainThread, "InvalidNimbleAPIUsage", "\(fnName) can only run on the main thread." ) nimblePrecondition( currentWaiter == nil, "InvalidNimbleAPIUsage", "Nested async expectations are not allowed to avoid creating flaky tests.\n\n" + "The call to\n\t\(info)\n" + "triggered this exception because\n\t\(currentWaiter!)\n" + "is currently managing the main run loop." ) currentWaiter = info } func isWaitingLocked() -> Bool { return currentWaiter != nil } func releaseWaitingLock() { currentWaiter = nil } } internal enum AwaitResult { /// Incomplete indicates None (aka - this value hasn't been fulfilled yet) case incomplete /// TimedOut indicates the result reached its defined timeout limit before returning case timedOut /// BlockedRunLoop indicates the main runloop is too busy processing other blocks to trigger /// the timeout code. /// /// This may also mean the async code waiting upon may have never actually ran within the /// required time because other timers & sources are running on the main run loop. case blockedRunLoop /// The async block successfully executed and returned a given result case completed(T) /// When a Swift Error is thrown case errorThrown(Error) /// When an Objective-C Exception is raised case raisedException(NSException) func isIncomplete() -> Bool { switch self { case .incomplete: return true default: return false } } func isCompleted() -> Bool { switch self { case .completed(_): return true default: return false } } } /// Holds the resulting value from an asynchronous expectation. /// This class is thread-safe at receiving an "response" to this promise. internal class AwaitPromise { private(set) internal var asyncResult: AwaitResult = .incomplete private var signal: DispatchSemaphore init() { signal = DispatchSemaphore(value: 1) } /// Resolves the promise with the given result if it has not been resolved. Repeated calls to /// this method will resolve in a no-op. /// /// @returns a Bool that indicates if the async result was accepted or rejected because another /// value was recieved first. func resolveResult(_ result: AwaitResult) -> Bool { if signal.wait(timeout: .now()) == .success { self.asyncResult = result return true } else { return false } } } internal struct AwaitTrigger { let timeoutSource: DispatchSourceTimer let actionSource: DispatchSourceTimer? let start: () throws -> Void } /// Factory for building fully configured AwaitPromises and waiting for their results. /// /// This factory stores all the state for an async expectation so that Await doesn't /// doesn't have to manage it. internal class AwaitPromiseBuilder { let awaiter: Awaiter let waitLock: WaitLock let trigger: AwaitTrigger let promise: AwaitPromise internal init( awaiter: Awaiter, waitLock: WaitLock, promise: AwaitPromise, trigger: AwaitTrigger) { self.awaiter = awaiter self.waitLock = waitLock self.promise = promise self.trigger = trigger } func timeout(_ timeoutInterval: TimeInterval, forcefullyAbortTimeout: TimeInterval) -> Self { // = Discussion = // // There's a lot of technical decisions here that is useful to elaborate on. This is // definitely more lower-level than the previous NSRunLoop based implementation. // // // Why Dispatch Source? // // // We're using a dispatch source to have better control of the run loop behavior. // A timer source gives us deferred-timing control without having to rely as much on // a run loop's traditional dispatching machinery (eg - NSTimers, DefaultRunLoopMode, etc.) // which is ripe for getting corrupted by application code. // // And unlike dispatch_async(), we can control how likely our code gets prioritized to // executed (see leeway parameter) + DISPATCH_TIMER_STRICT. // // This timer is assumed to run on the HIGH priority queue to ensure it maintains the // highest priority over normal application / test code when possible. // // // Run Loop Management // // In order to properly interrupt the waiting behavior performed by this factory class, // this timer stops the main run loop to tell the waiter code that the result should be // checked. // // In addition, stopping the run loop is used to halt code executed on the main run loop. trigger.timeoutSource.scheduleOneshot( deadline: DispatchTime.now() + timeoutInterval, leeway: timeoutLeeway) trigger.timeoutSource.setEventHandler() { guard self.promise.asyncResult.isIncomplete() else { return } let timedOutSem = DispatchSemaphore(value: 0) let semTimedOutOrBlocked = DispatchSemaphore(value: 0) semTimedOutOrBlocked.signal() let runLoop = CFRunLoopGetMain() #if _runtime(_ObjC) let runLoopMode = CFRunLoopMode.defaultMode.rawValue #else let runLoopMode = kCFRunLoopDefaultMode #endif CFRunLoopPerformBlock(runLoop, runLoopMode) { if semTimedOutOrBlocked.wait(timeout: .now()) == .success { timedOutSem.signal() semTimedOutOrBlocked.signal() if self.promise.resolveResult(.timedOut) { CFRunLoopStop(CFRunLoopGetMain()) } } } // potentially interrupt blocking code on run loop to let timeout code run CFRunLoopStop(runLoop) let now = DispatchTime.now() + forcefullyAbortTimeout let didNotTimeOut = timedOutSem.wait(timeout: now) != .success let timeoutWasNotTriggered = semTimedOutOrBlocked.wait(timeout: .now()) == .success if didNotTimeOut && timeoutWasNotTriggered { if self.promise.resolveResult(.blockedRunLoop) { CFRunLoopStop(CFRunLoopGetMain()) } } } return self } /// Blocks for an asynchronous result. /// /// @discussion /// This function must be executed on the main thread and cannot be nested. This is because /// this function (and it's related methods) coordinate through the main run loop. Tampering /// with the run loop can cause undesireable behavior. /// /// This method will return an AwaitResult in the following cases: /// /// - The main run loop is blocked by other operations and the async expectation cannot be /// be stopped. /// - The async expectation timed out /// - The async expectation succeeded /// - The async expectation raised an unexpected exception (objc) /// - The async expectation raised an unexpected error (swift) /// /// The returned AwaitResult will NEVER be .incomplete. func wait(_ fnName: String = #function, file: FileString = #file, line: UInt = #line) -> AwaitResult { waitLock.acquireWaitingLock( fnName, file: file, line: line) let capture = NMBExceptionCapture(handler: ({ exception in _ = self.promise.resolveResult(.raisedException(exception)) }), finally: ({ self.waitLock.releaseWaitingLock() })) capture.tryBlock { do { try self.trigger.start() } catch let error { _ = self.promise.resolveResult(.errorThrown(error)) } self.trigger.timeoutSource.resume() while self.promise.asyncResult.isIncomplete() { // Stopping the run loop does not work unless we run only 1 mode _ = RunLoop.current.run(mode: .defaultRunLoopMode, before: .distantFuture) } self.trigger.timeoutSource.suspend() self.trigger.timeoutSource.cancel() if let asyncSource = self.trigger.actionSource { asyncSource.cancel() } } return promise.asyncResult } } internal class Awaiter { let waitLock: WaitLock let timeoutQueue: DispatchQueue let asyncQueue: DispatchQueue internal init( waitLock: WaitLock, asyncQueue: DispatchQueue, timeoutQueue: DispatchQueue) { self.waitLock = waitLock self.asyncQueue = asyncQueue self.timeoutQueue = timeoutQueue } private func createTimerSource(_ queue: DispatchQueue) -> DispatchSourceTimer { return DispatchSource.makeTimerSource(flags: .strict, queue: queue) } func performBlock( _ closure: @escaping (@escaping (T) -> Void) throws -> Void) -> AwaitPromiseBuilder { let promise = AwaitPromise() let timeoutSource = createTimerSource(timeoutQueue) var completionCount = 0 let trigger = AwaitTrigger(timeoutSource: timeoutSource, actionSource: nil) { try closure() { completionCount += 1 nimblePrecondition( completionCount < 2, "InvalidNimbleAPIUsage", "Done closure's was called multiple times. waitUntil(..) expects its " + "completion closure to only be called once.") if promise.resolveResult(.completed($0)) { CFRunLoopStop(CFRunLoopGetMain()) } } } return AwaitPromiseBuilder( awaiter: self, waitLock: waitLock, promise: promise, trigger: trigger) } func poll(_ pollInterval: TimeInterval, closure: @escaping () throws -> T?) -> AwaitPromiseBuilder { let promise = AwaitPromise() let timeoutSource = createTimerSource(timeoutQueue) let asyncSource = createTimerSource(asyncQueue) let trigger = AwaitTrigger(timeoutSource: timeoutSource, actionSource: asyncSource) { let interval = DispatchTimeInterval.nanoseconds(Int(pollInterval * TimeInterval(NSEC_PER_SEC))) asyncSource.scheduleRepeating(deadline: .now(), interval: interval, leeway: pollLeeway) asyncSource.setEventHandler() { do { if let result = try closure() { if promise.resolveResult(.completed(result)) { CFRunLoopStop(CFRunLoopGetCurrent()) } } } catch let error { if promise.resolveResult(.errorThrown(error)) { CFRunLoopStop(CFRunLoopGetCurrent()) } } } asyncSource.resume() } return AwaitPromiseBuilder( awaiter: self, waitLock: waitLock, promise: promise, trigger: trigger) } } internal func pollBlock( pollInterval: TimeInterval, timeoutInterval: TimeInterval, file: FileString, line: UInt, fnName: String = #function, expression: @escaping () throws -> Bool) -> AwaitResult { let awaiter = NimbleEnvironment.activeInstance.awaiter let result = awaiter.poll(pollInterval) { () throws -> Bool? in do { if try expression() { return true } return nil } catch let error { throw error } }.timeout(timeoutInterval, forcefullyAbortTimeout: timeoutInterval / 2.0).wait(fnName, file: file, line: line) return result } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Utils/Errors.swift ================================================ import Foundation // Generic internal func setFailureMessageForError( _ failureMessage: FailureMessage, postfixMessageVerb: String = "throw", actualError: Error?, error: T? = nil, errorType: T.Type? = nil, closure: ((T) -> Void)? = nil) { failureMessage.postfixMessage = "\(postfixMessageVerb) error" if let error = error { if let error = error as? CustomDebugStringConvertible { failureMessage.postfixMessage += " <\(error.debugDescription)>" } else { failureMessage.postfixMessage += " <\(error)>" } } else if errorType != nil || closure != nil { failureMessage.postfixMessage += " from type <\(T.self)>" } if let _ = closure { failureMessage.postfixMessage += " that satisfies block" } if error == nil && errorType == nil && closure == nil { failureMessage.postfixMessage = "\(postfixMessageVerb) any error" } if let actualError = actualError { failureMessage.actualValue = "<\(actualError)>" } else { failureMessage.actualValue = "no error" } } internal func errorMatchesExpectedError( _ actualError: Error, expectedError: T) -> Bool { return actualError._domain == expectedError._domain && actualError._code == expectedError._code } internal func errorMatchesExpectedError( _ actualError: Error, expectedError: T) -> Bool where T: Equatable { if let actualError = actualError as? T { return actualError == expectedError } return false } internal func errorMatchesNonNilFieldsOrClosure( _ actualError: Error?, error: T? = nil, errorType: T.Type? = nil, closure: ((T) -> Void)? = nil) -> Bool { var matches = false if let actualError = actualError { matches = true if let error = error { if !errorMatchesExpectedError(actualError, expectedError: error) { matches = false } } if let actualError = actualError as? T { if let closure = closure { let assertions = gatherFailingExpectations { closure(actualError as T) } let messages = assertions.map { $0.message } if messages.count > 0 { matches = false } } } else if errorType != nil { matches = (actualError is T) // The closure expects another ErrorProtocol as argument, so this // is _supposed_ to fail, so that it becomes more obvious. if let closure = closure { let assertions = gatherExpectations { if let actual = actualError as? T { closure(actual) } } let messages = assertions.map { $0.message } if messages.count > 0 { matches = false } } } } return matches } // Non-generic internal func setFailureMessageForError( _ failureMessage: FailureMessage, actualError: Error?, closure: ((Error) -> Void)?) { failureMessage.postfixMessage = "throw error" if let _ = closure { failureMessage.postfixMessage += " that satisfies block" } else { failureMessage.postfixMessage = "throw any error" } if let actualError = actualError { failureMessage.actualValue = "<\(actualError)>" } else { failureMessage.actualValue = "no error" } } internal func errorMatchesNonNilFieldsOrClosure( _ actualError: Error?, closure: ((Error) -> Void)?) -> Bool { var matches = false if let actualError = actualError { matches = true if let closure = closure { let assertions = gatherFailingExpectations { closure(actualError) } let messages = assertions.map { $0.message } if messages.count > 0 { matches = false } } } return matches } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Utils/Functional.swift ================================================ import Foundation extension Sequence { internal func all(_ fn: (Iterator.Element) -> Bool) -> Bool { for item in self { if !fn(item) { return false } } return true } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Utils/SourceLocation.swift ================================================ import Foundation // Ideally we would always use `StaticString` as the type for tracking the file name // that expectations originate from, for consistency with `assert` etc. from the // stdlib, and because recent versions of the XCTest overlay require `StaticString` // when calling `XCTFail`. Under the Objective-C runtime (i.e. building on Mac), we // have to use `String` instead because StaticString can't be generated from Objective-C #if _runtime(_ObjC) public typealias FileString = String #else public typealias FileString = StaticString #endif public final class SourceLocation : NSObject { public let file: FileString public let line: UInt override init() { file = "Unknown File" line = 0 } init(file: FileString, line: UInt) { self.file = file self.line = line } override public var description: String { return "\(file):\(line)" } } ================================================ FILE: Example/Pods/Nimble/Sources/Nimble/Utils/Stringers.swift ================================================ import Foundation internal func identityAsString(_ value: Any?) -> String { let anyObject: AnyObject? #if os(Linux) anyObject = value as? AnyObject #else anyObject = value as AnyObject? #endif if let value = anyObject { return NSString(format: "<%p>", unsafeBitCast(value, to: Int.self)).description } else { return "nil" } } internal func arrayAsString(_ items: [T], joiner: String = ", ") -> String { return items.reduce("") { accum, item in let prefix = (accum.isEmpty ? "" : joiner) return accum + prefix + "\(stringify(item))" } } /// A type with a customized test output text representation. /// /// This textual representation is produced when values will be /// printed in test runs, and may be useful when producing /// error messages in custom matchers. /// /// - SeeAlso: `CustomDebugStringConvertible` public protocol TestOutputStringConvertible { var testDescription: String { get } } extension Double: TestOutputStringConvertible { public var testDescription: String { return NSNumber(value: self).testDescription } } extension Float: TestOutputStringConvertible { public var testDescription: String { return NSNumber(value: self).testDescription } } extension NSNumber: TestOutputStringConvertible { // This is using `NSString(format:)` instead of // `String(format:)` because the latter somehow breaks // the travis CI build on linux. public var testDescription: String { let description = self.description if description.contains(".") { // Travis linux swiftpm build doesn't like casting String to NSString, // which is why this annoying nested initializer thing is here. // Maybe this will change in a future snapshot. let decimalPlaces = NSString(string: NSString(string: description) .components(separatedBy: ".")[1]) // SeeAlso: https://bugs.swift.org/browse/SR-1464 switch decimalPlaces.length { case 1: return NSString(format: "%0.1f", self.doubleValue).description case 2: return NSString(format: "%0.2f", self.doubleValue).description case 3: return NSString(format: "%0.3f", self.doubleValue).description default: return NSString(format: "%0.4f", self.doubleValue).description } } return self.description } } extension Array: TestOutputStringConvertible { public var testDescription: String { let list = self.map(Nimble.stringify).joined(separator: ", ") return "[\(list)]" } } extension AnySequence: TestOutputStringConvertible { public var testDescription: String { let generator = self.makeIterator() var strings = [String]() var value: AnySequence.Iterator.Element? repeat { value = generator.next() if let value = value { strings.append(stringify(value)) } } while value != nil let list = strings.joined(separator: ", ") return "[\(list)]" } } extension NSArray: TestOutputStringConvertible { public var testDescription: String { let list = Array(self).map(Nimble.stringify).joined(separator: ", ") return "(\(list))" } } extension NSIndexSet: TestOutputStringConvertible { public var testDescription: String { let list = Array(self).map(Nimble.stringify).joined(separator: ", ") return "(\(list))" } } extension String: TestOutputStringConvertible { public var testDescription: String { return self } } extension Data: TestOutputStringConvertible { public var testDescription: String { #if os(Linux) // FIXME: Swift on Linux triggers a segfault when calling NSData's hash() (last checked on 03-11-16) return "Data" #else return "Data" #endif } } /// /// Returns a string appropriate for displaying in test output /// from the provided value. /// /// - parameter value: A value that will show up in a test's output. /// /// - returns: The string that is returned can be /// customized per type by conforming a type to the `TestOutputStringConvertible` /// protocol. When stringifying a non-`TestOutputStringConvertible` type, this /// function will return the value's debug description and then its /// normal description if available and in that order. Otherwise it /// will return the result of constructing a string from the value. /// /// - SeeAlso: `TestOutputStringConvertible` public func stringify(_ value: T) -> String { if let value = value as? TestOutputStringConvertible { return value.testDescription } if let value = value as? CustomDebugStringConvertible { return value.debugDescription } return String(describing: value) } /// -SeeAlso: `stringify(value: T)` public func stringify(_ value: T?) -> String { if let unboxed = value { return stringify(unboxed) } return "nil" } #if _runtime(_ObjC) @objc public class NMBStringer: NSObject { @objc public class func stringify(_ obj: Any?) -> String { return Nimble.stringify(obj) } } #endif // MARK: Collection Type Stringers /// Attempts to generate a pretty type string for a given value. If the value is of a Objective-C /// collection type, or a subclass thereof, (e.g. `NSArray`, `NSDictionary`, etc.). /// This function will return the type name of the root class of the class cluster for better /// readability (e.g. `NSArray` instead of `__NSArrayI`). /// /// For values that don't have a type of an Objective-C collection, this function returns the /// default type description. /// /// - parameter value: A value that will be used to determine a type name. /// /// - returns: The name of the class cluster root class for Objective-C collection types, or the /// the `dynamicType` of the value for values of any other type. public func prettyCollectionType(_ value: T) -> String { switch value { case is NSArray: return String(describing: NSArray.self) case is NSDictionary: return String(describing: NSDictionary.self) case is NSSet: return String(describing: NSSet.self) case is NSIndexSet: return String(describing: NSIndexSet.self) default: return String(describing: value) } } /// Returns the type name for a given collection type. This overload is used by Swift /// collection types. /// /// - parameter collection: A Swift `CollectionType` value. /// /// - returns: A string representing the `dynamicType` of the value. public func prettyCollectionType(_ collection: T) -> String { return String(describing: type(of: collection)) } ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/CurrentTestCaseTracker.h ================================================ #import #import SWIFT_CLASS("_TtC6Nimble22CurrentTestCaseTracker") @interface CurrentTestCaseTracker : NSObject + (CurrentTestCaseTracker *)sharedInstance; @end @interface CurrentTestCaseTracker (Register) @end ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/DSL.h ================================================ #import @class NMBExpectation; @class NMBObjCBeCloseToMatcher; @class NMBObjCRaiseExceptionMatcher; @protocol NMBMatcher; NS_ASSUME_NONNULL_BEGIN #define NIMBLE_OVERLOADABLE __attribute__((overloadable)) #define NIMBLE_EXPORT FOUNDATION_EXPORT #define NIMBLE_EXPORT_INLINE FOUNDATION_STATIC_INLINE #define NIMBLE_VALUE_OF(VAL) ({ \ __typeof__((VAL)) val = (VAL); \ [NSValue valueWithBytes:&val objCType:@encode(__typeof__((VAL)))]; \ }) #ifdef NIMBLE_DISABLE_SHORT_SYNTAX #define NIMBLE_SHORT(PROTO, ORIGINAL) #define NIMBLE_SHORT_OVERLOADED(PROTO, ORIGINAL) #else #define NIMBLE_SHORT(PROTO, ORIGINAL) FOUNDATION_STATIC_INLINE PROTO { return (ORIGINAL); } #define NIMBLE_SHORT_OVERLOADED(PROTO, ORIGINAL) FOUNDATION_STATIC_INLINE NIMBLE_OVERLOADABLE PROTO { return (ORIGINAL); } #endif #define DEFINE_NMB_EXPECT_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ NMBExpectation *NMB_expect(TYPE(^actualBlock)(), NSString *file, NSUInteger line) { \ return NMB_expect(^id { return EXPR; }, file, line); \ } NIMBLE_EXPORT NIMBLE_OVERLOADABLE NMBExpectation *NMB_expect(id(^actualBlock)(), NSString *file, NSUInteger line); // overloaded dispatch for nils - expect(nil) DEFINE_NMB_EXPECT_OVERLOAD(void*, nil) DEFINE_NMB_EXPECT_OVERLOAD(NSRange, NIMBLE_VALUE_OF(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(long, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(unsigned long, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(int, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(unsigned int, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(float, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(double, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(long long, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(unsigned long long, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(char, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(unsigned char, @(actualBlock())) // bool doesn't get the compiler to dispatch to BOOL types, but using BOOL here seems to allow // the compiler to dispatch to bool. DEFINE_NMB_EXPECT_OVERLOAD(BOOL, @(actualBlock())) DEFINE_NMB_EXPECT_OVERLOAD(char *, @(actualBlock())) #undef DEFINE_NMB_EXPECT_OVERLOAD NIMBLE_EXPORT NMBExpectation *NMB_expectAction(void(^actualBlock)(), NSString *file, NSUInteger line); #define DEFINE_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ id NMB_equal(TYPE expectedValue) { \ return NMB_equal((EXPR)); \ } \ NIMBLE_SHORT_OVERLOADED(id equal(TYPE expectedValue), NMB_equal(expectedValue)); NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_equal(__nullable id expectedValue); NIMBLE_SHORT_OVERLOADED(id equal(__nullable id expectedValue), NMB_equal(expectedValue)); // overloaded dispatch for nils - expect(nil) DEFINE_OVERLOAD(void*__nullable, (id)nil) DEFINE_OVERLOAD(NSRange, NIMBLE_VALUE_OF(expectedValue)) DEFINE_OVERLOAD(long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long, @(expectedValue)) DEFINE_OVERLOAD(int, @(expectedValue)) DEFINE_OVERLOAD(unsigned int, @(expectedValue)) DEFINE_OVERLOAD(float, @(expectedValue)) DEFINE_OVERLOAD(double, @(expectedValue)) DEFINE_OVERLOAD(long long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long long, @(expectedValue)) DEFINE_OVERLOAD(char, @(expectedValue)) DEFINE_OVERLOAD(unsigned char, @(expectedValue)) // bool doesn't get the compiler to dispatch to BOOL types, but using BOOL here seems to allow // the compiler to dispatch to bool. DEFINE_OVERLOAD(BOOL, @(expectedValue)) DEFINE_OVERLOAD(char *, @(expectedValue)) #undef DEFINE_OVERLOAD #define DEFINE_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ id NMB_haveCount(TYPE expectedValue) { \ return NMB_haveCount((EXPR)); \ } \ NIMBLE_SHORT_OVERLOADED(id haveCount(TYPE expectedValue), \ NMB_haveCount(expectedValue)); NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_haveCount(id expectedValue); NIMBLE_SHORT_OVERLOADED(id haveCount(id expectedValue), NMB_haveCount(expectedValue)); DEFINE_OVERLOAD(long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long, @(expectedValue)) DEFINE_OVERLOAD(int, @(expectedValue)) DEFINE_OVERLOAD(unsigned int, @(expectedValue)) DEFINE_OVERLOAD(long long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long long, @(expectedValue)) DEFINE_OVERLOAD(char, @(expectedValue)) DEFINE_OVERLOAD(unsigned char, @(expectedValue)) #undef DEFINE_OVERLOAD #define DEFINE_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ NMBObjCBeCloseToMatcher *NMB_beCloseTo(TYPE expectedValue) { \ return NMB_beCloseTo((NSNumber *)(EXPR)); \ } \ NIMBLE_SHORT_OVERLOADED(NMBObjCBeCloseToMatcher *beCloseTo(TYPE expectedValue), \ NMB_beCloseTo(expectedValue)); NIMBLE_EXPORT NIMBLE_OVERLOADABLE NMBObjCBeCloseToMatcher *NMB_beCloseTo(NSNumber *expectedValue); NIMBLE_SHORT_OVERLOADED(NMBObjCBeCloseToMatcher *beCloseTo(NSNumber *expectedValue), NMB_beCloseTo(expectedValue)); // it would be better to only overload float & double, but zero becomes ambigious DEFINE_OVERLOAD(long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long, @(expectedValue)) DEFINE_OVERLOAD(int, @(expectedValue)) DEFINE_OVERLOAD(unsigned int, @(expectedValue)) DEFINE_OVERLOAD(float, @(expectedValue)) DEFINE_OVERLOAD(double, @(expectedValue)) DEFINE_OVERLOAD(long long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long long, @(expectedValue)) DEFINE_OVERLOAD(char, @(expectedValue)) DEFINE_OVERLOAD(unsigned char, @(expectedValue)) #undef DEFINE_OVERLOAD NIMBLE_EXPORT id NMB_beAnInstanceOf(Class expectedClass); NIMBLE_EXPORT_INLINE id beAnInstanceOf(Class expectedClass) { return NMB_beAnInstanceOf(expectedClass); } NIMBLE_EXPORT id NMB_beAKindOf(Class expectedClass); NIMBLE_EXPORT_INLINE id beAKindOf(Class expectedClass) { return NMB_beAKindOf(expectedClass); } NIMBLE_EXPORT id NMB_beginWith(id itemElementOrSubstring); NIMBLE_EXPORT_INLINE id beginWith(id itemElementOrSubstring) { return NMB_beginWith(itemElementOrSubstring); } #define DEFINE_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ id NMB_beGreaterThan(TYPE expectedValue) { \ return NMB_beGreaterThan((EXPR)); \ } \ NIMBLE_SHORT_OVERLOADED(id beGreaterThan(TYPE expectedValue), NMB_beGreaterThan(expectedValue)); NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beGreaterThan(NSNumber *expectedValue); NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE id beGreaterThan(NSNumber *expectedValue) { return NMB_beGreaterThan(expectedValue); } DEFINE_OVERLOAD(long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long, @(expectedValue)) DEFINE_OVERLOAD(int, @(expectedValue)) DEFINE_OVERLOAD(unsigned int, @(expectedValue)) DEFINE_OVERLOAD(long long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long long, @(expectedValue)) DEFINE_OVERLOAD(char, @(expectedValue)) DEFINE_OVERLOAD(unsigned char, @(expectedValue)) #undef DEFINE_OVERLOAD #define DEFINE_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ id NMB_beGreaterThanOrEqualTo(TYPE expectedValue) { \ return NMB_beGreaterThanOrEqualTo((EXPR)); \ } \ NIMBLE_SHORT_OVERLOADED(id beGreaterThanOrEqualTo(TYPE expectedValue), \ NMB_beGreaterThanOrEqualTo(expectedValue)); NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beGreaterThanOrEqualTo(NSNumber *expectedValue); NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE id beGreaterThanOrEqualTo(NSNumber *expectedValue) { return NMB_beGreaterThanOrEqualTo(expectedValue); } DEFINE_OVERLOAD(long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long, @(expectedValue)) DEFINE_OVERLOAD(int, @(expectedValue)) DEFINE_OVERLOAD(unsigned int, @(expectedValue)) DEFINE_OVERLOAD(float, @(expectedValue)) DEFINE_OVERLOAD(double, @(expectedValue)) DEFINE_OVERLOAD(long long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long long, @(expectedValue)) DEFINE_OVERLOAD(char, @(expectedValue)) DEFINE_OVERLOAD(unsigned char, @(expectedValue)) #undef DEFINE_OVERLOAD NIMBLE_EXPORT id NMB_beIdenticalTo(id expectedInstance); NIMBLE_SHORT(id beIdenticalTo(id expectedInstance), NMB_beIdenticalTo(expectedInstance)); NIMBLE_EXPORT id NMB_be(id expectedInstance); NIMBLE_SHORT(id be(id expectedInstance), NMB_be(expectedInstance)); #define DEFINE_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ id NMB_beLessThan(TYPE expectedValue) { \ return NMB_beLessThan((EXPR)); \ } \ NIMBLE_SHORT_OVERLOADED(id beLessThan(TYPE expectedValue), \ NMB_beLessThan(expectedValue)); NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beLessThan(NSNumber *expectedValue); NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE id beLessThan(NSNumber *expectedValue) { return NMB_beLessThan(expectedValue); } DEFINE_OVERLOAD(long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long, @(expectedValue)) DEFINE_OVERLOAD(int, @(expectedValue)) DEFINE_OVERLOAD(unsigned int, @(expectedValue)) DEFINE_OVERLOAD(float, @(expectedValue)) DEFINE_OVERLOAD(double, @(expectedValue)) DEFINE_OVERLOAD(long long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long long, @(expectedValue)) DEFINE_OVERLOAD(char, @(expectedValue)) DEFINE_OVERLOAD(unsigned char, @(expectedValue)) #undef DEFINE_OVERLOAD #define DEFINE_OVERLOAD(TYPE, EXPR) \ NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE \ id NMB_beLessThanOrEqualTo(TYPE expectedValue) { \ return NMB_beLessThanOrEqualTo((EXPR)); \ } \ NIMBLE_SHORT_OVERLOADED(id beLessThanOrEqualTo(TYPE expectedValue), \ NMB_beLessThanOrEqualTo(expectedValue)); NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beLessThanOrEqualTo(NSNumber *expectedValue); NIMBLE_EXPORT_INLINE NIMBLE_OVERLOADABLE id beLessThanOrEqualTo(NSNumber *expectedValue) { return NMB_beLessThanOrEqualTo(expectedValue); } DEFINE_OVERLOAD(long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long, @(expectedValue)) DEFINE_OVERLOAD(int, @(expectedValue)) DEFINE_OVERLOAD(unsigned int, @(expectedValue)) DEFINE_OVERLOAD(float, @(expectedValue)) DEFINE_OVERLOAD(double, @(expectedValue)) DEFINE_OVERLOAD(long long, @(expectedValue)) DEFINE_OVERLOAD(unsigned long long, @(expectedValue)) DEFINE_OVERLOAD(char, @(expectedValue)) DEFINE_OVERLOAD(unsigned char, @(expectedValue)) #undef DEFINE_OVERLOAD NIMBLE_EXPORT id NMB_beTruthy(void); NIMBLE_SHORT(id beTruthy(void), NMB_beTruthy()); NIMBLE_EXPORT id NMB_beFalsy(void); NIMBLE_SHORT(id beFalsy(void), NMB_beFalsy()); NIMBLE_EXPORT id NMB_beTrue(void); NIMBLE_SHORT(id beTrue(void), NMB_beTrue()); NIMBLE_EXPORT id NMB_beFalse(void); NIMBLE_SHORT(id beFalse(void), NMB_beFalse()); NIMBLE_EXPORT id NMB_beNil(void); NIMBLE_SHORT(id beNil(void), NMB_beNil()); NIMBLE_EXPORT id NMB_beEmpty(void); NIMBLE_SHORT(id beEmpty(void), NMB_beEmpty()); NIMBLE_EXPORT id NMB_containWithNilTermination(id itemOrSubstring, ...) NS_REQUIRES_NIL_TERMINATION; #define NMB_contain(...) NMB_containWithNilTermination(__VA_ARGS__, nil) #ifndef NIMBLE_DISABLE_SHORT_SYNTAX #define contain(...) NMB_contain(__VA_ARGS__) #endif NIMBLE_EXPORT id NMB_endWith(id itemElementOrSubstring); NIMBLE_SHORT(id endWith(id itemElementOrSubstring), NMB_endWith(itemElementOrSubstring)); NIMBLE_EXPORT NMBObjCRaiseExceptionMatcher *NMB_raiseException(void); NIMBLE_SHORT(NMBObjCRaiseExceptionMatcher *raiseException(void), NMB_raiseException()); NIMBLE_EXPORT id NMB_match(id expectedValue); NIMBLE_SHORT(id match(id expectedValue), NMB_match(expectedValue)); NIMBLE_EXPORT id NMB_allPass(id matcher); NIMBLE_SHORT(id allPass(id matcher), NMB_allPass(matcher)); NIMBLE_EXPORT id NMB_satisfyAnyOfWithMatchers(id matchers); #define NMB_satisfyAnyOf(...) NMB_satisfyAnyOfWithMatchers(@[__VA_ARGS__]) #ifndef NIMBLE_DISABLE_SHORT_SYNTAX #define satisfyAnyOf(...) NMB_satisfyAnyOf(__VA_ARGS__) #endif // In order to preserve breakpoint behavior despite using macros to fill in __FILE__ and __LINE__, // define a builder that populates __FILE__ and __LINE__, and returns a block that takes timeout // and action arguments. See https://github.com/Quick/Quick/pull/185 for details. typedef void (^NMBWaitUntilTimeoutBlock)(NSTimeInterval timeout, void (^action)(void (^)(void))); typedef void (^NMBWaitUntilBlock)(void (^action)(void (^)(void))); NIMBLE_EXPORT void NMB_failWithMessage(NSString *msg, NSString *file, NSUInteger line); NIMBLE_EXPORT NMBWaitUntilTimeoutBlock NMB_waitUntilTimeoutBuilder(NSString *file, NSUInteger line); NIMBLE_EXPORT NMBWaitUntilBlock NMB_waitUntilBuilder(NSString *file, NSUInteger line); NIMBLE_EXPORT void NMB_failWithMessage(NSString *msg, NSString *file, NSUInteger line); #define NMB_waitUntilTimeout NMB_waitUntilTimeoutBuilder(@(__FILE__), __LINE__) #define NMB_waitUntil NMB_waitUntilBuilder(@(__FILE__), __LINE__) #ifndef NIMBLE_DISABLE_SHORT_SYNTAX #define expect(...) NMB_expect(^{ return (__VA_ARGS__); }, @(__FILE__), __LINE__) #define expectAction(BLOCK) NMB_expectAction((BLOCK), @(__FILE__), __LINE__) #define failWithMessage(msg) NMB_failWithMessage(msg, @(__FILE__), __LINE__) #define fail() failWithMessage(@"fail() always fails") #define waitUntilTimeout NMB_waitUntilTimeout #define waitUntil NMB_waitUntil #undef NIMBLE_VALUE_OF #endif NS_ASSUME_NONNULL_END ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/DSL.m ================================================ #import #import SWIFT_CLASS("_TtC6Nimble7NMBWait") @interface NMBWait : NSObject + (void)untilTimeout:(NSTimeInterval)timeout file:(NSString *)file line:(NSUInteger)line action:(void(^)())action; + (void)untilFile:(NSString *)file line:(NSUInteger)line action:(void(^)())action; @end NS_ASSUME_NONNULL_BEGIN NIMBLE_EXPORT NIMBLE_OVERLOADABLE NMBExpectation *__nonnull NMB_expect(id __nullable(^actualBlock)(), NSString *__nonnull file, NSUInteger line) { return [[NMBExpectation alloc] initWithActualBlock:actualBlock negative:NO file:file line:line]; } NIMBLE_EXPORT NMBExpectation *NMB_expectAction(void(^actualBlock)(), NSString *file, NSUInteger line) { return NMB_expect(^id{ actualBlock(); return nil; }, file, line); } NIMBLE_EXPORT void NMB_failWithMessage(NSString *msg, NSString *file, NSUInteger line) { return [NMBExpectation failWithMessage:msg file:file line:line]; } NIMBLE_EXPORT id NMB_beAnInstanceOf(Class expectedClass) { return [NMBObjCMatcher beAnInstanceOfMatcher:expectedClass]; } NIMBLE_EXPORT id NMB_beAKindOf(Class expectedClass) { return [NMBObjCMatcher beAKindOfMatcher:expectedClass]; } NIMBLE_EXPORT NIMBLE_OVERLOADABLE NMBObjCBeCloseToMatcher *NMB_beCloseTo(NSNumber *expectedValue) { return [NMBObjCMatcher beCloseToMatcher:expectedValue within:0.001]; } NIMBLE_EXPORT id NMB_beginWith(id itemElementOrSubstring) { return [NMBObjCMatcher beginWithMatcher:itemElementOrSubstring]; } NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beGreaterThan(NSNumber *expectedValue) { return [NMBObjCMatcher beGreaterThanMatcher:expectedValue]; } NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beGreaterThanOrEqualTo(NSNumber *expectedValue) { return [NMBObjCMatcher beGreaterThanOrEqualToMatcher:expectedValue]; } NIMBLE_EXPORT id NMB_beIdenticalTo(id expectedInstance) { return [NMBObjCMatcher beIdenticalToMatcher:expectedInstance]; } NIMBLE_EXPORT id NMB_be(id expectedInstance) { return [NMBObjCMatcher beIdenticalToMatcher:expectedInstance]; } NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beLessThan(NSNumber *expectedValue) { return [NMBObjCMatcher beLessThanMatcher:expectedValue]; } NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_beLessThanOrEqualTo(NSNumber *expectedValue) { return [NMBObjCMatcher beLessThanOrEqualToMatcher:expectedValue]; } NIMBLE_EXPORT id NMB_beTruthy() { return [NMBObjCMatcher beTruthyMatcher]; } NIMBLE_EXPORT id NMB_beFalsy() { return [NMBObjCMatcher beFalsyMatcher]; } NIMBLE_EXPORT id NMB_beTrue() { return [NMBObjCMatcher beTrueMatcher]; } NIMBLE_EXPORT id NMB_beFalse() { return [NMBObjCMatcher beFalseMatcher]; } NIMBLE_EXPORT id NMB_beNil() { return [NMBObjCMatcher beNilMatcher]; } NIMBLE_EXPORT id NMB_beEmpty() { return [NMBObjCMatcher beEmptyMatcher]; } NIMBLE_EXPORT id NMB_containWithNilTermination(id itemOrSubstring, ...) { NSMutableArray *itemOrSubstringArray = [NSMutableArray array]; if (itemOrSubstring) { [itemOrSubstringArray addObject:itemOrSubstring]; va_list args; va_start(args, itemOrSubstring); id next; while ((next = va_arg(args, id))) { [itemOrSubstringArray addObject:next]; } va_end(args); } return [NMBObjCMatcher containMatcher:itemOrSubstringArray]; } NIMBLE_EXPORT id NMB_endWith(id itemElementOrSubstring) { return [NMBObjCMatcher endWithMatcher:itemElementOrSubstring]; } NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_equal(__nullable id expectedValue) { return [NMBObjCMatcher equalMatcher:expectedValue]; } NIMBLE_EXPORT NIMBLE_OVERLOADABLE id NMB_haveCount(id expectedValue) { return [NMBObjCMatcher haveCountMatcher:expectedValue]; } NIMBLE_EXPORT id NMB_match(id expectedValue) { return [NMBObjCMatcher matchMatcher:expectedValue]; } NIMBLE_EXPORT id NMB_allPass(id expectedValue) { return [NMBObjCMatcher allPassMatcher:expectedValue]; } NIMBLE_EXPORT id NMB_satisfyAnyOfWithMatchers(id matchers) { return [NMBObjCMatcher satisfyAnyOfMatcher:matchers]; } NIMBLE_EXPORT NMBObjCRaiseExceptionMatcher *NMB_raiseException() { return [NMBObjCMatcher raiseExceptionMatcher]; } NIMBLE_EXPORT NMBWaitUntilTimeoutBlock NMB_waitUntilTimeoutBuilder(NSString *file, NSUInteger line) { return ^(NSTimeInterval timeout, void (^action)(void (^)(void))) { [NMBWait untilTimeout:timeout file:file line:line action:action]; }; } NIMBLE_EXPORT NMBWaitUntilBlock NMB_waitUntilBuilder(NSString *file, NSUInteger line) { return ^(void (^action)(void (^)(void))) { [NMBWait untilFile:file line:line action:action]; }; } NS_ASSUME_NONNULL_END ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/NMBExceptionCapture.h ================================================ #import #import @interface NMBExceptionCapture : NSObject - (nonnull instancetype)initWithHandler:(void(^ _Nullable)(NSException * _Nonnull))handler finally:(void(^ _Nullable)())finally; - (void)tryBlock:(void(^ _Nonnull)())unsafeBlock NS_SWIFT_NAME(tryBlock(_:)); @end typedef void(^NMBSourceCallbackBlock)(BOOL successful); ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/NMBExceptionCapture.m ================================================ #import "NMBExceptionCapture.h" @interface NMBExceptionCapture () @property (nonatomic, copy) void(^ _Nullable handler)(NSException * _Nullable); @property (nonatomic, copy) void(^ _Nullable finally)(); @end @implementation NMBExceptionCapture - (nonnull instancetype)initWithHandler:(void(^ _Nullable)(NSException * _Nonnull))handler finally:(void(^ _Nullable)())finally { self = [super init]; if (self) { self.handler = handler; self.finally = finally; } return self; } - (void)tryBlock:(void(^ _Nonnull)())unsafeBlock { @try { unsafeBlock(); } @catch (NSException *exception) { if (self.handler) { self.handler(exception); } } @finally { if (self.finally) { self.finally(); } } } @end ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/NMBStringify.h ================================================ @class NSString; /** * Returns a string appropriate for displaying in test output * from the provided value. * * @param value A value that will show up in a test's output. * * @return The string that is returned can be * customized per type by conforming a type to the `TestOutputStringConvertible` * protocol. When stringifying a non-`TestOutputStringConvertible` type, this * function will return the value's debug description and then its * normal description if available and in that order. Otherwise it * will return the result of constructing a string from the value. * * @see `TestOutputStringConvertible` */ extern NSString *_Nonnull NMBStringify(id _Nullable anyObject) __attribute__((warn_unused_result)); ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/NMBStringify.m ================================================ #import "NMBStringify.h" #import NSString *_Nonnull NMBStringify(id _Nullable anyObject) { return [NMBStringer stringify:anyObject]; } ================================================ FILE: Example/Pods/Nimble/Sources/NimbleObjectiveC/XCTestObservationCenter+Register.m ================================================ #import "CurrentTestCaseTracker.h" #import #import #pragma mark - Method Swizzling /// Swaps the implementations between two instance methods. /// /// @param class The class containing `originalSelector`. /// @param originalSelector Original method to replace. /// @param replacementSelector Replacement method. void swizzleSelectors(Class class, SEL originalSelector, SEL replacementSelector) { Method originalMethod = class_getInstanceMethod(class, originalSelector); Method replacementMethod = class_getInstanceMethod(class, replacementSelector); BOOL didAddMethod = class_addMethod(class, originalSelector, method_getImplementation(replacementMethod), method_getTypeEncoding(replacementMethod)); if (didAddMethod) { class_replaceMethod(class, replacementSelector, method_getImplementation(originalMethod), method_getTypeEncoding(originalMethod)); } else { method_exchangeImplementations(originalMethod, replacementMethod); } } #pragma mark - Private @interface XCTestObservationCenter (Private) - (void)_addLegacyTestObserver:(id)observer; @end @implementation XCTestObservationCenter (Register) /// Uses objc method swizzling to register `CurrentTestCaseTracker` as a test observer. This is necessary /// because Xcode 7.3 introduced timing issues where if a custom `XCTestObservation` is registered too early /// it suppresses all console output (generated by `XCTestLog`), breaking any tools that depend on this output. /// This approach waits to register our custom test observer until XCTest adds its first "legacy" observer, /// falling back to registering after the first normal observer if this private method ever changes. + (void)load { if (class_getInstanceMethod([self class], @selector(_addLegacyTestObserver:))) { // Swizzle -_addLegacyTestObserver: swizzleSelectors([self class], @selector(_addLegacyTestObserver:), @selector(NMB_original__addLegacyTestObserver:)); } else { // Swizzle -addTestObserver:, only if -_addLegacyTestObserver: is not implemented swizzleSelectors([self class], @selector(addTestObserver:), @selector(NMB_original_addTestObserver:)); } } #pragma mark - Replacement Methods /// Registers `CurrentTestCaseTracker` as a test observer after `XCTestLog` has been added. - (void)NMB_original__addLegacyTestObserver:(id)observer { [self NMB_original__addLegacyTestObserver:observer]; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ [self addTestObserver:[CurrentTestCaseTracker sharedInstance]]; }); } /// Registers `CurrentTestCaseTracker` as a test observer after `XCTestLog` has been added. /// This method is only used if `-_addLegacyTestObserver:` is not impelemented. (added in Xcode 7.3) - (void)NMB_original_addTestObserver:(id)observer { [self NMB_original_addTestObserver:observer]; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ [self NMB_original_addTestObserver:[CurrentTestCaseTracker sharedInstance]]; }); } @end ================================================ FILE: Example/Pods/Pods.xcodeproj/project.pbxproj ================================================ // !$*UTF8*$! { archiveVersion = 1; classes = { }; objectVersion = 46; objects = { /* Begin PBXBuildFile section */ 01297E76B8F59B57CA207191681F7B5B /* RelativePointer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0A7F4F011E3296C5BDBCDA0E0662448F /* RelativePointer.swift */; }; 020B66398FFAE7EF8DC82BCFBC847B74 /* World+DSL.h in Headers */ = {isa = PBXBuildFile; fileRef = 5E29A6AE6378CC0FFE2CBF7A691DF366 /* World+DSL.h */; settings = {ATTRIBUTES = (Project, ); }; }; 0447EAC87AD27FB27515B70F15F4837C /* PersistentStorageSerializable.swift in Sources */ = {isa = PBXBuildFile; fileRef = F8E892409CB344988B711253F95DF9A6 /* PersistentStorageSerializable.swift */; }; 047A68C646E00EB6D7D4D7343B801D09 /* AdapterProtocols.swift in Sources */ = {isa = PBXBuildFile; fileRef = 45186F11C51E26728BB50D85C0390181 /* AdapterProtocols.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 052E642802CDFAE58E5015973CC29989 /* Identity.swift in Sources */ = {isa = PBXBuildFile; fileRef = 409470BF79C61A1DC5EE998F14636B1D /* Identity.swift */; }; 053B74B0FCB3178D1ED0607D0F972A71 /* Reflection-iOS-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = 01EC2AA7495F252C13BD7234C74E79F3 /* Reflection-iOS-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 0553835581ED0E2219057AAAF8EDACB7 /* MemoryProperties.swift in Sources */ = {isa = PBXBuildFile; fileRef = 35699FC5A45F8604D9E53D74B994634E /* MemoryProperties.swift */; }; 0595F8F053D261E51EE0A53C8B27A343 /* PersistentStorage.swift in Sources */ = {isa = PBXBuildFile; fileRef = E12E2760F92F1A2C4D26629773BE116E /* PersistentStorage.swift */; }; 07722FBCF6B380961B9D2832D5883F45 /* BeGreaterThan.swift in Sources */ = {isa = PBXBuildFile; fileRef = DEED2885ABD003AA6FD143802588C6B4 /* BeGreaterThan.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 07731CF449EB16282C6A18D2739B0814 /* ExampleGroup.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5F7A1D7D610669DBC95F6145CE72F1E6 /* ExampleGroup.swift */; }; 079AB49FD0F4774D822A66A51327DA53 /* PersistentStorageSerializable-OSX-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = B23DC3D7DA990D4E2939C1BC4496A08A /* PersistentStorageSerializable-OSX-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 0AEC20AACF9B10846830274E3B2AA6FD /* BeLogical.swift in Sources */ = {isa = PBXBuildFile; fileRef = A2FA10E38A6C6E200ABA275E72DD4023 /* BeLogical.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 0B95B4873A60B312637F64D29989704F /* Array+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9578A4E1FCE35AB00735C22CFC7162C2 /* Array+Extensions.swift */; }; 0ECEEBC712D404AA6CF1E76A9284BFF9 /* DSL.h in Headers */ = {isa = PBXBuildFile; fileRef = 38E7ED6F46ED044FD279837053FB0991 /* DSL.h */; settings = {ATTRIBUTES = (Public, ); }; }; 0F98B9251F2C3EE6F7E51AEC683860F7 /* ValueWitnessTable.swift in Sources */ = {isa = PBXBuildFile; fileRef = 297F08DEBA780355103E1943E91C9863 /* ValueWitnessTable.swift */; }; 10FB7310EAD5D4DA82EC2E3A01673CE1 /* PersistentStorageSerializable-iOS-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 9BA1549C5D1B25AFA3C649C78FA1F854 /* PersistentStorageSerializable-iOS-dummy.m */; }; 110A640A9BE45841BA938B4C29EF5446 /* ThrowAssertion.swift in Sources */ = {isa = PBXBuildFile; fileRef = F2426CDF7725EBE8B022AB5940A504C8 /* ThrowAssertion.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 1126C787C127CB914614414DC0AB6B47 /* Metadata+Kind.swift in Sources */ = {isa = PBXBuildFile; fileRef = F8B180A74BF7DA9BBC0C73181205FB92 /* Metadata+Kind.swift */; }; 1132968D8FD56FC339BE397D93F30182 /* NominalType.swift in Sources */ = {isa = PBXBuildFile; fileRef = AC711F896F1F753CD40D0336E1891051 /* NominalType.swift */; }; 127CD37052B8E0BC645D83D4664F59D4 /* NMBStringify.m in Sources */ = {isa = PBXBuildFile; fileRef = 83845FD26AACEFCEC9B6152D1153AE71 /* NMBStringify.m */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 17261E344C2027602431A636759AC7F2 /* DSL.swift in Sources */ = {isa = PBXBuildFile; fileRef = 68E8EB308595205EAFD2911F340CA696 /* DSL.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 18B7E2BF4A724A3632E02E0AA3918844 /* World+DSL.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6ADE93DC4F670B429664153334AC498A /* World+DSL.swift */; }; 1B17B3C06FE5ADDFB860494D7695A3A2 /* Metadata+Tuple.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D6D4970F760DF36BCCBDE630066C7B2 /* Metadata+Tuple.swift */; }; 1C50F54510D5C2B2AD84D7B74A6EDEBB /* BeGreaterThanOrEqualTo.swift in Sources */ = {isa = PBXBuildFile; fileRef = CE13F5C238F2F59965B512E89C0D946B /* BeGreaterThanOrEqualTo.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 1C7CA1FAFBF8B865596C739FEA39CDEE /* DSL.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DB462E985BF4F3D549283CCE0813916 /* DSL.m */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 1E156B80065588ACEE97FF552C24920B /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */; }; 1FACBA5B035E21841BFC908DF2F8DE60 /* Reflection-iOS-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 13BD39469AED51D519EF9058AC78DB5B /* Reflection-iOS-dummy.m */; }; 1FEFF9515601DF2AD8B7AA51F78D84CD /* ReflectionError.swift in Sources */ = {isa = PBXBuildFile; fileRef = 972E1E97A8BE5406BCB6970C92C39D67 /* ReflectionError.swift */; }; 22C1DE74D494C10BBE727F239A68447D /* ThrowError.swift in Sources */ = {isa = PBXBuildFile; fileRef = 079BB80084E1A015AB255272CDD214F6 /* ThrowError.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 234BFC45ACAC4A8FB945EA17B6A74B0B /* SourceLocation.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5E6BFF347E9847E936924A832FBABBB /* SourceLocation.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 23E2E1E02FE79EE1E1688CBBAA777297 /* MatcherProtocols.swift in Sources */ = {isa = PBXBuildFile; fileRef = C4AD1312A77F4A770BB0CC46BEC8DBA5 /* MatcherProtocols.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 24EF979DB6A2B88464E07F5C5937EE14 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */; }; 2568862D51DC7E7E605FEA67B3C2B2DF /* NominalType.swift in Sources */ = {isa = PBXBuildFile; fileRef = AC711F896F1F753CD40D0336E1891051 /* NominalType.swift */; }; 27B262F95D3CF9E3C74541A41929691C /* NMBStringify.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FF2C07CF5BF76578AEAF758FD251ED7 /* NMBStringify.h */; settings = {ATTRIBUTES = (Public, ); }; }; 27C8D0B5BDCE5D2598D72B26804C5C02 /* QCKDSL.h in Headers */ = {isa = PBXBuildFile; fileRef = 3A92C161CC0365639BDA3BF5C09D75B0 /* QCKDSL.h */; settings = {ATTRIBUTES = (Public, ); }; }; 2BEA3608F762A2FE5015B1E18DFCD271 /* Metadata.swift in Sources */ = {isa = PBXBuildFile; fileRef = 22089DBC28F5B811B25675FBD14A464C /* Metadata.swift */; }; 32D21EE104D5522D22A63814A3014CE2 /* ValueWitnessTable.swift in Sources */ = {isa = PBXBuildFile; fileRef = 297F08DEBA780355103E1943E91C9863 /* ValueWitnessTable.swift */; }; 3600CF9CB81FDA40631664F18C987565 /* ExampleMetadata.swift in Sources */ = {isa = PBXBuildFile; fileRef = 00B18873BB378B52DE8BD4C15DD36011 /* ExampleMetadata.swift */; }; 36DE34FECFBAA5C66AD16796D49C922C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */; }; 3915DBB4731CB17B255A7FE86E240B6E /* CwlCatchBadInstruction.m in Sources */ = {isa = PBXBuildFile; fileRef = 469E378328AB74CE2F16E82A53E9FAAA /* CwlCatchBadInstruction.m */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 43DCD3F2C3E435EAD0B167ACD20CE1CE /* DSL.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AA62C473D27598FC7557C82330D047A /* DSL.swift */; }; 465F487084A675DF1D8FF41AB942A461 /* Pods-PersistentStorageSerializable_iOSExample-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = BC62F6B906201B92A5E117B29415D918 /* Pods-PersistentStorageSerializable_iOSExample-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 469E9C3ED9FD6009F7C9AAF9E537E212 /* Nimble.h in Headers */ = {isa = PBXBuildFile; fileRef = A41ACB6A39BC53C1AD5ECDF57143D17F /* Nimble.h */; settings = {ATTRIBUTES = (Public, ); }; }; 492FCC6E224A949B9883FA7F4568B0C3 /* HooksPhase.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7CC161CB4301C486CAB9553D7771F325 /* HooksPhase.swift */; }; 4C672CABC57F27FD257A00D44A41AA2C /* QuickConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = 4AB1B530FD4746C7F1ED45FB4D5A9874 /* QuickConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; 4C9F41FE904E314F55D857A80457CADC /* XCTestSuite+QuickTestSuiteBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = F944D7066C3FBE6346D1BC4CCEFF019B /* XCTestSuite+QuickTestSuiteBuilder.m */; }; 4EB98E304582EC3C0213C88146DE42F9 /* Reflection-OSX-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = 88A0A2C900F1B0DA95C4E099D8EF69DE /* Reflection-OSX-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 4F3F103945CC52D0A3B8A891BB0E21C4 /* RaisesException.swift in Sources */ = {isa = PBXBuildFile; fileRef = 160CAC0E61452631C6449C6AD9B44A76 /* RaisesException.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 502697EEDEB856CB927D86CEFFEFD81F /* MetadataType.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0FBD8197371FDDD1F56733D5344DA39C /* MetadataType.swift */; }; 50B80F12A9BAE302F07F6CF94752F462 /* mach_excServer.c in Sources */ = {isa = PBXBuildFile; fileRef = A8B01A7115AF84CE2793835F62484967 /* mach_excServer.c */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 514986E42D0AB20608C3841E710357D2 /* World.swift in Sources */ = {isa = PBXBuildFile; fileRef = EE9A987E830816D13D423881223CAD20 /* World.swift */; }; 551440A0F92574039C1D2EB39227D6B8 /* AsyncMatcherWrapper.swift in Sources */ = {isa = PBXBuildFile; fileRef = AFB88A73C0CB8BEA601FC0FFCAC65E93 /* AsyncMatcherWrapper.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 58BBAA735E0564DC10B759A045722D28 /* Pods-PersistentStorageSerializable_MacExample-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = F76B520EB440AD883F9E762A2520AE65 /* Pods-PersistentStorageSerializable_MacExample-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 58FAC51B72C06FEC4A6C73A97477B0A9 /* PersistentStorage.swift in Sources */ = {isa = PBXBuildFile; fileRef = E12E2760F92F1A2C4D26629773BE116E /* PersistentStorage.swift */; }; 599669823A2EED2928C77F301F6B0515 /* BeNil.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7198266CDCBE981765D73B51A366A2EC /* BeNil.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 5B15ED51D2DDC01FCECB0A6085564A83 /* Pods-PersistentStorageSerializable_MacExample-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = D3B7A9361C95282C7B4CDDB9F84197FF /* Pods-PersistentStorageSerializable_MacExample-dummy.m */; }; 5B863E4F94C0031EAA2395D95EEB6971 /* Storage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 217580B44B73532ED783A1267CCDB3FA /* Storage.swift */; }; 5DD5045E9FD98BA38FD09BC13331DB22 /* QuickSpec.h in Headers */ = {isa = PBXBuildFile; fileRef = F8B44832CF0A8EC7A1EFA01846604B27 /* QuickSpec.h */; settings = {ATTRIBUTES = (Public, ); }; }; 5EAF1AE63153220FC957F99817820067 /* SwiftTryCatch.h in Headers */ = {isa = PBXBuildFile; fileRef = AC46343C8BF32068677D41A1DC13B7EA /* SwiftTryCatch.h */; settings = {ATTRIBUTES = (Public, ); }; }; 5F0656C57F3790BFAECDEE9DD19FF9F8 /* Quick-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = E196A082C7CA44AB8438286B821016A9 /* Quick-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 60986639F7C83D8C8120F0C56EACB273 /* RelativePointer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0A7F4F011E3296C5BDBCDA0E0662448F /* RelativePointer.swift */; }; 6151084EDA799E77F35D31B123AA4FC4 /* Properties.swift in Sources */ = {isa = PBXBuildFile; fileRef = BE3AC896DCF9F346EDE03FFD0488C493 /* Properties.swift */; }; 62744EF299751FB49B5FCD81D8C8FFF7 /* SatisfyAnyOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4B9854299BC061D75E995BB3C3634F23 /* SatisfyAnyOf.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 6302DC24446FB6D1D3F28C7A91074E6C /* Advance.swift in Sources */ = {isa = PBXBuildFile; fileRef = 559C95F20B29BE7F707CA733C7738B29 /* Advance.swift */; }; 65F5217D44A557FC16218DE5DE348C35 /* CwlCatchBadInstruction.h in Headers */ = {isa = PBXBuildFile; fileRef = 40337972E5B074C5A690D3990DF7905F /* CwlCatchBadInstruction.h */; settings = {ATTRIBUTES = (Public, ); }; }; 696055C40EA92B1E64AA427B5F279F17 /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4AF86E0EEBE4ECA5D93983C10918FE02 /* XCTest.framework */; }; 698B22A2197B6B1C3FBD6152F580A56E /* MetadataType.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0FBD8197371FDDD1F56733D5344DA39C /* MetadataType.swift */; }; 6CA40832F248BADDAEAD9799D25E8327 /* Any+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = AD76B886530DC003364EE0F566036318 /* Any+Extensions.swift */; }; 6CDBA48C3A8621E4EE1DAFFE240F0D82 /* CwlCatchBadInstruction.swift in Sources */ = {isa = PBXBuildFile; fileRef = 011E5DDBA8311C08981F7D176417FCC8 /* CwlCatchBadInstruction.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 6E397D9FB11A47E48D70287D734B12B2 /* BeLessThan.swift in Sources */ = {isa = PBXBuildFile; fileRef = B37769BCBFDCACCA32CB732FFB0DAA20 /* BeLessThan.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 71591AC90458BECCD88F503B98B7E307 /* Set.swift in Sources */ = {isa = PBXBuildFile; fileRef = 96F31DEAF8546F97D13B6631A0613D6C /* Set.swift */; }; 737E19F3254F5929263982C29237C0BA /* CwlBadInstructionException.swift in Sources */ = {isa = PBXBuildFile; fileRef = 18F76549DC53A24E718801CA74B5AA09 /* CwlBadInstructionException.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 74FD712F3B503891B6BD9E5CD287E481 /* AssertionDispatcher.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5E235870D7A5353B927F7EBA6540C98D /* AssertionDispatcher.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 75ADBCD6658BE042CBE2EF88470AD142 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */; }; 76036D32625A56D480D84AA46961EF91 /* Nimble-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = 6BA9BDC9D1D74EFFEE8DC76C6DE0B7C7 /* Nimble-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 78F3DE174B4F8D368EF8EEFD7EE62087 /* BeVoid.swift in Sources */ = {isa = PBXBuildFile; fileRef = C23CDF8784A07DF2572B6822663C7933 /* BeVoid.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 7B7AB22D0F4F8BE806E6E64EBF69C086 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */; }; 7D2A4146047606E0D021403D9D2CA45A /* ExampleHooks.swift in Sources */ = {isa = PBXBuildFile; fileRef = EF8E3FA49E14F3F1714335FBAADF79B6 /* ExampleHooks.swift */; }; 7D6269A3CFE53C28DAA6B92E8FC017A7 /* FailureMessage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4A3BA563C4ADDE47EE94EB7E7ED106F5 /* FailureMessage.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 7F6750C7B1847733370B18C4CBFE32DF /* Errors.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9F19211B3AEEEC934B1FE393C5561046 /* Errors.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 8015239010C1D642F14C105F8FF8E035 /* Expression.swift in Sources */ = {isa = PBXBuildFile; fileRef = F748A8D90936AA999672DB5B2D47B07A /* Expression.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 810870C32C831856AA9056F4FBEC1512 /* SuiteHooks.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9C478096F55DAAFB3A4039B64FEFAE98 /* SuiteHooks.swift */; }; 8154A9D75CE273A5CA11AD734F8DD0AF /* Storage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 217580B44B73532ED783A1267CCDB3FA /* Storage.swift */; }; 83D71334D516ECEF04E52AF19341CF92 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3D7153B4402DAA3EEF052B341B37773F /* Cocoa.framework */; }; 84096C1960B46419BEAA85A22B353DB2 /* MemoryProperties.swift in Sources */ = {isa = PBXBuildFile; fileRef = 35699FC5A45F8604D9E53D74B994634E /* MemoryProperties.swift */; }; 8431C26BBC7EAB8C47681E2B96AB93B5 /* PersistentStorageSerializable.swift in Sources */ = {isa = PBXBuildFile; fileRef = F8E892409CB344988B711253F95DF9A6 /* PersistentStorageSerializable.swift */; }; 8507F4BF7437EB40A3626EDCC68BFF6D /* Contain.swift in Sources */ = {isa = PBXBuildFile; fileRef = 747AE697137B5D4B95170B071EAE349D /* Contain.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 8654571F855691C23B7B8E61B2141944 /* EndWith.swift in Sources */ = {isa = PBXBuildFile; fileRef = D5D9FE92E1B00D3504D61F30D99D12B4 /* EndWith.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 86FFB76B2EDCF4AE79CC4C0BD8A0FE9A /* DSL+Wait.swift in Sources */ = {isa = PBXBuildFile; fileRef = 578411CA2D094C30D95F87E06ADD724A /* DSL+Wait.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 87DD62F200DAB5E1D701AB9F94D1D422 /* CwlCatchException.h in Headers */ = {isa = PBXBuildFile; fileRef = 87B3D180D720E49401F81F66966E6417 /* CwlCatchException.h */; settings = {ATTRIBUTES = (Public, ); }; }; 88D2CD8353F07F320B24053F75B0AA8A /* SwiftTryCatch.m in Sources */ = {isa = PBXBuildFile; fileRef = B17CA6902411F751101E932D315A01A3 /* SwiftTryCatch.m */; }; 8C30EAD5FFD28B387099B41C74657A67 /* NMBExpectation.swift in Sources */ = {isa = PBXBuildFile; fileRef = F56CFE193CC4072A0438EA2F4E084175 /* NMBExpectation.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 8DFD3ED6E1F4FC0D540E0FE53C8D67D8 /* Construct.swift in Sources */ = {isa = PBXBuildFile; fileRef = 80C39B59F6205A8B8AF381514259A66D /* Construct.swift */; }; 917949F596E1188261FC59214782C3D9 /* NMBExceptionCapture.h in Headers */ = {isa = PBXBuildFile; fileRef = BF2FBABC3914541778F7605748F68659 /* NMBExceptionCapture.h */; settings = {ATTRIBUTES = (Public, ); }; }; 947162383483B6391F8CDF38249BFBD2 /* CwlCatchException.m in Sources */ = {isa = PBXBuildFile; fileRef = 441B373D2C5A3C7017EED3662A2E5E7C /* CwlCatchException.m */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 9544A4EEC2A8448743ECA9981F88B60F /* BeCloseTo.swift in Sources */ = {isa = PBXBuildFile; fileRef = E5BA4C3F41EC945CFBBFEF98BF01FB49 /* BeCloseTo.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 96DAA4B406FA5410F4D3474B8EDB890C /* Metadata+Tuple.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D6D4970F760DF36BCCBDE630066C7B2 /* Metadata+Tuple.swift */; }; 96E14093C91E8E1DB68029173EB8D45C /* URL+FileName.swift in Sources */ = {isa = PBXBuildFile; fileRef = C878728B2C3CFD5993B6822137CE771B /* URL+FileName.swift */; }; 970E9F902FFC919D23F51D8861E05EBC /* UserDefaultsStorage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 55ECD6A7CA8C0BE3247C517C2BF3CD48 /* UserDefaultsStorage.swift */; }; 9AF235C16362BA00BFBF12147907E953 /* BeEmpty.swift in Sources */ = {isa = PBXBuildFile; fileRef = BE30AD879574EA8033F752AC8AE0824B /* BeEmpty.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 9BEBD1791C233763A8DC13080BFB99C9 /* Stringers.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1751B926019ABF625854A4E26839A0CA /* Stringers.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; 9C547F2004309855E778AE6D60A10291 /* Configuration.swift in Sources */ = {isa = PBXBuildFile; fileRef = 219C092F09954399C1A31DF8A3206EAB /* Configuration.swift */; }; 9E605272EAFAAD942D11080DBE9CA985 /* QuickConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = CA7ED0ECCD1072B842759099B8A5BB64 /* QuickConfiguration.m */; }; 9E95D6E15DBE9B0FC92AAF60D42D1464 /* Nimble-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 4FA2C3F5E0A780BE8ACBF263F1144522 /* Nimble-dummy.m */; }; 9F08882A4973621F4AF68EB72EDF6239 /* NominalTypeDescriptor.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD2E21D6BE5962664A0A86D50A5F27FF /* NominalTypeDescriptor.swift */; }; A044BA198D7D7B695111CC1D2D72D8CB /* Metadata+Kind.swift in Sources */ = {isa = PBXBuildFile; fileRef = F8B180A74BF7DA9BBC0C73181205FB92 /* Metadata+Kind.swift */; }; A21134677479F6C55B6E5481D7AAA043 /* World.h in Headers */ = {isa = PBXBuildFile; fileRef = 67B1F98F024249532383E6CED2529B76 /* World.h */; settings = {ATTRIBUTES = (Project, ); }; }; A33F1754198E8E8CCC7087F6176FFDC8 /* BeIdenticalTo.swift in Sources */ = {isa = PBXBuildFile; fileRef = E540642D5AE67802640578D42DD3C385 /* BeIdenticalTo.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; A448F837592E21D9387322E8DA0DD93F /* BeAnInstanceOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = EB94377F385F2D67C9712226280BAFFD /* BeAnInstanceOf.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; A75A6FB66967A82A2FE709B7DA7D430E /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E91672B06B55CA166C0DBC1160D16897 /* Foundation.framework */; }; A91166D0A5E8F1D5D5377622C381C045 /* Match.swift in Sources */ = {isa = PBXBuildFile; fileRef = 588E4C9B1904E209FFFE7F7CEC43BAC9 /* Match.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; AB255C27EF10E742C6567775022F49D5 /* BeginWith.swift in Sources */ = {isa = PBXBuildFile; fileRef = D2EEA7B45558989FF3AC986804E224B5 /* BeginWith.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; AB2BA417AEEFD18FE0F73F80C97987CC /* Example.swift in Sources */ = {isa = PBXBuildFile; fileRef = 82A0734EE3DC7F6358E28BF8AE2FDF3E /* Example.swift */; }; AB2E65E61E97DB35009A8531 /* PlistStorage.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB2E65E51E97DB35009A8531 /* PlistStorage.swift */; }; AB2E65E71E97DB35009A8531 /* PlistStorage.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB2E65E51E97DB35009A8531 /* PlistStorage.swift */; }; AB7641581E9798B5007279BE /* PropertiesIteration.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB7641571E9798B5007279BE /* PropertiesIteration.swift */; }; AB7641591E9798B5007279BE /* PropertiesIteration.swift in Sources */ = {isa = PBXBuildFile; fileRef = AB7641571E9798B5007279BE /* PropertiesIteration.swift */; }; ABD62B3892A67B671316A6D145AF6761 /* UnsafePointer+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4F08D19A4E34CF4C3804349437273B90 /* UnsafePointer+Extensions.swift */; }; ABEACAEF1E9B6E4D004C1C2F /* SupportedSerializableType.swift in Sources */ = {isa = PBXBuildFile; fileRef = ABEACAEE1E9B6E4D004C1C2F /* SupportedSerializableType.swift */; }; ABEACAF01E9B6E4D004C1C2F /* SupportedSerializableType.swift in Sources */ = {isa = PBXBuildFile; fileRef = ABEACAEE1E9B6E4D004C1C2F /* SupportedSerializableType.swift */; }; AC0B24EF198E3BEDFCC9F25D7B8EEDAB /* NMBObjCMatcher.swift in Sources */ = {isa = PBXBuildFile; fileRef = 41415B1CBC6148AB3EAE70E253CDF09E /* NMBObjCMatcher.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; AC29CC89E22273BF0D0DC2C841B7524C /* Async.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5C9115DBFFBCA4CBC7B5D325CDFA974 /* Async.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; AC5137B44BDB6C4C38C6450791C1BAF4 /* Filter.swift in Sources */ = {isa = PBXBuildFile; fileRef = F51A6A4AD26C84606E8A06CEF80604CC /* Filter.swift */; }; AD5162BE3EE92A4A3197423D7040F0C5 /* NSString+QCKSelectorName.h in Headers */ = {isa = PBXBuildFile; fileRef = CDF2382E3A3EBF8C4EA56EA63B0450BC /* NSString+QCKSelectorName.h */; settings = {ATTRIBUTES = (Project, ); }; }; AD6BACF97D192AE3BC9AA98DBB6B0C8F /* Construct.swift in Sources */ = {isa = PBXBuildFile; fileRef = 80C39B59F6205A8B8AF381514259A66D /* Construct.swift */; }; ADAFA23A712E649A250F51E1E4A3B9A6 /* Array+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9578A4E1FCE35AB00735C22CFC7162C2 /* Array+Extensions.swift */; }; ADB23C0587582C77280651FABBBB20E7 /* Properties.swift in Sources */ = {isa = PBXBuildFile; fileRef = BE3AC896DCF9F346EDE03FFD0488C493 /* Properties.swift */; }; ADFCB73443130CB466C1EEE6422E3EA1 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3D7153B4402DAA3EEF052B341B37773F /* Cocoa.framework */; }; AFBB8B76ECE814775A6EC638AB37A43F /* Pods-PersistentStorageSerializable_Tests-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = 5CB4072DCEF8D77880842C53D041AB97 /* Pods-PersistentStorageSerializable_Tests-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; B093484B1637B3D3AF65DF2232FDBADC /* mach_excServer.h in Headers */ = {isa = PBXBuildFile; fileRef = 927DCA96CF6C59B4A98CBD6C063C6DE5 /* mach_excServer.h */; settings = {ATTRIBUTES = (Public, ); }; }; B12039684B5C118037A233D091B8E832 /* Quick-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = E28B0C352E6F01D475C896EB2AC2BF88 /* Quick-dummy.m */; }; B2231C0FB5071D40FDDCE3461FDB8F98 /* NominalTypeDescriptor.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD2E21D6BE5962664A0A86D50A5F27FF /* NominalTypeDescriptor.swift */; }; B6E3B1A8C83A31066CF8ED1A341AA5AA /* Callsite.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0AA4D8CFED2767407ECB264B19B3F94F /* Callsite.swift */; }; B7C651D3CB5879217669C82B3897B0E4 /* Metadata+Struct.swift in Sources */ = {isa = PBXBuildFile; fileRef = 08F6FE8EEAA8D621FB74B7B387C39435 /* Metadata+Struct.swift */; }; B894AA08164D83B7428202D518B328CC /* QuickSelectedTestSuiteBuilder.swift in Sources */ = {isa = PBXBuildFile; fileRef = F6243AD9E6311D7DCEFDEF4BC3A50859 /* QuickSelectedTestSuiteBuilder.swift */; }; B9BD565DAB07F8E2288A960A1D3EFAC1 /* MatcherFunc.swift in Sources */ = {isa = PBXBuildFile; fileRef = 688F1664230F9D437028E4FE35E2B787 /* MatcherFunc.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; BA09DEE84D61AFCD97C518D61A3D3A96 /* ReflectionError.swift in Sources */ = {isa = PBXBuildFile; fileRef = 972E1E97A8BE5406BCB6970C92C39D67 /* ReflectionError.swift */; }; BA72C62E612AC2615BFD2215E4E009E5 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3D7153B4402DAA3EEF052B341B37773F /* Cocoa.framework */; }; BAEFDCBE1577A385DBE693446B7A43E4 /* QuickTestSuite.swift in Sources */ = {isa = PBXBuildFile; fileRef = A1EABCA2C5F0C8116ADA4972CD177535 /* QuickTestSuite.swift */; }; BB10A2D0B1EE5B1BA811354116F83E3F /* CwlDarwinDefinitions.swift in Sources */ = {isa = PBXBuildFile; fileRef = D28E7A2DCC4CCB6CE200E402A592FE62 /* CwlDarwinDefinitions.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; BF232BD5ED6C85D9397D2F54335AC84F /* Metadata.swift in Sources */ = {isa = PBXBuildFile; fileRef = 22089DBC28F5B811B25675FBD14A464C /* Metadata.swift */; }; BF3AF1D2B46E09E2B3DCC824E6C1F5AF /* Equal.swift in Sources */ = {isa = PBXBuildFile; fileRef = A5F067F59522C866F69B1F02CAD8458D /* Equal.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; C059821F074270276AE2F165C8A2FA05 /* QuickSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = D78F0624BEB297D6125991F8F27CA381 /* QuickSpec.m */; }; C0A7EED80F769F12D2BD3846B7DF137C /* PersistentStorageSerializable-OSX-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = BBD89AD9CE542E5D5CA821020724FFBA /* PersistentStorageSerializable-OSX-dummy.m */; }; C1DD2D7CE982C0064A8448E4E661098E /* Closures.swift in Sources */ = {isa = PBXBuildFile; fileRef = B80B627A14B4E0A37EC0E7A9982A125D /* Closures.swift */; }; C331C441134E33E71ED4C596B95C10EA /* NSString+QCKSelectorName.m in Sources */ = {isa = PBXBuildFile; fileRef = 61BCEA4D2FE54567759B6361862E85A5 /* NSString+QCKSelectorName.m */; }; C60420491851A44ADA0989C09A0A00A8 /* PersistentStorageSerializable-iOS-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = A026A2D246B6B842F4B7564B2E87C903 /* PersistentStorageSerializable-iOS-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; C75B4E3F0052DF9F138A20EE54C52E87 /* Metadata+Struct.swift in Sources */ = {isa = PBXBuildFile; fileRef = 08F6FE8EEAA8D621FB74B7B387C39435 /* Metadata+Struct.swift */; }; C9510EA7D95C129CD044F451413547A6 /* Set.swift in Sources */ = {isa = PBXBuildFile; fileRef = 96F31DEAF8546F97D13B6631A0613D6C /* Set.swift */; }; CB7558CCDD935C9E82BBF454022ED1D3 /* Expectation.swift in Sources */ = {isa = PBXBuildFile; fileRef = E7E2F7C919910E3CBA06A9B9D7323E50 /* Expectation.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; CD6CC09B21B2BCBAA4F16A8613806246 /* Metadata+Class.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47982F2D4AB9B4C4719DA6F8802FC275 /* Metadata+Class.swift */; }; CE3FA6AE0944D4AE737F0E57CFF4A615 /* HaveCount.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1817B32F3FC7E047D8B9194BC1136606 /* HaveCount.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; CE4CEF6328E255B380E2B2692B351CF8 /* MatchError.swift in Sources */ = {isa = PBXBuildFile; fileRef = 620732F4BDA95B19DBB955D49CA1C5F9 /* MatchError.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; CEB1E434D27275AD2A65C817A838EF97 /* Reflection-OSX-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = C7BF7B887150EFCDEFB19473A8CCFB25 /* Reflection-OSX-dummy.m */; }; D1F0D71DC0ED03185D640B1D3EEA3150 /* SwiftTryCatch.m in Sources */ = {isa = PBXBuildFile; fileRef = B17CA6902411F751101E932D315A01A3 /* SwiftTryCatch.m */; }; D2CB5974414798DD931B35C52E1444FB /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */; }; D3B626F2AC4E553461FA5875C298D41B /* PointerType.swift in Sources */ = {isa = PBXBuildFile; fileRef = CA30706E8884E8F1B0E6CD2EA1B84275 /* PointerType.swift */; }; D4DD435BD76E710101BBACFBDA5539EE /* Pods-PersistentStorageSerializable_Tests-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = A18E35F09E61F21D2E34681DE3CAB1BB /* Pods-PersistentStorageSerializable_Tests-dummy.m */; }; D88575ED37BC462E8130CDBEFE9EA308 /* XCTestObservationCenter+Register.m in Sources */ = {isa = PBXBuildFile; fileRef = 23FB991E1056AD6AEA2355DD1A9F4C9C /* XCTestObservationCenter+Register.m */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; D9D0C0BB64E7C80001F92BE20AEDD20C /* NSBundle+CurrentTestBundle.swift in Sources */ = {isa = PBXBuildFile; fileRef = 475EE8B724BFCA089214492EB90258F4 /* NSBundle+CurrentTestBundle.swift */; }; DB5B42776D188C8BA01E7F214CE2B2E5 /* Advance.swift in Sources */ = {isa = PBXBuildFile; fileRef = 559C95F20B29BE7F707CA733C7738B29 /* Advance.swift */; }; DC32331BE565888E694E1321BB1D80F5 /* NMBExceptionCapture.m in Sources */ = {isa = PBXBuildFile; fileRef = CC381077BAF0D5E990F3FA9B68C3D1B9 /* NMBExceptionCapture.m */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; DCEE854E62441E78FED15CC994497F61 /* AllPass.swift in Sources */ = {isa = PBXBuildFile; fileRef = B0552E74FBD3E66212FFE3E8BE396E8F /* AllPass.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; DD70CBB5FBFE8E2BE8F6D2E2C7754A44 /* PointerType.swift in Sources */ = {isa = PBXBuildFile; fileRef = CA30706E8884E8F1B0E6CD2EA1B84275 /* PointerType.swift */; }; DF767D1E1FFE54AE90119C25E603B1C0 /* Reflection.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6EFD55C435B2B0C8D1D85EC50C34952E /* Reflection.framework */; }; E03BAAB6CA5552B89F00F4157D7E4552 /* Reflection.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6EFD55C435B2B0C8D1D85EC50C34952E /* Reflection.framework */; }; E0534D41B876E82FD0472460B8D51179 /* UserDefaultsStorage.swift in Sources */ = {isa = PBXBuildFile; fileRef = 55ECD6A7CA8C0BE3247C517C2BF3CD48 /* UserDefaultsStorage.swift */; }; E1A93DCEC817DE5770524BF75E840E08 /* Pods-PersistentStorageSerializable_iOSExample-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = C94794649537F0066EB7D122F0E30D60 /* Pods-PersistentStorageSerializable_iOSExample-dummy.m */; }; E522A8C892DC6E5CAEDC20148D704EF8 /* Quick.h in Headers */ = {isa = PBXBuildFile; fileRef = B8F86A7E42E45B16621FA7D141DDD102 /* Quick.h */; settings = {ATTRIBUTES = (Public, ); }; }; E5CCEF0B83F8272D10671C01AAE4FFA0 /* NimbleXCTestHandler.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8EA38D47FEF4AFE18A0F512010D99D16 /* NimbleXCTestHandler.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; E7B341CCA626B55029DA67A8F4D8E78B /* Get.swift in Sources */ = {isa = PBXBuildFile; fileRef = F15DABBF3A935A0689C332EA250AD0DE /* Get.swift */; }; E8B55982DC570A58CFCE688C476FD5F6 /* ErrorUtility.swift in Sources */ = {isa = PBXBuildFile; fileRef = AED6C0967624AED98816B8F1161F42BB /* ErrorUtility.swift */; }; EBA52C16F42E42A1824D87C284F4A60C /* PostNotification.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7535FB188FA658A1D4BE308C7260DFCB /* PostNotification.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; EEB1AB6DD725CC3E48EC1A253B8365A0 /* Identity.swift in Sources */ = {isa = PBXBuildFile; fileRef = 409470BF79C61A1DC5EE998F14636B1D /* Identity.swift */; }; EFCF71BE7182C23F3517B99A90EF647E /* Any+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = AD76B886530DC003364EE0F566036318 /* Any+Extensions.swift */; }; F20E741BBC41327AED358EB0E719D1CF /* SwiftTryCatch.h in Headers */ = {isa = PBXBuildFile; fileRef = AC46343C8BF32068677D41A1DC13B7EA /* SwiftTryCatch.h */; settings = {ATTRIBUTES = (Public, ); }; }; F4A1B7A059AAA6727EB70E58E09332A4 /* CwlCatchException.swift in Sources */ = {isa = PBXBuildFile; fileRef = A073FCA24B91588D8ACB577C9DC91B45 /* CwlCatchException.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; F5B288321A3A12AB215FCEFAC0208522 /* UnsafePointer+Extensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4F08D19A4E34CF4C3804349437273B90 /* UnsafePointer+Extensions.swift */; }; F60D221B548716DF35193FC2CF244676 /* BeAKindOf.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1917257A77F7B817A10400B4DAF65E20 /* BeAKindOf.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; F68273DF598C7366016B4942A61059B8 /* Get.swift in Sources */ = {isa = PBXBuildFile; fileRef = F15DABBF3A935A0689C332EA250AD0DE /* Get.swift */; }; F693D0A9E0D05F815A85DC258E75AF8D /* CurrentTestCaseTracker.h in Headers */ = {isa = PBXBuildFile; fileRef = 924D5CF3D65D791C1C28BA3301BD8BB6 /* CurrentTestCaseTracker.h */; settings = {ATTRIBUTES = (Private, ); }; }; F9D61EB5EEB799105913685722FF4C9C /* NimbleEnvironment.swift in Sources */ = {isa = PBXBuildFile; fileRef = EB22C6757F9B47F0DFEED8B0996FA956 /* NimbleEnvironment.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; F9E05A63D447B51E008B89731192FE7F /* AssertionRecorder.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0CF611AC318BFEB347CA578141B6DBB9 /* AssertionRecorder.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; FAB4ECE0C5039D99BB7173880670871D /* BeLessThanOrEqual.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3CB2BCB50D1984E0D33F874869511ACB /* BeLessThanOrEqual.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; FB0EEC25C35082E1C2E0BE2EFFF36EF8 /* Metadata+Class.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47982F2D4AB9B4C4719DA6F8802FC275 /* Metadata+Class.swift */; }; FCFFEB587281358CFF05A65ED9E94C12 /* Functional.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC2D23D7A476F61595C9DF0B6A4B1FB1 /* Functional.swift */; settings = {COMPILER_FLAGS = "-DPRODUCT_NAME=Nimble/Nimble"; }; }; FDD34D9019B0A1A2BD782EDF6F91DFBC /* QCKDSL.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A0483B4BB0243CC28E72E5FBD8DB68B /* QCKDSL.m */; }; /* End PBXBuildFile section */ /* Begin PBXContainerItemProxy section */ 0301C33F3EE8422150ECA9CD70476491 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = F0CEC1F3C61AFCB9ADA5919C64B003CE; remoteInfo = "Reflection-iOS"; }; 27510798F8AD1C92D9FB66C516C94881 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = F0CEC1F3C61AFCB9ADA5919C64B003CE; remoteInfo = "Reflection-iOS"; }; 362C7D8F64D2069669D0361A894B07DD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = 1321E318D10CFDC9F5B93A7952492CCD; remoteInfo = Nimble; }; 3C951DED5AEBD73277E58FD83A3DEAC1 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = B29FB212BE53D249CF080AF2FC6B42D5; remoteInfo = "PersistentStorageSerializable-OSX"; }; 4D2A85AFB5315F895ED8E20766C4B614 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = 810EE9CC72099DB8CE653C742754EC04; remoteInfo = "PersistentStorageSerializable-iOS"; }; 830ED203775A09F2188E8B7988E838FD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = F0CEC1F3C61AFCB9ADA5919C64B003CE; remoteInfo = "Reflection-iOS"; }; 893F510CFF86D0DAA159249D0A0A391D /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = 78DD5EB06C96485107D83E0183C84D70; remoteInfo = Quick; }; B26D0DAB801E487506A768E6C181571B /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = 8302DFE25125E545B660DD41FB4DAD67; remoteInfo = "Reflection-OSX"; }; D49CF07FCC46DBEEE26DD631094D3918 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = 810EE9CC72099DB8CE653C742754EC04; remoteInfo = "PersistentStorageSerializable-iOS"; }; D7611BE4244CB48B792553F5B14E126B /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; proxyType = 1; remoteGlobalIDString = 8302DFE25125E545B660DD41FB4DAD67; remoteInfo = "Reflection-OSX"; }; /* End PBXContainerItemProxy section */ /* Begin PBXFileReference section */ 00B18873BB378B52DE8BD4C15DD36011 /* ExampleMetadata.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ExampleMetadata.swift; path = Sources/Quick/ExampleMetadata.swift; sourceTree = ""; }; 011E5DDBA8311C08981F7D176417FCC8 /* CwlCatchBadInstruction.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = CwlCatchBadInstruction.swift; path = Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlCatchBadInstruction.swift; sourceTree = ""; }; 01EC2AA7495F252C13BD7234C74E79F3 /* Reflection-iOS-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = "Reflection-iOS-umbrella.h"; path = "../Reflection-iOS/Reflection-iOS-umbrella.h"; sourceTree = ""; }; 079BB80084E1A015AB255272CDD214F6 /* ThrowError.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ThrowError.swift; path = Sources/Nimble/Matchers/ThrowError.swift; sourceTree = ""; }; 08F6FE8EEAA8D621FB74B7B387C39435 /* Metadata+Struct.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "Metadata+Struct.swift"; path = "Sources/Reflection/Metadata+Struct.swift"; sourceTree = ""; }; 09C1992E68D8FC0C0241FC40D3899B5D /* Nimble.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = Nimble.xcconfig; sourceTree = ""; }; 09F16AFC755B1E7DA916EB123B4B433C /* Pods-PersistentStorageSerializable_iOSExample-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PersistentStorageSerializable_iOSExample-resources.sh"; sourceTree = ""; }; 0A7F4F011E3296C5BDBCDA0E0662448F /* RelativePointer.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = RelativePointer.swift; path = Sources/Reflection/RelativePointer.swift; sourceTree = ""; }; 0AA4D8CFED2767407ECB264B19B3F94F /* Callsite.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Callsite.swift; path = Sources/Quick/Callsite.swift; sourceTree = ""; }; 0CF611AC318BFEB347CA578141B6DBB9 /* AssertionRecorder.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = AssertionRecorder.swift; path = Sources/Nimble/Adapters/AssertionRecorder.swift; sourceTree = ""; }; 0FBD8197371FDDD1F56733D5344DA39C /* MetadataType.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = MetadataType.swift; path = Sources/Reflection/MetadataType.swift; sourceTree = ""; }; 0FF2C07CF5BF76578AEAF758FD251ED7 /* NMBStringify.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = NMBStringify.h; path = Sources/NimbleObjectiveC/NMBStringify.h; sourceTree = ""; }; 10BF599C02A2F92878A7D882C9611421 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 13BD39469AED51D519EF9058AC78DB5B /* Reflection-iOS-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = "Reflection-iOS-dummy.m"; path = "../Reflection-iOS/Reflection-iOS-dummy.m"; sourceTree = ""; }; 160CAC0E61452631C6449C6AD9B44A76 /* RaisesException.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = RaisesException.swift; path = Sources/Nimble/Matchers/RaisesException.swift; sourceTree = ""; }; 1751B926019ABF625854A4E26839A0CA /* Stringers.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Stringers.swift; path = Sources/Nimble/Utils/Stringers.swift; sourceTree = ""; }; 1817B32F3FC7E047D8B9194BC1136606 /* HaveCount.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = HaveCount.swift; path = Sources/Nimble/Matchers/HaveCount.swift; sourceTree = ""; }; 18785D0D7962AC70BC0DDD2600F7CAA9 /* Reflection-iOS.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; name = "Reflection-iOS.modulemap"; path = "../Reflection-iOS/Reflection-iOS.modulemap"; sourceTree = ""; }; 18F76549DC53A24E718801CA74B5AA09 /* CwlBadInstructionException.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = CwlBadInstructionException.swift; path = Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlBadInstructionException.swift; sourceTree = ""; }; 1917257A77F7B817A10400B4DAF65E20 /* BeAKindOf.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeAKindOf.swift; path = Sources/Nimble/Matchers/BeAKindOf.swift; sourceTree = ""; }; 1AD12082F1076D96DAC1FD9A39D116A7 /* PersistentStorageSerializable-OSX.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "PersistentStorageSerializable-OSX.xcconfig"; sourceTree = ""; }; 1D92A2C0B35822F6671F491C09EC6EDB /* Pods_PersistentStorageSerializable_iOSExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_PersistentStorageSerializable_iOSExample.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 1E991206BBAD4F0FA3A741A59A57E783 /* Pods-PersistentStorageSerializable_iOSExample-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-PersistentStorageSerializable_iOSExample-acknowledgements.markdown"; sourceTree = ""; }; 213549B893FEA076CD035251ADFE9845 /* Pods-PersistentStorageSerializable_Tests.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Pods-PersistentStorageSerializable_Tests.modulemap"; sourceTree = ""; }; 217580B44B73532ED783A1267CCDB3FA /* Storage.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Storage.swift; path = Sources/Reflection/Storage.swift; sourceTree = ""; }; 219C092F09954399C1A31DF8A3206EAB /* Configuration.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Configuration.swift; path = Sources/Quick/Configuration/Configuration.swift; sourceTree = ""; }; 22089DBC28F5B811B25675FBD14A464C /* Metadata.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Metadata.swift; path = Sources/Reflection/Metadata.swift; sourceTree = ""; }; 236C27708A8A6A5A6183983A059511E4 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = Info.plist; path = "../Reflection-iOS/Info.plist"; sourceTree = ""; }; 23FB991E1056AD6AEA2355DD1A9F4C9C /* XCTestObservationCenter+Register.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = "XCTestObservationCenter+Register.m"; path = "Sources/NimbleObjectiveC/XCTestObservationCenter+Register.m"; sourceTree = ""; }; 2447827F13EA2ED7E904EA15F647F2EA /* Quick.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Quick.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 272AA0D36A2B77FCF978B083C7D8673C /* Pods-PersistentStorageSerializable_iOSExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PersistentStorageSerializable_iOSExample.release.xcconfig"; sourceTree = ""; }; 297F08DEBA780355103E1943E91C9863 /* ValueWitnessTable.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ValueWitnessTable.swift; path = Sources/Reflection/ValueWitnessTable.swift; sourceTree = ""; }; 3075226313FF83346C5B4B26AFC5D7C7 /* Pods-PersistentStorageSerializable_iOSExample-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PersistentStorageSerializable_iOSExample-frameworks.sh"; sourceTree = ""; }; 330960B91D30A9CFAE24181F3B16FD69 /* Pods-PersistentStorageSerializable_MacExample-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-PersistentStorageSerializable_MacExample-acknowledgements.plist"; sourceTree = ""; }; 35699FC5A45F8604D9E53D74B994634E /* MemoryProperties.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = MemoryProperties.swift; path = Sources/Reflection/MemoryProperties.swift; sourceTree = ""; }; 37FEFD4566840955F87EC36E6CFA43F1 /* Pods-PersistentStorageSerializable_MacExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PersistentStorageSerializable_MacExample.debug.xcconfig"; sourceTree = ""; }; 38E7ED6F46ED044FD279837053FB0991 /* DSL.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = DSL.h; path = Sources/NimbleObjectiveC/DSL.h; sourceTree = ""; }; 3A92C161CC0365639BDA3BF5C09D75B0 /* QCKDSL.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = QCKDSL.h; path = Sources/QuickObjectiveC/DSL/QCKDSL.h; sourceTree = ""; }; 3AA62C473D27598FC7557C82330D047A /* DSL.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = DSL.swift; path = Sources/Quick/DSL/DSL.swift; sourceTree = ""; }; 3CB2BCB50D1984E0D33F874869511ACB /* BeLessThanOrEqual.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeLessThanOrEqual.swift; path = Sources/Nimble/Matchers/BeLessThanOrEqual.swift; sourceTree = ""; }; 3D6D4970F760DF36BCCBDE630066C7B2 /* Metadata+Tuple.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "Metadata+Tuple.swift"; path = "Sources/Reflection/Metadata+Tuple.swift"; sourceTree = ""; }; 3D7153B4402DAA3EEF052B341B37773F /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/Cocoa.framework; sourceTree = DEVELOPER_DIR; }; 3DB462E985BF4F3D549283CCE0813916 /* DSL.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = DSL.m; path = Sources/NimbleObjectiveC/DSL.m; sourceTree = ""; }; 3F6AF0730A8A933938DC9F34A8A068E2 /* Pods-PersistentStorageSerializable_Tests-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PersistentStorageSerializable_Tests-frameworks.sh"; sourceTree = ""; }; 40337972E5B074C5A690D3990DF7905F /* CwlCatchBadInstruction.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = CwlCatchBadInstruction.h; path = Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlCatchBadInstruction.h; sourceTree = ""; }; 409470BF79C61A1DC5EE998F14636B1D /* Identity.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Identity.swift; path = Sources/Reflection/Identity.swift; sourceTree = ""; }; 40D4F0906C3E8D0F7BD6A7B203991625 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 41415B1CBC6148AB3EAE70E253CDF09E /* NMBObjCMatcher.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = NMBObjCMatcher.swift; path = Sources/Nimble/Adapters/NMBObjCMatcher.swift; sourceTree = ""; }; 441B373D2C5A3C7017EED3662A2E5E7C /* CwlCatchException.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = CwlCatchException.m; path = Sources/Lib/CwlPreconditionTesting/CwlCatchException/CwlCatchException/CwlCatchException.m; sourceTree = ""; }; 449695496334292237F7ABF92C612C79 /* Reflection-OSX.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Reflection-OSX.xcconfig"; sourceTree = ""; }; 45186F11C51E26728BB50D85C0390181 /* AdapterProtocols.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = AdapterProtocols.swift; path = Sources/Nimble/Adapters/AdapterProtocols.swift; sourceTree = ""; }; 45326A29AFE6D19B42FE6CAAAC531328 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 469E378328AB74CE2F16E82A53E9FAAA /* CwlCatchBadInstruction.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = CwlCatchBadInstruction.m; path = Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlCatchBadInstruction.m; sourceTree = ""; }; 475EE8B724BFCA089214492EB90258F4 /* NSBundle+CurrentTestBundle.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "NSBundle+CurrentTestBundle.swift"; path = "Sources/Quick/NSBundle+CurrentTestBundle.swift"; sourceTree = ""; }; 47982F2D4AB9B4C4719DA6F8802FC275 /* Metadata+Class.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "Metadata+Class.swift"; path = "Sources/Reflection/Metadata+Class.swift"; sourceTree = ""; }; 48BE6F62489EFA706F38F78647FD9728 /* PersistentStorageSerializable-iOS.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; name = "PersistentStorageSerializable-iOS.modulemap"; path = "../PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS.modulemap"; sourceTree = ""; }; 4A3BA563C4ADDE47EE94EB7E7ED106F5 /* FailureMessage.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = FailureMessage.swift; path = Sources/Nimble/FailureMessage.swift; sourceTree = ""; }; 4AB1B530FD4746C7F1ED45FB4D5A9874 /* QuickConfiguration.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = QuickConfiguration.h; path = Sources/QuickObjectiveC/Configuration/QuickConfiguration.h; sourceTree = ""; }; 4AF86E0EEBE4ECA5D93983C10918FE02 /* XCTest.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = XCTest.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS10.0.sdk/System/Library/Frameworks/XCTest.framework; sourceTree = DEVELOPER_DIR; }; 4B9854299BC061D75E995BB3C3634F23 /* SatisfyAnyOf.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = SatisfyAnyOf.swift; path = Sources/Nimble/Matchers/SatisfyAnyOf.swift; sourceTree = ""; }; 4F08D19A4E34CF4C3804349437273B90 /* UnsafePointer+Extensions.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "UnsafePointer+Extensions.swift"; path = "Sources/Reflection/UnsafePointer+Extensions.swift"; sourceTree = ""; }; 4FA2C3F5E0A780BE8ACBF263F1144522 /* Nimble-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Nimble-dummy.m"; sourceTree = ""; }; 4FFE5B7B0ECD5BFF9BF32C39E01BF3CF /* Reflection-OSX-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Reflection-OSX-prefix.pch"; sourceTree = ""; }; 539A7260F2A2B5AB2DF4494D3EBFD410 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; name = Info.plist; path = "../PersistentStorageSerializable-iOS/Info.plist"; sourceTree = ""; }; 549FEBEE27325E9E177BE6D99C52B08C /* PersistentStorageSerializable.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = PersistentStorageSerializable.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 559C95F20B29BE7F707CA733C7738B29 /* Advance.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Advance.swift; path = Sources/Reflection/Advance.swift; sourceTree = ""; }; 55ECD6A7CA8C0BE3247C517C2BF3CD48 /* UserDefaultsStorage.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = UserDefaultsStorage.swift; sourceTree = ""; }; 574E9F7002EDCC105A916FA3AEC5E703 /* PersistentStorageSerializable.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = PersistentStorageSerializable.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 578411CA2D094C30D95F87E06ADD724A /* DSL+Wait.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "DSL+Wait.swift"; path = "Sources/Nimble/DSL+Wait.swift"; sourceTree = ""; }; 588E4C9B1904E209FFFE7F7CEC43BAC9 /* Match.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Match.swift; path = Sources/Nimble/Matchers/Match.swift; sourceTree = ""; }; 5A0483B4BB0243CC28E72E5FBD8DB68B /* QCKDSL.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = QCKDSL.m; path = Sources/QuickObjectiveC/DSL/QCKDSL.m; sourceTree = ""; }; 5CB4072DCEF8D77880842C53D041AB97 /* Pods-PersistentStorageSerializable_Tests-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-PersistentStorageSerializable_Tests-umbrella.h"; sourceTree = ""; }; 5E235870D7A5353B927F7EBA6540C98D /* AssertionDispatcher.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = AssertionDispatcher.swift; path = Sources/Nimble/Adapters/AssertionDispatcher.swift; sourceTree = ""; }; 5E29A6AE6378CC0FFE2CBF7A691DF366 /* World+DSL.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = "World+DSL.h"; path = "Sources/QuickObjectiveC/DSL/World+DSL.h"; sourceTree = ""; }; 5F7A1D7D610669DBC95F6145CE72F1E6 /* ExampleGroup.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ExampleGroup.swift; path = Sources/Quick/ExampleGroup.swift; sourceTree = ""; }; 61BCEA4D2FE54567759B6361862E85A5 /* NSString+QCKSelectorName.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = "NSString+QCKSelectorName.m"; path = "Sources/QuickObjectiveC/NSString+QCKSelectorName.m"; sourceTree = ""; }; 620732F4BDA95B19DBB955D49CA1C5F9 /* MatchError.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = MatchError.swift; path = Sources/Nimble/Matchers/MatchError.swift; sourceTree = ""; }; 6390C415FDF7E2074F9679B0EF4E9DA1 /* Pods-PersistentStorageSerializable_iOSExample.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Pods-PersistentStorageSerializable_iOSExample.modulemap"; sourceTree = ""; }; 66EA1514CB8DCAB8B490F192914CCE88 /* Reflection-iOS.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Reflection-iOS.xcconfig"; path = "../Reflection-iOS/Reflection-iOS.xcconfig"; sourceTree = ""; }; 67B1F98F024249532383E6CED2529B76 /* World.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = World.h; path = Sources/QuickObjectiveC/World.h; sourceTree = ""; }; 688F1664230F9D437028E4FE35E2B787 /* MatcherFunc.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = MatcherFunc.swift; path = Sources/Nimble/Matchers/MatcherFunc.swift; sourceTree = ""; }; 68E8EB308595205EAFD2911F340CA696 /* DSL.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = DSL.swift; path = Sources/Nimble/DSL.swift; sourceTree = ""; }; 6ADE93DC4F670B429664153334AC498A /* World+DSL.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "World+DSL.swift"; path = "Sources/Quick/DSL/World+DSL.swift"; sourceTree = ""; }; 6BA9BDC9D1D74EFFEE8DC76C6DE0B7C7 /* Nimble-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Nimble-umbrella.h"; sourceTree = ""; }; 6DDCF5299547FB5521D650CE6A57F2AF /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 6EFD55C435B2B0C8D1D85EC50C34952E /* Reflection.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Reflection.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 7198266CDCBE981765D73B51A366A2EC /* BeNil.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeNil.swift; path = Sources/Nimble/Matchers/BeNil.swift; sourceTree = ""; }; 747AE697137B5D4B95170B071EAE349D /* Contain.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Contain.swift; path = Sources/Nimble/Matchers/Contain.swift; sourceTree = ""; }; 7535FB188FA658A1D4BE308C7260DFCB /* PostNotification.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = PostNotification.swift; path = Sources/Nimble/Matchers/PostNotification.swift; sourceTree = ""; }; 75E42118B71F2B29F7881C63C2B011FB /* PersistentStorageSerializable-iOS-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = "PersistentStorageSerializable-iOS-prefix.pch"; path = "../PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-prefix.pch"; sourceTree = ""; }; 7CC161CB4301C486CAB9553D7771F325 /* HooksPhase.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = HooksPhase.swift; path = Sources/Quick/Hooks/HooksPhase.swift; sourceTree = ""; }; 7EA1857941993C28916ABAA7338C2124 /* Nimble.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Nimble.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 80C39B59F6205A8B8AF381514259A66D /* Construct.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Construct.swift; path = Sources/Reflection/Construct.swift; sourceTree = ""; }; 82A0734EE3DC7F6358E28BF8AE2FDF3E /* Example.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Example.swift; path = Sources/Quick/Example.swift; sourceTree = ""; }; 82BB205A9D6D44244AAAF4109F30BBAC /* Reflection-OSX.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Reflection-OSX.modulemap"; sourceTree = ""; }; 8383C2DB5F3EB2FE3DFB4992A399343B /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 83845FD26AACEFCEC9B6152D1153AE71 /* NMBStringify.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = NMBStringify.m; path = Sources/NimbleObjectiveC/NMBStringify.m; sourceTree = ""; }; 8564F055BF244AF3234A9A5931029A54 /* Reflection-iOS-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = "Reflection-iOS-prefix.pch"; path = "../Reflection-iOS/Reflection-iOS-prefix.pch"; sourceTree = ""; }; 85D107FD08A65476FFB42BF6F74A3DB2 /* Quick.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = Quick.modulemap; sourceTree = ""; }; 87B3D180D720E49401F81F66966E6417 /* CwlCatchException.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = CwlCatchException.h; path = Sources/Lib/CwlPreconditionTesting/CwlCatchException/CwlCatchException/CwlCatchException.h; sourceTree = ""; }; 88A0A2C900F1B0DA95C4E099D8EF69DE /* Reflection-OSX-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Reflection-OSX-umbrella.h"; sourceTree = ""; }; 89CA505A4090716FCFBB675A171D4137 /* Quick.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = Quick.xcconfig; sourceTree = ""; }; 8D9D52F249D62845DF022590C42147CD /* Pods-PersistentStorageSerializable_Tests-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-PersistentStorageSerializable_Tests-acknowledgements.markdown"; sourceTree = ""; }; 8EA38D47FEF4AFE18A0F512010D99D16 /* NimbleXCTestHandler.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = NimbleXCTestHandler.swift; path = Sources/Nimble/Adapters/NimbleXCTestHandler.swift; sourceTree = ""; }; 8F48EBA91CB748656BB261C2366EF4A5 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 8F942B77C05759400B0802230EA76478 /* PersistentStorageSerializable-OSX.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "PersistentStorageSerializable-OSX.modulemap"; sourceTree = ""; }; 924D5CF3D65D791C1C28BA3301BD8BB6 /* CurrentTestCaseTracker.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = CurrentTestCaseTracker.h; path = Sources/NimbleObjectiveC/CurrentTestCaseTracker.h; sourceTree = ""; }; 927DCA96CF6C59B4A98CBD6C063C6DE5 /* mach_excServer.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = mach_excServer.h; path = Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/mach_excServer.h; sourceTree = ""; }; 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; name = Podfile; path = ../Podfile; sourceTree = SOURCE_ROOT; xcLanguageSpecificationIdentifier = xcode.lang.ruby; }; 944DE07F663B6872169C028461F2F467 /* Pods-PersistentStorageSerializable_MacExample-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-PersistentStorageSerializable_MacExample-acknowledgements.markdown"; sourceTree = ""; }; 9578A4E1FCE35AB00735C22CFC7162C2 /* Array+Extensions.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "Array+Extensions.swift"; path = "Sources/Reflection/Array+Extensions.swift"; sourceTree = ""; }; 96F31DEAF8546F97D13B6631A0613D6C /* Set.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Set.swift; path = Sources/Reflection/Set.swift; sourceTree = ""; }; 972E1E97A8BE5406BCB6970C92C39D67 /* ReflectionError.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ReflectionError.swift; path = Sources/Reflection/ReflectionError.swift; sourceTree = ""; }; 9BA1549C5D1B25AFA3C649C78FA1F854 /* PersistentStorageSerializable-iOS-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = "PersistentStorageSerializable-iOS-dummy.m"; path = "../PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-dummy.m"; sourceTree = ""; }; 9C478096F55DAAFB3A4039B64FEFAE98 /* SuiteHooks.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = SuiteHooks.swift; path = Sources/Quick/Hooks/SuiteHooks.swift; sourceTree = ""; }; 9D8169968C7213ADA57D2C051D306C17 /* Nimble.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = Nimble.modulemap; sourceTree = ""; }; 9E14E05F296DA5CB818FF86D62211B6C /* Pods-PersistentStorageSerializable_MacExample.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = "sourcecode.module-map"; path = "Pods-PersistentStorageSerializable_MacExample.modulemap"; sourceTree = ""; }; 9F19211B3AEEEC934B1FE393C5561046 /* Errors.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Errors.swift; path = Sources/Nimble/Utils/Errors.swift; sourceTree = ""; }; A026A2D246B6B842F4B7564B2E87C903 /* PersistentStorageSerializable-iOS-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = "PersistentStorageSerializable-iOS-umbrella.h"; path = "../PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-umbrella.h"; sourceTree = ""; }; A073FCA24B91588D8ACB577C9DC91B45 /* CwlCatchException.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = CwlCatchException.swift; path = Sources/Lib/CwlPreconditionTesting/CwlCatchException/CwlCatchException/CwlCatchException.swift; sourceTree = ""; }; A0786455757A284E0F80A4F1D4140D38 /* Pods_PersistentStorageSerializable_MacExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_PersistentStorageSerializable_MacExample.framework; sourceTree = BUILT_PRODUCTS_DIR; }; A18E35F09E61F21D2E34681DE3CAB1BB /* Pods-PersistentStorageSerializable_Tests-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-PersistentStorageSerializable_Tests-dummy.m"; sourceTree = ""; }; A1EABCA2C5F0C8116ADA4972CD177535 /* QuickTestSuite.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = QuickTestSuite.swift; path = Sources/Quick/QuickTestSuite.swift; sourceTree = ""; }; A2FA10E38A6C6E200ABA275E72DD4023 /* BeLogical.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeLogical.swift; path = Sources/Nimble/Matchers/BeLogical.swift; sourceTree = ""; }; A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS10.0.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; }; A41ACB6A39BC53C1AD5ECDF57143D17F /* Nimble.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = Nimble.h; path = Sources/Nimble/Nimble.h; sourceTree = ""; }; A4B56A6EED0B50275C67F754263391DA /* Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig"; sourceTree = ""; }; A5C9115DBFFBCA4CBC7B5D325CDFA974 /* Async.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Async.swift; path = Sources/Nimble/Utils/Async.swift; sourceTree = ""; }; A5E6BFF347E9847E936924A832FBABBB /* SourceLocation.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = SourceLocation.swift; path = Sources/Nimble/Utils/SourceLocation.swift; sourceTree = ""; }; A5F067F59522C866F69B1F02CAD8458D /* Equal.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Equal.swift; path = Sources/Nimble/Matchers/Equal.swift; sourceTree = ""; }; A8B01A7115AF84CE2793835F62484967 /* mach_excServer.c */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.c; name = mach_excServer.c; path = Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/mach_excServer.c; sourceTree = ""; }; AB2E65E51E97DB35009A8531 /* PlistStorage.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = PlistStorage.swift; sourceTree = ""; }; AB379B8B8259CE097D226FB13A1FC648 /* PersistentStorageSerializable-iOS.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "PersistentStorageSerializable-iOS.xcconfig"; path = "../PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS.xcconfig"; sourceTree = ""; }; AB7641571E9798B5007279BE /* PropertiesIteration.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = PropertiesIteration.swift; sourceTree = ""; }; ABEACAEE1E9B6E4D004C1C2F /* SupportedSerializableType.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SupportedSerializableType.swift; sourceTree = ""; }; AC46343C8BF32068677D41A1DC13B7EA /* SwiftTryCatch.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = SwiftTryCatch.h; sourceTree = ""; }; AC711F896F1F753CD40D0336E1891051 /* NominalType.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = NominalType.swift; path = Sources/Reflection/NominalType.swift; sourceTree = ""; }; AD76B886530DC003364EE0F566036318 /* Any+Extensions.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "Any+Extensions.swift"; path = "Sources/Reflection/Any+Extensions.swift"; sourceTree = ""; }; AED6C0967624AED98816B8F1161F42BB /* ErrorUtility.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ErrorUtility.swift; path = Sources/Quick/ErrorUtility.swift; sourceTree = ""; }; AFB88A73C0CB8BEA601FC0FFCAC65E93 /* AsyncMatcherWrapper.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = AsyncMatcherWrapper.swift; path = Sources/Nimble/Matchers/AsyncMatcherWrapper.swift; sourceTree = ""; }; B0552E74FBD3E66212FFE3E8BE396E8F /* AllPass.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = AllPass.swift; path = Sources/Nimble/Matchers/AllPass.swift; sourceTree = ""; }; B17CA6902411F751101E932D315A01A3 /* SwiftTryCatch.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = SwiftTryCatch.m; sourceTree = ""; }; B23DC3D7DA990D4E2939C1BC4496A08A /* PersistentStorageSerializable-OSX-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "PersistentStorageSerializable-OSX-umbrella.h"; sourceTree = ""; }; B37769BCBFDCACCA32CB732FFB0DAA20 /* BeLessThan.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeLessThan.swift; path = Sources/Nimble/Matchers/BeLessThan.swift; sourceTree = ""; }; B4F57D336E8CD0C8E07BF34E6FBCF86E /* Pods-PersistentStorageSerializable_Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PersistentStorageSerializable_Tests.debug.xcconfig"; sourceTree = ""; }; B80B627A14B4E0A37EC0E7A9982A125D /* Closures.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Closures.swift; path = Sources/Quick/Hooks/Closures.swift; sourceTree = ""; }; B843A390CA2C46325E617109CE7C00B4 /* Pods-PersistentStorageSerializable_MacExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PersistentStorageSerializable_MacExample.release.xcconfig"; sourceTree = ""; }; B8F86A7E42E45B16621FA7D141DDD102 /* Quick.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = Quick.h; path = Sources/QuickObjectiveC/Quick.h; sourceTree = ""; }; B9C83EAA39CDD9F7107D4D7F499A4D03 /* Quick-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Quick-prefix.pch"; sourceTree = ""; }; BBD89AD9CE542E5D5CA821020724FFBA /* PersistentStorageSerializable-OSX-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "PersistentStorageSerializable-OSX-dummy.m"; sourceTree = ""; }; BC62F6B906201B92A5E117B29415D918 /* Pods-PersistentStorageSerializable_iOSExample-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-PersistentStorageSerializable_iOSExample-umbrella.h"; sourceTree = ""; }; BE30AD879574EA8033F752AC8AE0824B /* BeEmpty.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeEmpty.swift; path = Sources/Nimble/Matchers/BeEmpty.swift; sourceTree = ""; }; BE3AC896DCF9F346EDE03FFD0488C493 /* Properties.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Properties.swift; path = Sources/Reflection/Properties.swift; sourceTree = ""; }; BF2FBABC3914541778F7605748F68659 /* NMBExceptionCapture.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = NMBExceptionCapture.h; path = Sources/NimbleObjectiveC/NMBExceptionCapture.h; sourceTree = ""; }; C00223D84C0D987C5C44B6E450DCB8F3 /* Pods-PersistentStorageSerializable_Tests-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PersistentStorageSerializable_Tests-resources.sh"; sourceTree = ""; }; C23CDF8784A07DF2572B6822663C7933 /* BeVoid.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeVoid.swift; path = Sources/Nimble/Matchers/BeVoid.swift; sourceTree = ""; }; C4AD1312A77F4A770BB0CC46BEC8DBA5 /* MatcherProtocols.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = MatcherProtocols.swift; path = Sources/Nimble/Matchers/MatcherProtocols.swift; sourceTree = ""; }; C7BF7B887150EFCDEFB19473A8CCFB25 /* Reflection-OSX-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Reflection-OSX-dummy.m"; sourceTree = ""; }; C878728B2C3CFD5993B6822137CE771B /* URL+FileName.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "URL+FileName.swift"; path = "Sources/Quick/URL+FileName.swift"; sourceTree = ""; }; C94794649537F0066EB7D122F0E30D60 /* Pods-PersistentStorageSerializable_iOSExample-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-PersistentStorageSerializable_iOSExample-dummy.m"; sourceTree = ""; }; C9633F84E2EEA318823E16E16FA3E7CE /* Pods-PersistentStorageSerializable_Tests-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-PersistentStorageSerializable_Tests-acknowledgements.plist"; sourceTree = ""; }; CA172C3BBC2F641B659ED5C623805BDC /* Pods_PersistentStorageSerializable_Tests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_PersistentStorageSerializable_Tests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; CA30706E8884E8F1B0E6CD2EA1B84275 /* PointerType.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = PointerType.swift; path = Sources/Reflection/PointerType.swift; sourceTree = ""; }; CA7ED0ECCD1072B842759099B8A5BB64 /* QuickConfiguration.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = QuickConfiguration.m; path = Sources/QuickObjectiveC/Configuration/QuickConfiguration.m; sourceTree = ""; }; CC381077BAF0D5E990F3FA9B68C3D1B9 /* NMBExceptionCapture.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = NMBExceptionCapture.m; path = Sources/NimbleObjectiveC/NMBExceptionCapture.m; sourceTree = ""; }; CD13BDB1BAB67FC79EF84323384574CE /* Pods-PersistentStorageSerializable_MacExample-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PersistentStorageSerializable_MacExample-frameworks.sh"; sourceTree = ""; }; CDF2382E3A3EBF8C4EA56EA63B0450BC /* NSString+QCKSelectorName.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = "NSString+QCKSelectorName.h"; path = "Sources/QuickObjectiveC/NSString+QCKSelectorName.h"; sourceTree = ""; }; CDFE125ABF7991778EB9DCFEBE1980AD /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; CE13F5C238F2F59965B512E89C0D946B /* BeGreaterThanOrEqualTo.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeGreaterThanOrEqualTo.swift; path = Sources/Nimble/Matchers/BeGreaterThanOrEqualTo.swift; sourceTree = ""; }; D28E7A2DCC4CCB6CE200E402A592FE62 /* CwlDarwinDefinitions.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = CwlDarwinDefinitions.swift; path = Sources/Lib/CwlPreconditionTesting/CwlPreconditionTesting/CwlDarwinDefinitions.swift; sourceTree = ""; }; D2EEA7B45558989FF3AC986804E224B5 /* BeginWith.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeginWith.swift; path = Sources/Nimble/Matchers/BeginWith.swift; sourceTree = ""; }; D3B7A9361C95282C7B4CDDB9F84197FF /* Pods-PersistentStorageSerializable_MacExample-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-PersistentStorageSerializable_MacExample-dummy.m"; sourceTree = ""; }; D3F8840B178F3FF2FC53CE285B77F87E /* Nimble-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Nimble-prefix.pch"; sourceTree = ""; }; D5D9FE92E1B00D3504D61F30D99D12B4 /* EndWith.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = EndWith.swift; path = Sources/Nimble/Matchers/EndWith.swift; sourceTree = ""; }; D78F0624BEB297D6125991F8F27CA381 /* QuickSpec.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = QuickSpec.m; path = Sources/QuickObjectiveC/QuickSpec.m; sourceTree = ""; }; DD2E21D6BE5962664A0A86D50A5F27FF /* NominalTypeDescriptor.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = NominalTypeDescriptor.swift; path = Sources/Reflection/NominalTypeDescriptor.swift; sourceTree = ""; }; DDAB3E7FAA610141534F47F426392A3D /* Pods-PersistentStorageSerializable_Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PersistentStorageSerializable_Tests.release.xcconfig"; sourceTree = ""; }; DEED2885ABD003AA6FD143802588C6B4 /* BeGreaterThan.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeGreaterThan.swift; path = Sources/Nimble/Matchers/BeGreaterThan.swift; sourceTree = ""; }; E09F71C71226DABFB704EBB455FD474D /* Pods-PersistentStorageSerializable_MacExample-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PersistentStorageSerializable_MacExample-resources.sh"; sourceTree = ""; }; E12E2760F92F1A2C4D26629773BE116E /* PersistentStorage.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = PersistentStorage.swift; sourceTree = ""; }; E196A082C7CA44AB8438286B821016A9 /* Quick-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Quick-umbrella.h"; sourceTree = ""; }; E28B0C352E6F01D475C896EB2AC2BF88 /* Quick-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Quick-dummy.m"; sourceTree = ""; }; E540642D5AE67802640578D42DD3C385 /* BeIdenticalTo.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeIdenticalTo.swift; path = Sources/Nimble/Matchers/BeIdenticalTo.swift; sourceTree = ""; }; E5BA4C3F41EC945CFBBFEF98BF01FB49 /* BeCloseTo.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeCloseTo.swift; path = Sources/Nimble/Matchers/BeCloseTo.swift; sourceTree = ""; }; E7E2F7C919910E3CBA06A9B9D7323E50 /* Expectation.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Expectation.swift; path = Sources/Nimble/Expectation.swift; sourceTree = ""; }; E91672B06B55CA166C0DBC1160D16897 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; }; EAC1A086219F60C7564C880B9CE22833 /* Reflection.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Reflection.framework; sourceTree = BUILT_PRODUCTS_DIR; }; EB22C6757F9B47F0DFEED8B0996FA956 /* NimbleEnvironment.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = NimbleEnvironment.swift; path = Sources/Nimble/Adapters/NimbleEnvironment.swift; sourceTree = ""; }; EB94377F385F2D67C9712226280BAFFD /* BeAnInstanceOf.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = BeAnInstanceOf.swift; path = Sources/Nimble/Matchers/BeAnInstanceOf.swift; sourceTree = ""; }; EC2D23D7A476F61595C9DF0B6A4B1FB1 /* Functional.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Functional.swift; path = Sources/Nimble/Utils/Functional.swift; sourceTree = ""; }; EE9A987E830816D13D423881223CAD20 /* World.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = World.swift; path = Sources/Quick/World.swift; sourceTree = ""; }; EF8E3FA49E14F3F1714335FBAADF79B6 /* ExampleHooks.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ExampleHooks.swift; path = Sources/Quick/Hooks/ExampleHooks.swift; sourceTree = ""; }; F002B2610679A6F73A8EBDAE1FB8B769 /* Reflection.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Reflection.framework; sourceTree = BUILT_PRODUCTS_DIR; }; F15DABBF3A935A0689C332EA250AD0DE /* Get.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Get.swift; path = Sources/Reflection/Get.swift; sourceTree = ""; }; F18E3ACFDE1E8E7880CCE9E1210A80AC /* PersistentStorageSerializable-OSX-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "PersistentStorageSerializable-OSX-prefix.pch"; sourceTree = ""; }; F2426CDF7725EBE8B022AB5940A504C8 /* ThrowAssertion.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ThrowAssertion.swift; path = Sources/Nimble/Matchers/ThrowAssertion.swift; sourceTree = ""; }; F51A6A4AD26C84606E8A06CEF80604CC /* Filter.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Filter.swift; path = Sources/Quick/Filter.swift; sourceTree = ""; }; F56CFE193CC4072A0438EA2F4E084175 /* NMBExpectation.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = NMBExpectation.swift; path = Sources/Nimble/Adapters/NMBExpectation.swift; sourceTree = ""; }; F6243AD9E6311D7DCEFDEF4BC3A50859 /* QuickSelectedTestSuiteBuilder.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = QuickSelectedTestSuiteBuilder.swift; path = Sources/Quick/QuickSelectedTestSuiteBuilder.swift; sourceTree = ""; }; F748A8D90936AA999672DB5B2D47B07A /* Expression.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = Expression.swift; path = Sources/Nimble/Expression.swift; sourceTree = ""; }; F76B520EB440AD883F9E762A2520AE65 /* Pods-PersistentStorageSerializable_MacExample-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-PersistentStorageSerializable_MacExample-umbrella.h"; sourceTree = ""; }; F7E8EF54B0B1130FB01D55683CCB70BD /* Pods-PersistentStorageSerializable_iOSExample-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-PersistentStorageSerializable_iOSExample-acknowledgements.plist"; sourceTree = ""; }; F8B180A74BF7DA9BBC0C73181205FB92 /* Metadata+Kind.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = "Metadata+Kind.swift"; path = "Sources/Reflection/Metadata+Kind.swift"; sourceTree = ""; }; F8B44832CF0A8EC7A1EFA01846604B27 /* QuickSpec.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = QuickSpec.h; path = Sources/QuickObjectiveC/QuickSpec.h; sourceTree = ""; }; F8E892409CB344988B711253F95DF9A6 /* PersistentStorageSerializable.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = PersistentStorageSerializable.swift; sourceTree = ""; }; F944D7066C3FBE6346D1BC4CCEFF019B /* XCTestSuite+QuickTestSuiteBuilder.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = "XCTestSuite+QuickTestSuiteBuilder.m"; path = "Sources/QuickObjectiveC/XCTestSuite+QuickTestSuiteBuilder.m"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ 1E587FE14CF0ED99AAD2265A8B9CBEA4 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 75ADBCD6658BE042CBE2EF88470AD142 /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 22F12015985B9E18FDDC014D683C3AE5 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 7B7AB22D0F4F8BE806E6E64EBF69C086 /* Foundation.framework in Frameworks */, 696055C40EA92B1E64AA427B5F279F17 /* XCTest.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 4EB16425BDA91C91D2FADCA18300D987 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 83D71334D516ECEF04E52AF19341CF92 /* Cocoa.framework in Frameworks */, A75A6FB66967A82A2FE709B7DA7D430E /* Foundation.framework in Frameworks */, E03BAAB6CA5552B89F00F4157D7E4552 /* Reflection.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 90F7CC3A876AD76ED38ED1EBC225EA40 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( ADFCB73443130CB466C1EEE6422E3EA1 /* Cocoa.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; 9E1716F5D34F5505736FEB173664D299 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 1E156B80065588ACEE97FF552C24920B /* Foundation.framework in Frameworks */, DF767D1E1FFE54AE90119C25E603B1C0 /* Reflection.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; BFB5F99A63F936C3C47B70F4A922146A /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 36DE34FECFBAA5C66AD16796D49C922C /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; DBE2CE2F5ED086FC1DD44D4B176AEA5B /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( 24EF979DB6A2B88464E07F5C5937EE14 /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; DEECF0B3A5FC43A3CA9BAF0B9547809C /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( D2CB5974414798DD931B35C52E1444FB /* Foundation.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; F782E107EC5038AD4ACDFA75608A6E01 /* Frameworks */ = { isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( BA72C62E612AC2615BFD2215E4E009E5 /* Cocoa.framework in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ 01C8399240B3656FB9FD76C9D6831AAC /* PersistentStorageSerializable */ = { isa = PBXGroup; children = ( 1C8B4BF0792A90B44A334AFF94FB5CEF /* Classes */, ); path = PersistentStorageSerializable; sourceTree = ""; }; 05726D4C8C55E92510638D41B1182E34 /* Nimble */ = { isa = PBXGroup; children = ( 45186F11C51E26728BB50D85C0390181 /* AdapterProtocols.swift */, B0552E74FBD3E66212FFE3E8BE396E8F /* AllPass.swift */, 5E235870D7A5353B927F7EBA6540C98D /* AssertionDispatcher.swift */, 0CF611AC318BFEB347CA578141B6DBB9 /* AssertionRecorder.swift */, A5C9115DBFFBCA4CBC7B5D325CDFA974 /* Async.swift */, AFB88A73C0CB8BEA601FC0FFCAC65E93 /* AsyncMatcherWrapper.swift */, 1917257A77F7B817A10400B4DAF65E20 /* BeAKindOf.swift */, EB94377F385F2D67C9712226280BAFFD /* BeAnInstanceOf.swift */, E5BA4C3F41EC945CFBBFEF98BF01FB49 /* BeCloseTo.swift */, BE30AD879574EA8033F752AC8AE0824B /* BeEmpty.swift */, D2EEA7B45558989FF3AC986804E224B5 /* BeginWith.swift */, DEED2885ABD003AA6FD143802588C6B4 /* BeGreaterThan.swift */, CE13F5C238F2F59965B512E89C0D946B /* BeGreaterThanOrEqualTo.swift */, E540642D5AE67802640578D42DD3C385 /* BeIdenticalTo.swift */, B37769BCBFDCACCA32CB732FFB0DAA20 /* BeLessThan.swift */, 3CB2BCB50D1984E0D33F874869511ACB /* BeLessThanOrEqual.swift */, A2FA10E38A6C6E200ABA275E72DD4023 /* BeLogical.swift */, 7198266CDCBE981765D73B51A366A2EC /* BeNil.swift */, C23CDF8784A07DF2572B6822663C7933 /* BeVoid.swift */, 747AE697137B5D4B95170B071EAE349D /* Contain.swift */, 924D5CF3D65D791C1C28BA3301BD8BB6 /* CurrentTestCaseTracker.h */, 18F76549DC53A24E718801CA74B5AA09 /* CwlBadInstructionException.swift */, 40337972E5B074C5A690D3990DF7905F /* CwlCatchBadInstruction.h */, 469E378328AB74CE2F16E82A53E9FAAA /* CwlCatchBadInstruction.m */, 011E5DDBA8311C08981F7D176417FCC8 /* CwlCatchBadInstruction.swift */, 87B3D180D720E49401F81F66966E6417 /* CwlCatchException.h */, 441B373D2C5A3C7017EED3662A2E5E7C /* CwlCatchException.m */, A073FCA24B91588D8ACB577C9DC91B45 /* CwlCatchException.swift */, D28E7A2DCC4CCB6CE200E402A592FE62 /* CwlDarwinDefinitions.swift */, 38E7ED6F46ED044FD279837053FB0991 /* DSL.h */, 3DB462E985BF4F3D549283CCE0813916 /* DSL.m */, 68E8EB308595205EAFD2911F340CA696 /* DSL.swift */, 578411CA2D094C30D95F87E06ADD724A /* DSL+Wait.swift */, D5D9FE92E1B00D3504D61F30D99D12B4 /* EndWith.swift */, A5F067F59522C866F69B1F02CAD8458D /* Equal.swift */, 9F19211B3AEEEC934B1FE393C5561046 /* Errors.swift */, E7E2F7C919910E3CBA06A9B9D7323E50 /* Expectation.swift */, F748A8D90936AA999672DB5B2D47B07A /* Expression.swift */, 4A3BA563C4ADDE47EE94EB7E7ED106F5 /* FailureMessage.swift */, EC2D23D7A476F61595C9DF0B6A4B1FB1 /* Functional.swift */, 1817B32F3FC7E047D8B9194BC1136606 /* HaveCount.swift */, A8B01A7115AF84CE2793835F62484967 /* mach_excServer.c */, 927DCA96CF6C59B4A98CBD6C063C6DE5 /* mach_excServer.h */, 588E4C9B1904E209FFFE7F7CEC43BAC9 /* Match.swift */, 688F1664230F9D437028E4FE35E2B787 /* MatcherFunc.swift */, C4AD1312A77F4A770BB0CC46BEC8DBA5 /* MatcherProtocols.swift */, 620732F4BDA95B19DBB955D49CA1C5F9 /* MatchError.swift */, A41ACB6A39BC53C1AD5ECDF57143D17F /* Nimble.h */, EB22C6757F9B47F0DFEED8B0996FA956 /* NimbleEnvironment.swift */, 8EA38D47FEF4AFE18A0F512010D99D16 /* NimbleXCTestHandler.swift */, BF2FBABC3914541778F7605748F68659 /* NMBExceptionCapture.h */, CC381077BAF0D5E990F3FA9B68C3D1B9 /* NMBExceptionCapture.m */, F56CFE193CC4072A0438EA2F4E084175 /* NMBExpectation.swift */, 41415B1CBC6148AB3EAE70E253CDF09E /* NMBObjCMatcher.swift */, 0FF2C07CF5BF76578AEAF758FD251ED7 /* NMBStringify.h */, 83845FD26AACEFCEC9B6152D1153AE71 /* NMBStringify.m */, 7535FB188FA658A1D4BE308C7260DFCB /* PostNotification.swift */, 160CAC0E61452631C6449C6AD9B44A76 /* RaisesException.swift */, 4B9854299BC061D75E995BB3C3634F23 /* SatisfyAnyOf.swift */, A5E6BFF347E9847E936924A832FBABBB /* SourceLocation.swift */, 1751B926019ABF625854A4E26839A0CA /* Stringers.swift */, F2426CDF7725EBE8B022AB5940A504C8 /* ThrowAssertion.swift */, 079BB80084E1A015AB255272CDD214F6 /* ThrowError.swift */, 23FB991E1056AD6AEA2355DD1A9F4C9C /* XCTestObservationCenter+Register.m */, C9DC65308111F737200B1E64FCBDA75E /* Support Files */, ); path = Nimble; sourceTree = ""; }; 112B47088E1A093231482A68550F00E8 /* Products */ = { isa = PBXGroup; children = ( 7EA1857941993C28916ABAA7338C2124 /* Nimble.framework */, 574E9F7002EDCC105A916FA3AEC5E703 /* PersistentStorageSerializable.framework */, 549FEBEE27325E9E177BE6D99C52B08C /* PersistentStorageSerializable.framework */, 1D92A2C0B35822F6671F491C09EC6EDB /* Pods_PersistentStorageSerializable_iOSExample.framework */, A0786455757A284E0F80A4F1D4140D38 /* Pods_PersistentStorageSerializable_MacExample.framework */, CA172C3BBC2F641B659ED5C623805BDC /* Pods_PersistentStorageSerializable_Tests.framework */, 2447827F13EA2ED7E904EA15F647F2EA /* Quick.framework */, EAC1A086219F60C7564C880B9CE22833 /* Reflection.framework */, F002B2610679A6F73A8EBDAE1FB8B769 /* Reflection.framework */, ); name = Products; sourceTree = ""; }; 1457A5B98FA989360F0D80579C7F2057 /* Frameworks */ = { isa = PBXGroup; children = ( 6EFD55C435B2B0C8D1D85EC50C34952E /* Reflection.framework */, B76AD05414975C4FA2C7ED1838BB5600 /* iOS */, 3951C868986B062B13881BC87545151B /* OS X */, ); name = Frameworks; sourceTree = ""; }; 1C8B4BF0792A90B44A334AFF94FB5CEF /* Classes */ = { isa = PBXGroup; children = ( E12E2760F92F1A2C4D26629773BE116E /* PersistentStorage.swift */, F8E892409CB344988B711253F95DF9A6 /* PersistentStorageSerializable.swift */, ABEACAEE1E9B6E4D004C1C2F /* SupportedSerializableType.swift */, AB7641571E9798B5007279BE /* PropertiesIteration.swift */, AC46343C8BF32068677D41A1DC13B7EA /* SwiftTryCatch.h */, B17CA6902411F751101E932D315A01A3 /* SwiftTryCatch.m */, 55ECD6A7CA8C0BE3247C517C2BF3CD48 /* UserDefaultsStorage.swift */, AB2E65E51E97DB35009A8531 /* PlistStorage.swift */, ); path = Classes; sourceTree = ""; }; 2AB8D204A1CFF4CBA30176679BBED97E /* Development Pods */ = { isa = PBXGroup; children = ( 68A40BDDB283092F875791156923FBB7 /* PersistentStorageSerializable */, ); name = "Development Pods"; sourceTree = ""; }; 3951C868986B062B13881BC87545151B /* OS X */ = { isa = PBXGroup; children = ( 3D7153B4402DAA3EEF052B341B37773F /* Cocoa.framework */, E91672B06B55CA166C0DBC1160D16897 /* Foundation.framework */, ); name = "OS X"; sourceTree = ""; }; 3C44D2D68BDE305386D95A2CD24F2BF1 /* Quick */ = { isa = PBXGroup; children = ( 0AA4D8CFED2767407ECB264B19B3F94F /* Callsite.swift */, B80B627A14B4E0A37EC0E7A9982A125D /* Closures.swift */, 219C092F09954399C1A31DF8A3206EAB /* Configuration.swift */, 3AA62C473D27598FC7557C82330D047A /* DSL.swift */, AED6C0967624AED98816B8F1161F42BB /* ErrorUtility.swift */, 82A0734EE3DC7F6358E28BF8AE2FDF3E /* Example.swift */, 5F7A1D7D610669DBC95F6145CE72F1E6 /* ExampleGroup.swift */, EF8E3FA49E14F3F1714335FBAADF79B6 /* ExampleHooks.swift */, 00B18873BB378B52DE8BD4C15DD36011 /* ExampleMetadata.swift */, F51A6A4AD26C84606E8A06CEF80604CC /* Filter.swift */, 7CC161CB4301C486CAB9553D7771F325 /* HooksPhase.swift */, 475EE8B724BFCA089214492EB90258F4 /* NSBundle+CurrentTestBundle.swift */, CDF2382E3A3EBF8C4EA56EA63B0450BC /* NSString+QCKSelectorName.h */, 61BCEA4D2FE54567759B6361862E85A5 /* NSString+QCKSelectorName.m */, 3A92C161CC0365639BDA3BF5C09D75B0 /* QCKDSL.h */, 5A0483B4BB0243CC28E72E5FBD8DB68B /* QCKDSL.m */, B8F86A7E42E45B16621FA7D141DDD102 /* Quick.h */, 4AB1B530FD4746C7F1ED45FB4D5A9874 /* QuickConfiguration.h */, CA7ED0ECCD1072B842759099B8A5BB64 /* QuickConfiguration.m */, F6243AD9E6311D7DCEFDEF4BC3A50859 /* QuickSelectedTestSuiteBuilder.swift */, F8B44832CF0A8EC7A1EFA01846604B27 /* QuickSpec.h */, D78F0624BEB297D6125991F8F27CA381 /* QuickSpec.m */, A1EABCA2C5F0C8116ADA4972CD177535 /* QuickTestSuite.swift */, 9C478096F55DAAFB3A4039B64FEFAE98 /* SuiteHooks.swift */, C878728B2C3CFD5993B6822137CE771B /* URL+FileName.swift */, 67B1F98F024249532383E6CED2529B76 /* World.h */, EE9A987E830816D13D423881223CAD20 /* World.swift */, 5E29A6AE6378CC0FFE2CBF7A691DF366 /* World+DSL.h */, 6ADE93DC4F670B429664153334AC498A /* World+DSL.swift */, F944D7066C3FBE6346D1BC4CCEFF019B /* XCTestSuite+QuickTestSuiteBuilder.m */, 4CF216E4372B016FCC3723A0C0FB9A62 /* Support Files */, ); path = Quick; sourceTree = ""; }; 4CF216E4372B016FCC3723A0C0FB9A62 /* Support Files */ = { isa = PBXGroup; children = ( CDFE125ABF7991778EB9DCFEBE1980AD /* Info.plist */, 85D107FD08A65476FFB42BF6F74A3DB2 /* Quick.modulemap */, 89CA505A4090716FCFBB675A171D4137 /* Quick.xcconfig */, E28B0C352E6F01D475C896EB2AC2BF88 /* Quick-dummy.m */, B9C83EAA39CDD9F7107D4D7F499A4D03 /* Quick-prefix.pch */, E196A082C7CA44AB8438286B821016A9 /* Quick-umbrella.h */, ); name = "Support Files"; path = "../Target Support Files/Quick"; sourceTree = ""; }; 5B35EBC88BB4B3C48041E879D7D48865 /* Pods */ = { isa = PBXGroup; children = ( 05726D4C8C55E92510638D41B1182E34 /* Nimble */, 3C44D2D68BDE305386D95A2CD24F2BF1 /* Quick */, C177F8F3FCB64CCB33485690CC670143 /* Reflection */, ); name = Pods; sourceTree = ""; }; 68A40BDDB283092F875791156923FBB7 /* PersistentStorageSerializable */ = { isa = PBXGroup; children = ( 01C8399240B3656FB9FD76C9D6831AAC /* PersistentStorageSerializable */, 981FA3EA82839531F6C0D2580F700D0E /* Support Files */, ); name = PersistentStorageSerializable; path = ../..; sourceTree = ""; }; 7DB346D0F39D3F0E887471402A8071AB = { isa = PBXGroup; children = ( 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */, 2AB8D204A1CFF4CBA30176679BBED97E /* Development Pods */, 1457A5B98FA989360F0D80579C7F2057 /* Frameworks */, 5B35EBC88BB4B3C48041E879D7D48865 /* Pods */, 112B47088E1A093231482A68550F00E8 /* Products */, 95FA4C334EB05550157C56B2CEE9A1F1 /* Targets Support Files */, ); sourceTree = ""; }; 8924E3D4BE7707FB3B2B34CFA1B7D2BE /* Pods-PersistentStorageSerializable_MacExample */ = { isa = PBXGroup; children = ( 45326A29AFE6D19B42FE6CAAAC531328 /* Info.plist */, 9E14E05F296DA5CB818FF86D62211B6C /* Pods-PersistentStorageSerializable_MacExample.modulemap */, 944DE07F663B6872169C028461F2F467 /* Pods-PersistentStorageSerializable_MacExample-acknowledgements.markdown */, 330960B91D30A9CFAE24181F3B16FD69 /* Pods-PersistentStorageSerializable_MacExample-acknowledgements.plist */, D3B7A9361C95282C7B4CDDB9F84197FF /* Pods-PersistentStorageSerializable_MacExample-dummy.m */, CD13BDB1BAB67FC79EF84323384574CE /* Pods-PersistentStorageSerializable_MacExample-frameworks.sh */, E09F71C71226DABFB704EBB455FD474D /* Pods-PersistentStorageSerializable_MacExample-resources.sh */, F76B520EB440AD883F9E762A2520AE65 /* Pods-PersistentStorageSerializable_MacExample-umbrella.h */, 37FEFD4566840955F87EC36E6CFA43F1 /* Pods-PersistentStorageSerializable_MacExample.debug.xcconfig */, B843A390CA2C46325E617109CE7C00B4 /* Pods-PersistentStorageSerializable_MacExample.release.xcconfig */, ); name = "Pods-PersistentStorageSerializable_MacExample"; path = "Target Support Files/Pods-PersistentStorageSerializable_MacExample"; sourceTree = ""; }; 95FA4C334EB05550157C56B2CEE9A1F1 /* Targets Support Files */ = { isa = PBXGroup; children = ( BEB38A81834392A2E7E6883F47BEFF1C /* Pods-PersistentStorageSerializable_iOSExample */, 8924E3D4BE7707FB3B2B34CFA1B7D2BE /* Pods-PersistentStorageSerializable_MacExample */, E6C3EC009DAD7C99819DA47CAE1A8691 /* Pods-PersistentStorageSerializable_Tests */, ); name = "Targets Support Files"; sourceTree = ""; }; 981FA3EA82839531F6C0D2580F700D0E /* Support Files */ = { isa = PBXGroup; children = ( 539A7260F2A2B5AB2DF4494D3EBFD410 /* Info.plist */, 10BF599C02A2F92878A7D882C9611421 /* Info.plist */, 48BE6F62489EFA706F38F78647FD9728 /* PersistentStorageSerializable-iOS.modulemap */, AB379B8B8259CE097D226FB13A1FC648 /* PersistentStorageSerializable-iOS.xcconfig */, 9BA1549C5D1B25AFA3C649C78FA1F854 /* PersistentStorageSerializable-iOS-dummy.m */, 75E42118B71F2B29F7881C63C2B011FB /* PersistentStorageSerializable-iOS-prefix.pch */, A026A2D246B6B842F4B7564B2E87C903 /* PersistentStorageSerializable-iOS-umbrella.h */, 8F942B77C05759400B0802230EA76478 /* PersistentStorageSerializable-OSX.modulemap */, 1AD12082F1076D96DAC1FD9A39D116A7 /* PersistentStorageSerializable-OSX.xcconfig */, BBD89AD9CE542E5D5CA821020724FFBA /* PersistentStorageSerializable-OSX-dummy.m */, F18E3ACFDE1E8E7880CCE9E1210A80AC /* PersistentStorageSerializable-OSX-prefix.pch */, B23DC3D7DA990D4E2939C1BC4496A08A /* PersistentStorageSerializable-OSX-umbrella.h */, ); name = "Support Files"; path = "Example/Pods/Target Support Files/PersistentStorageSerializable-OSX"; sourceTree = ""; }; B76AD05414975C4FA2C7ED1838BB5600 /* iOS */ = { isa = PBXGroup; children = ( A3812E2DC98C94413C4741910FB77160 /* Foundation.framework */, 4AF86E0EEBE4ECA5D93983C10918FE02 /* XCTest.framework */, ); name = iOS; sourceTree = ""; }; BEB38A81834392A2E7E6883F47BEFF1C /* Pods-PersistentStorageSerializable_iOSExample */ = { isa = PBXGroup; children = ( 40D4F0906C3E8D0F7BD6A7B203991625 /* Info.plist */, 6390C415FDF7E2074F9679B0EF4E9DA1 /* Pods-PersistentStorageSerializable_iOSExample.modulemap */, 1E991206BBAD4F0FA3A741A59A57E783 /* Pods-PersistentStorageSerializable_iOSExample-acknowledgements.markdown */, F7E8EF54B0B1130FB01D55683CCB70BD /* Pods-PersistentStorageSerializable_iOSExample-acknowledgements.plist */, C94794649537F0066EB7D122F0E30D60 /* Pods-PersistentStorageSerializable_iOSExample-dummy.m */, 3075226313FF83346C5B4B26AFC5D7C7 /* Pods-PersistentStorageSerializable_iOSExample-frameworks.sh */, 09F16AFC755B1E7DA916EB123B4B433C /* Pods-PersistentStorageSerializable_iOSExample-resources.sh */, BC62F6B906201B92A5E117B29415D918 /* Pods-PersistentStorageSerializable_iOSExample-umbrella.h */, A4B56A6EED0B50275C67F754263391DA /* Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig */, 272AA0D36A2B77FCF978B083C7D8673C /* Pods-PersistentStorageSerializable_iOSExample.release.xcconfig */, ); name = "Pods-PersistentStorageSerializable_iOSExample"; path = "Target Support Files/Pods-PersistentStorageSerializable_iOSExample"; sourceTree = ""; }; C10B9F96B8EA91B32F2573AD1849405A /* Support Files */ = { isa = PBXGroup; children = ( 236C27708A8A6A5A6183983A059511E4 /* Info.plist */, 8383C2DB5F3EB2FE3DFB4992A399343B /* Info.plist */, 18785D0D7962AC70BC0DDD2600F7CAA9 /* Reflection-iOS.modulemap */, 66EA1514CB8DCAB8B490F192914CCE88 /* Reflection-iOS.xcconfig */, 13BD39469AED51D519EF9058AC78DB5B /* Reflection-iOS-dummy.m */, 8564F055BF244AF3234A9A5931029A54 /* Reflection-iOS-prefix.pch */, 01EC2AA7495F252C13BD7234C74E79F3 /* Reflection-iOS-umbrella.h */, 82BB205A9D6D44244AAAF4109F30BBAC /* Reflection-OSX.modulemap */, 449695496334292237F7ABF92C612C79 /* Reflection-OSX.xcconfig */, C7BF7B887150EFCDEFB19473A8CCFB25 /* Reflection-OSX-dummy.m */, 4FFE5B7B0ECD5BFF9BF32C39E01BF3CF /* Reflection-OSX-prefix.pch */, 88A0A2C900F1B0DA95C4E099D8EF69DE /* Reflection-OSX-umbrella.h */, ); name = "Support Files"; path = "../Target Support Files/Reflection-OSX"; sourceTree = ""; }; C177F8F3FCB64CCB33485690CC670143 /* Reflection */ = { isa = PBXGroup; children = ( 559C95F20B29BE7F707CA733C7738B29 /* Advance.swift */, AD76B886530DC003364EE0F566036318 /* Any+Extensions.swift */, 9578A4E1FCE35AB00735C22CFC7162C2 /* Array+Extensions.swift */, 80C39B59F6205A8B8AF381514259A66D /* Construct.swift */, F15DABBF3A935A0689C332EA250AD0DE /* Get.swift */, 409470BF79C61A1DC5EE998F14636B1D /* Identity.swift */, 35699FC5A45F8604D9E53D74B994634E /* MemoryProperties.swift */, 22089DBC28F5B811B25675FBD14A464C /* Metadata.swift */, 47982F2D4AB9B4C4719DA6F8802FC275 /* Metadata+Class.swift */, F8B180A74BF7DA9BBC0C73181205FB92 /* Metadata+Kind.swift */, 08F6FE8EEAA8D621FB74B7B387C39435 /* Metadata+Struct.swift */, 3D6D4970F760DF36BCCBDE630066C7B2 /* Metadata+Tuple.swift */, 0FBD8197371FDDD1F56733D5344DA39C /* MetadataType.swift */, AC711F896F1F753CD40D0336E1891051 /* NominalType.swift */, DD2E21D6BE5962664A0A86D50A5F27FF /* NominalTypeDescriptor.swift */, CA30706E8884E8F1B0E6CD2EA1B84275 /* PointerType.swift */, BE3AC896DCF9F346EDE03FFD0488C493 /* Properties.swift */, 972E1E97A8BE5406BCB6970C92C39D67 /* ReflectionError.swift */, 0A7F4F011E3296C5BDBCDA0E0662448F /* RelativePointer.swift */, 96F31DEAF8546F97D13B6631A0613D6C /* Set.swift */, 217580B44B73532ED783A1267CCDB3FA /* Storage.swift */, 4F08D19A4E34CF4C3804349437273B90 /* UnsafePointer+Extensions.swift */, 297F08DEBA780355103E1943E91C9863 /* ValueWitnessTable.swift */, C10B9F96B8EA91B32F2573AD1849405A /* Support Files */, ); path = Reflection; sourceTree = ""; }; C9DC65308111F737200B1E64FCBDA75E /* Support Files */ = { isa = PBXGroup; children = ( 8F48EBA91CB748656BB261C2366EF4A5 /* Info.plist */, 9D8169968C7213ADA57D2C051D306C17 /* Nimble.modulemap */, 09C1992E68D8FC0C0241FC40D3899B5D /* Nimble.xcconfig */, 4FA2C3F5E0A780BE8ACBF263F1144522 /* Nimble-dummy.m */, D3F8840B178F3FF2FC53CE285B77F87E /* Nimble-prefix.pch */, 6BA9BDC9D1D74EFFEE8DC76C6DE0B7C7 /* Nimble-umbrella.h */, ); name = "Support Files"; path = "../Target Support Files/Nimble"; sourceTree = ""; }; E6C3EC009DAD7C99819DA47CAE1A8691 /* Pods-PersistentStorageSerializable_Tests */ = { isa = PBXGroup; children = ( 6DDCF5299547FB5521D650CE6A57F2AF /* Info.plist */, 213549B893FEA076CD035251ADFE9845 /* Pods-PersistentStorageSerializable_Tests.modulemap */, 8D9D52F249D62845DF022590C42147CD /* Pods-PersistentStorageSerializable_Tests-acknowledgements.markdown */, C9633F84E2EEA318823E16E16FA3E7CE /* Pods-PersistentStorageSerializable_Tests-acknowledgements.plist */, A18E35F09E61F21D2E34681DE3CAB1BB /* Pods-PersistentStorageSerializable_Tests-dummy.m */, 3F6AF0730A8A933938DC9F34A8A068E2 /* Pods-PersistentStorageSerializable_Tests-frameworks.sh */, C00223D84C0D987C5C44B6E450DCB8F3 /* Pods-PersistentStorageSerializable_Tests-resources.sh */, 5CB4072DCEF8D77880842C53D041AB97 /* Pods-PersistentStorageSerializable_Tests-umbrella.h */, B4F57D336E8CD0C8E07BF34E6FBCF86E /* Pods-PersistentStorageSerializable_Tests.debug.xcconfig */, DDAB3E7FAA610141534F47F426392A3D /* Pods-PersistentStorageSerializable_Tests.release.xcconfig */, ); name = "Pods-PersistentStorageSerializable_Tests"; path = "Target Support Files/Pods-PersistentStorageSerializable_Tests"; sourceTree = ""; }; /* End PBXGroup section */ /* Begin PBXHeadersBuildPhase section */ 11B44C47B51351542DE8194E76DE3001 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( 58BBAA735E0564DC10B759A045722D28 /* Pods-PersistentStorageSerializable_MacExample-umbrella.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; 1F799EC06F84DF4380CC7E2CDAA3FD23 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( C60420491851A44ADA0989C09A0A00A8 /* PersistentStorageSerializable-iOS-umbrella.h in Headers */, 5EAF1AE63153220FC957F99817820067 /* SwiftTryCatch.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; 2ACF6192E10A038A21EFA2156C9F7EA3 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( F693D0A9E0D05F815A85DC258E75AF8D /* CurrentTestCaseTracker.h in Headers */, 65F5217D44A557FC16218DE5DE348C35 /* CwlCatchBadInstruction.h in Headers */, 87DD62F200DAB5E1D701AB9F94D1D422 /* CwlCatchException.h in Headers */, 0ECEEBC712D404AA6CF1E76A9284BFF9 /* DSL.h in Headers */, B093484B1637B3D3AF65DF2232FDBADC /* mach_excServer.h in Headers */, 76036D32625A56D480D84AA46961EF91 /* Nimble-umbrella.h in Headers */, 469E9C3ED9FD6009F7C9AAF9E537E212 /* Nimble.h in Headers */, 917949F596E1188261FC59214782C3D9 /* NMBExceptionCapture.h in Headers */, 27B262F95D3CF9E3C74541A41929691C /* NMBStringify.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; 524B83A6C825BAF4C274F39ED56AF5D2 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( AD5162BE3EE92A4A3197423D7040F0C5 /* NSString+QCKSelectorName.h in Headers */, 27C8D0B5BDCE5D2598D72B26804C5C02 /* QCKDSL.h in Headers */, 5F0656C57F3790BFAECDEE9DD19FF9F8 /* Quick-umbrella.h in Headers */, E522A8C892DC6E5CAEDC20148D704EF8 /* Quick.h in Headers */, 4C672CABC57F27FD257A00D44A41AA2C /* QuickConfiguration.h in Headers */, 5DD5045E9FD98BA38FD09BC13331DB22 /* QuickSpec.h in Headers */, 020B66398FFAE7EF8DC82BCFBC847B74 /* World+DSL.h in Headers */, A21134677479F6C55B6E5481D7AAA043 /* World.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; 5DFEFB77A67C0940F7B1A1EAF79990D6 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( 465F487084A675DF1D8FF41AB942A461 /* Pods-PersistentStorageSerializable_iOSExample-umbrella.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; 68E3FF3CE12E064A8B29BCFC9CB491C9 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( 053B74B0FCB3178D1ED0607D0F972A71 /* Reflection-iOS-umbrella.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; 72EFED2E87FDF59D892804C047C3A726 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( 079AB49FD0F4774D822A66A51327DA53 /* PersistentStorageSerializable-OSX-umbrella.h in Headers */, F20E741BBC41327AED358EB0E719D1CF /* SwiftTryCatch.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; E174AD545CC1F7849FE91FC22FB76448 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( 4EB98E304582EC3C0213C88146DE42F9 /* Reflection-OSX-umbrella.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; F3731B6966525ECA9A58DD15F878ED79 /* Headers */ = { isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( AFBB8B76ECE814775A6EC638AB37A43F /* Pods-PersistentStorageSerializable_Tests-umbrella.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXHeadersBuildPhase section */ /* Begin PBXNativeTarget section */ 0549E4E6F5102AC529E6B71AC4B98B73 /* Pods-PersistentStorageSerializable_MacExample */ = { isa = PBXNativeTarget; buildConfigurationList = D92D3AFFD976E7382A2EC7E51CCBA37C /* Build configuration list for PBXNativeTarget "Pods-PersistentStorageSerializable_MacExample" */; buildPhases = ( B0032F9879AAFB0171B9D84AB5320096 /* Sources */, 90F7CC3A876AD76ED38ED1EBC225EA40 /* Frameworks */, 11B44C47B51351542DE8194E76DE3001 /* Headers */, ); buildRules = ( ); dependencies = ( BD475F43DE62EFCA9655DB3CEE4B0892 /* PBXTargetDependency */, BAA858ED93A0AC61EAC4D3E4DF4753A9 /* PBXTargetDependency */, ); name = "Pods-PersistentStorageSerializable_MacExample"; productName = "Pods-PersistentStorageSerializable_MacExample"; productReference = A0786455757A284E0F80A4F1D4140D38 /* Pods_PersistentStorageSerializable_MacExample.framework */; productType = "com.apple.product-type.framework"; }; 1321E318D10CFDC9F5B93A7952492CCD /* Nimble */ = { isa = PBXNativeTarget; buildConfigurationList = B1DBAFB75A3AF98C8C6B0863BDC7A2E3 /* Build configuration list for PBXNativeTarget "Nimble" */; buildPhases = ( 3C4AABA28564F6F29FE8E3F38226690A /* Sources */, DBE2CE2F5ED086FC1DD44D4B176AEA5B /* Frameworks */, 2ACF6192E10A038A21EFA2156C9F7EA3 /* Headers */, ); buildRules = ( ); dependencies = ( ); name = Nimble; productName = Nimble; productReference = 7EA1857941993C28916ABAA7338C2124 /* Nimble.framework */; productType = "com.apple.product-type.framework"; }; 4F6E643E2F6C9A118A094117CCF0AD33 /* Pods-PersistentStorageSerializable_Tests */ = { isa = PBXNativeTarget; buildConfigurationList = E224EA756B2648B2E5AB2028E714FD79 /* Build configuration list for PBXNativeTarget "Pods-PersistentStorageSerializable_Tests" */; buildPhases = ( 83DDA1DDF8A5C0DD2B9457C6A6797E0F /* Sources */, 1E587FE14CF0ED99AAD2265A8B9CBEA4 /* Frameworks */, F3731B6966525ECA9A58DD15F878ED79 /* Headers */, ); buildRules = ( ); dependencies = ( A423C4C7B0ED8254F9B7640584BB8DDE /* PBXTargetDependency */, 41A8A32402B47D152FCBECD8CDC1284B /* PBXTargetDependency */, 19808F654D7BD88967CF0E2657A11A8B /* PBXTargetDependency */, FA8AB738B2E50CEB9120D41F5442D7B4 /* PBXTargetDependency */, ); name = "Pods-PersistentStorageSerializable_Tests"; productName = "Pods-PersistentStorageSerializable_Tests"; productReference = CA172C3BBC2F641B659ED5C623805BDC /* Pods_PersistentStorageSerializable_Tests.framework */; productType = "com.apple.product-type.framework"; }; 78DD5EB06C96485107D83E0183C84D70 /* Quick */ = { isa = PBXNativeTarget; buildConfigurationList = 323621E0B680E87AA6892CEE3C97081D /* Build configuration list for PBXNativeTarget "Quick" */; buildPhases = ( E769480009C52559A3A3C28FF42D5C57 /* Sources */, 22F12015985B9E18FDDC014D683C3AE5 /* Frameworks */, 524B83A6C825BAF4C274F39ED56AF5D2 /* Headers */, ); buildRules = ( ); dependencies = ( ); name = Quick; productName = Quick; productReference = 2447827F13EA2ED7E904EA15F647F2EA /* Quick.framework */; productType = "com.apple.product-type.framework"; }; 810EE9CC72099DB8CE653C742754EC04 /* PersistentStorageSerializable-iOS */ = { isa = PBXNativeTarget; buildConfigurationList = 83E8B094BB06F88FAA1D579ECE15F50A /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable-iOS" */; buildPhases = ( D57185FD8D82A912CD38F74EDDEBB42C /* Sources */, 9E1716F5D34F5505736FEB173664D299 /* Frameworks */, 1F799EC06F84DF4380CC7E2CDAA3FD23 /* Headers */, ); buildRules = ( ); dependencies = ( F98C13D6D032C95C1913D4AFE48511C3 /* PBXTargetDependency */, ); name = "PersistentStorageSerializable-iOS"; productName = "PersistentStorageSerializable-iOS"; productReference = 549FEBEE27325E9E177BE6D99C52B08C /* PersistentStorageSerializable.framework */; productType = "com.apple.product-type.framework"; }; 8302DFE25125E545B660DD41FB4DAD67 /* Reflection-OSX */ = { isa = PBXNativeTarget; buildConfigurationList = E9E41A62CDC5D28F3772CFCB3460DFD4 /* Build configuration list for PBXNativeTarget "Reflection-OSX" */; buildPhases = ( 13F0DCB671A23F38A260DDBD69DFE48D /* Sources */, F782E107EC5038AD4ACDFA75608A6E01 /* Frameworks */, E174AD545CC1F7849FE91FC22FB76448 /* Headers */, ); buildRules = ( ); dependencies = ( ); name = "Reflection-OSX"; productName = "Reflection-OSX"; productReference = F002B2610679A6F73A8EBDAE1FB8B769 /* Reflection.framework */; productType = "com.apple.product-type.framework"; }; B29FB212BE53D249CF080AF2FC6B42D5 /* PersistentStorageSerializable-OSX */ = { isa = PBXNativeTarget; buildConfigurationList = 0FF05E191588DF44EB64DDDBD0AECCD0 /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable-OSX" */; buildPhases = ( 6D7B2BF7B2084078EF820BD25BA245A6 /* Sources */, 4EB16425BDA91C91D2FADCA18300D987 /* Frameworks */, 72EFED2E87FDF59D892804C047C3A726 /* Headers */, ); buildRules = ( ); dependencies = ( 55F35D5044C2CC3CA3D74CF48AD3C182 /* PBXTargetDependency */, ); name = "PersistentStorageSerializable-OSX"; productName = "PersistentStorageSerializable-OSX"; productReference = 574E9F7002EDCC105A916FA3AEC5E703 /* PersistentStorageSerializable.framework */; productType = "com.apple.product-type.framework"; }; F0CEC1F3C61AFCB9ADA5919C64B003CE /* Reflection-iOS */ = { isa = PBXNativeTarget; buildConfigurationList = 6CDCABBEB0265ED19E8A8CF567DACD69 /* Build configuration list for PBXNativeTarget "Reflection-iOS" */; buildPhases = ( 606CB0654DDA73D64979D232B0532D64 /* Sources */, BFB5F99A63F936C3C47B70F4A922146A /* Frameworks */, 68E3FF3CE12E064A8B29BCFC9CB491C9 /* Headers */, ); buildRules = ( ); dependencies = ( ); name = "Reflection-iOS"; productName = "Reflection-iOS"; productReference = EAC1A086219F60C7564C880B9CE22833 /* Reflection.framework */; productType = "com.apple.product-type.framework"; }; F2951F9CAE6AB0A0B459024AA4D646B1 /* Pods-PersistentStorageSerializable_iOSExample */ = { isa = PBXNativeTarget; buildConfigurationList = 2FAF241D791923DB8E7AE90EDE7027C3 /* Build configuration list for PBXNativeTarget "Pods-PersistentStorageSerializable_iOSExample" */; buildPhases = ( 32C3F4C43D291B781BEAFB87562EC2E5 /* Sources */, DEECF0B3A5FC43A3CA9BAF0B9547809C /* Frameworks */, 5DFEFB77A67C0940F7B1A1EAF79990D6 /* Headers */, ); buildRules = ( ); dependencies = ( FF9952B7AE33F3727AC1E9BAC6F1B3FE /* PBXTargetDependency */, C4FF8625191A1F15A28302281CEEE0EC /* PBXTargetDependency */, ); name = "Pods-PersistentStorageSerializable_iOSExample"; productName = "Pods-PersistentStorageSerializable_iOSExample"; productReference = 1D92A2C0B35822F6671F491C09EC6EDB /* Pods_PersistentStorageSerializable_iOSExample.framework */; productType = "com.apple.product-type.framework"; }; /* End PBXNativeTarget section */ /* Begin PBXProject section */ D41D8CD98F00B204E9800998ECF8427E /* Project object */ = { isa = PBXProject; attributes = { LastSwiftUpdateCheck = 0730; LastUpgradeCheck = 0700; }; buildConfigurationList = 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */; compatibilityVersion = "Xcode 3.2"; developmentRegion = English; hasScannedForEncodings = 0; knownRegions = ( en, ); mainGroup = 7DB346D0F39D3F0E887471402A8071AB; productRefGroup = 112B47088E1A093231482A68550F00E8 /* Products */; projectDirPath = ""; projectRoot = ""; targets = ( 1321E318D10CFDC9F5B93A7952492CCD /* Nimble */, 810EE9CC72099DB8CE653C742754EC04 /* PersistentStorageSerializable-iOS */, B29FB212BE53D249CF080AF2FC6B42D5 /* PersistentStorageSerializable-OSX */, F2951F9CAE6AB0A0B459024AA4D646B1 /* Pods-PersistentStorageSerializable_iOSExample */, 0549E4E6F5102AC529E6B71AC4B98B73 /* Pods-PersistentStorageSerializable_MacExample */, 4F6E643E2F6C9A118A094117CCF0AD33 /* Pods-PersistentStorageSerializable_Tests */, 78DD5EB06C96485107D83E0183C84D70 /* Quick */, F0CEC1F3C61AFCB9ADA5919C64B003CE /* Reflection-iOS */, 8302DFE25125E545B660DD41FB4DAD67 /* Reflection-OSX */, ); }; /* End PBXProject section */ /* Begin PBXSourcesBuildPhase section */ 13F0DCB671A23F38A260DDBD69DFE48D /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 6302DC24446FB6D1D3F28C7A91074E6C /* Advance.swift in Sources */, EFCF71BE7182C23F3517B99A90EF647E /* Any+Extensions.swift in Sources */, ADAFA23A712E649A250F51E1E4A3B9A6 /* Array+Extensions.swift in Sources */, 8DFD3ED6E1F4FC0D540E0FE53C8D67D8 /* Construct.swift in Sources */, F68273DF598C7366016B4942A61059B8 /* Get.swift in Sources */, EEB1AB6DD725CC3E48EC1A253B8365A0 /* Identity.swift in Sources */, 84096C1960B46419BEAA85A22B353DB2 /* MemoryProperties.swift in Sources */, CD6CC09B21B2BCBAA4F16A8613806246 /* Metadata+Class.swift in Sources */, 1126C787C127CB914614414DC0AB6B47 /* Metadata+Kind.swift in Sources */, B7C651D3CB5879217669C82B3897B0E4 /* Metadata+Struct.swift in Sources */, 1B17B3C06FE5ADDFB860494D7695A3A2 /* Metadata+Tuple.swift in Sources */, 2BEA3608F762A2FE5015B1E18DFCD271 /* Metadata.swift in Sources */, 698B22A2197B6B1C3FBD6152F580A56E /* MetadataType.swift in Sources */, 2568862D51DC7E7E605FEA67B3C2B2DF /* NominalType.swift in Sources */, 9F08882A4973621F4AF68EB72EDF6239 /* NominalTypeDescriptor.swift in Sources */, DD70CBB5FBFE8E2BE8F6D2E2C7754A44 /* PointerType.swift in Sources */, ADB23C0587582C77280651FABBBB20E7 /* Properties.swift in Sources */, CEB1E434D27275AD2A65C817A838EF97 /* Reflection-OSX-dummy.m in Sources */, BA09DEE84D61AFCD97C518D61A3D3A96 /* ReflectionError.swift in Sources */, 60986639F7C83D8C8120F0C56EACB273 /* RelativePointer.swift in Sources */, 71591AC90458BECCD88F503B98B7E307 /* Set.swift in Sources */, 8154A9D75CE273A5CA11AD734F8DD0AF /* Storage.swift in Sources */, F5B288321A3A12AB215FCEFAC0208522 /* UnsafePointer+Extensions.swift in Sources */, 0F98B9251F2C3EE6F7E51AEC683860F7 /* ValueWitnessTable.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 32C3F4C43D291B781BEAFB87562EC2E5 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( E1A93DCEC817DE5770524BF75E840E08 /* Pods-PersistentStorageSerializable_iOSExample-dummy.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 3C4AABA28564F6F29FE8E3F38226690A /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 047A68C646E00EB6D7D4D7343B801D09 /* AdapterProtocols.swift in Sources */, DCEE854E62441E78FED15CC994497F61 /* AllPass.swift in Sources */, 74FD712F3B503891B6BD9E5CD287E481 /* AssertionDispatcher.swift in Sources */, F9E05A63D447B51E008B89731192FE7F /* AssertionRecorder.swift in Sources */, AC29CC89E22273BF0D0DC2C841B7524C /* Async.swift in Sources */, 551440A0F92574039C1D2EB39227D6B8 /* AsyncMatcherWrapper.swift in Sources */, F60D221B548716DF35193FC2CF244676 /* BeAKindOf.swift in Sources */, A448F837592E21D9387322E8DA0DD93F /* BeAnInstanceOf.swift in Sources */, 9544A4EEC2A8448743ECA9981F88B60F /* BeCloseTo.swift in Sources */, 9AF235C16362BA00BFBF12147907E953 /* BeEmpty.swift in Sources */, AB255C27EF10E742C6567775022F49D5 /* BeginWith.swift in Sources */, 07722FBCF6B380961B9D2832D5883F45 /* BeGreaterThan.swift in Sources */, 1C50F54510D5C2B2AD84D7B74A6EDEBB /* BeGreaterThanOrEqualTo.swift in Sources */, A33F1754198E8E8CCC7087F6176FFDC8 /* BeIdenticalTo.swift in Sources */, 6E397D9FB11A47E48D70287D734B12B2 /* BeLessThan.swift in Sources */, FAB4ECE0C5039D99BB7173880670871D /* BeLessThanOrEqual.swift in Sources */, 0AEC20AACF9B10846830274E3B2AA6FD /* BeLogical.swift in Sources */, 599669823A2EED2928C77F301F6B0515 /* BeNil.swift in Sources */, 78F3DE174B4F8D368EF8EEFD7EE62087 /* BeVoid.swift in Sources */, 8507F4BF7437EB40A3626EDCC68BFF6D /* Contain.swift in Sources */, 737E19F3254F5929263982C29237C0BA /* CwlBadInstructionException.swift in Sources */, 3915DBB4731CB17B255A7FE86E240B6E /* CwlCatchBadInstruction.m in Sources */, 6CDBA48C3A8621E4EE1DAFFE240F0D82 /* CwlCatchBadInstruction.swift in Sources */, 947162383483B6391F8CDF38249BFBD2 /* CwlCatchException.m in Sources */, F4A1B7A059AAA6727EB70E58E09332A4 /* CwlCatchException.swift in Sources */, BB10A2D0B1EE5B1BA811354116F83E3F /* CwlDarwinDefinitions.swift in Sources */, 86FFB76B2EDCF4AE79CC4C0BD8A0FE9A /* DSL+Wait.swift in Sources */, 1C7CA1FAFBF8B865596C739FEA39CDEE /* DSL.m in Sources */, 17261E344C2027602431A636759AC7F2 /* DSL.swift in Sources */, 8654571F855691C23B7B8E61B2141944 /* EndWith.swift in Sources */, BF3AF1D2B46E09E2B3DCC824E6C1F5AF /* Equal.swift in Sources */, 7F6750C7B1847733370B18C4CBFE32DF /* Errors.swift in Sources */, CB7558CCDD935C9E82BBF454022ED1D3 /* Expectation.swift in Sources */, 8015239010C1D642F14C105F8FF8E035 /* Expression.swift in Sources */, 7D6269A3CFE53C28DAA6B92E8FC017A7 /* FailureMessage.swift in Sources */, FCFFEB587281358CFF05A65ED9E94C12 /* Functional.swift in Sources */, CE3FA6AE0944D4AE737F0E57CFF4A615 /* HaveCount.swift in Sources */, 50B80F12A9BAE302F07F6CF94752F462 /* mach_excServer.c in Sources */, A91166D0A5E8F1D5D5377622C381C045 /* Match.swift in Sources */, B9BD565DAB07F8E2288A960A1D3EFAC1 /* MatcherFunc.swift in Sources */, 23E2E1E02FE79EE1E1688CBBAA777297 /* MatcherProtocols.swift in Sources */, CE4CEF6328E255B380E2B2692B351CF8 /* MatchError.swift in Sources */, 9E95D6E15DBE9B0FC92AAF60D42D1464 /* Nimble-dummy.m in Sources */, F9D61EB5EEB799105913685722FF4C9C /* NimbleEnvironment.swift in Sources */, E5CCEF0B83F8272D10671C01AAE4FFA0 /* NimbleXCTestHandler.swift in Sources */, DC32331BE565888E694E1321BB1D80F5 /* NMBExceptionCapture.m in Sources */, 8C30EAD5FFD28B387099B41C74657A67 /* NMBExpectation.swift in Sources */, AC0B24EF198E3BEDFCC9F25D7B8EEDAB /* NMBObjCMatcher.swift in Sources */, 127CD37052B8E0BC645D83D4664F59D4 /* NMBStringify.m in Sources */, EBA52C16F42E42A1824D87C284F4A60C /* PostNotification.swift in Sources */, 4F3F103945CC52D0A3B8A891BB0E21C4 /* RaisesException.swift in Sources */, 62744EF299751FB49B5FCD81D8C8FFF7 /* SatisfyAnyOf.swift in Sources */, 234BFC45ACAC4A8FB945EA17B6A74B0B /* SourceLocation.swift in Sources */, 9BEBD1791C233763A8DC13080BFB99C9 /* Stringers.swift in Sources */, 110A640A9BE45841BA938B4C29EF5446 /* ThrowAssertion.swift in Sources */, 22C1DE74D494C10BBE727F239A68447D /* ThrowError.swift in Sources */, D88575ED37BC462E8130CDBEFE9EA308 /* XCTestObservationCenter+Register.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 606CB0654DDA73D64979D232B0532D64 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( DB5B42776D188C8BA01E7F214CE2B2E5 /* Advance.swift in Sources */, 6CA40832F248BADDAEAD9799D25E8327 /* Any+Extensions.swift in Sources */, 0B95B4873A60B312637F64D29989704F /* Array+Extensions.swift in Sources */, AD6BACF97D192AE3BC9AA98DBB6B0C8F /* Construct.swift in Sources */, E7B341CCA626B55029DA67A8F4D8E78B /* Get.swift in Sources */, 052E642802CDFAE58E5015973CC29989 /* Identity.swift in Sources */, 0553835581ED0E2219057AAAF8EDACB7 /* MemoryProperties.swift in Sources */, FB0EEC25C35082E1C2E0BE2EFFF36EF8 /* Metadata+Class.swift in Sources */, A044BA198D7D7B695111CC1D2D72D8CB /* Metadata+Kind.swift in Sources */, C75B4E3F0052DF9F138A20EE54C52E87 /* Metadata+Struct.swift in Sources */, 96DAA4B406FA5410F4D3474B8EDB890C /* Metadata+Tuple.swift in Sources */, BF232BD5ED6C85D9397D2F54335AC84F /* Metadata.swift in Sources */, 502697EEDEB856CB927D86CEFFEFD81F /* MetadataType.swift in Sources */, 1132968D8FD56FC339BE397D93F30182 /* NominalType.swift in Sources */, B2231C0FB5071D40FDDCE3461FDB8F98 /* NominalTypeDescriptor.swift in Sources */, D3B626F2AC4E553461FA5875C298D41B /* PointerType.swift in Sources */, 6151084EDA799E77F35D31B123AA4FC4 /* Properties.swift in Sources */, 1FACBA5B035E21841BFC908DF2F8DE60 /* Reflection-iOS-dummy.m in Sources */, 1FEFF9515601DF2AD8B7AA51F78D84CD /* ReflectionError.swift in Sources */, 01297E76B8F59B57CA207191681F7B5B /* RelativePointer.swift in Sources */, C9510EA7D95C129CD044F451413547A6 /* Set.swift in Sources */, 5B863E4F94C0031EAA2395D95EEB6971 /* Storage.swift in Sources */, ABD62B3892A67B671316A6D145AF6761 /* UnsafePointer+Extensions.swift in Sources */, 32D21EE104D5522D22A63814A3014CE2 /* ValueWitnessTable.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 6D7B2BF7B2084078EF820BD25BA245A6 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 0595F8F053D261E51EE0A53C8B27A343 /* PersistentStorage.swift in Sources */, C0A7EED80F769F12D2BD3846B7DF137C /* PersistentStorageSerializable-OSX-dummy.m in Sources */, 8431C26BBC7EAB8C47681E2B96AB93B5 /* PersistentStorageSerializable.swift in Sources */, AB7641591E9798B5007279BE /* PropertiesIteration.swift in Sources */, D1F0D71DC0ED03185D640B1D3EEA3150 /* SwiftTryCatch.m in Sources */, AB2E65E71E97DB35009A8531 /* PlistStorage.swift in Sources */, 970E9F902FFC919D23F51D8861E05EBC /* UserDefaultsStorage.swift in Sources */, ABEACAF01E9B6E4D004C1C2F /* SupportedSerializableType.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; 83DDA1DDF8A5C0DD2B9457C6A6797E0F /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( D4DD435BD76E710101BBACFBDA5539EE /* Pods-PersistentStorageSerializable_Tests-dummy.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; B0032F9879AAFB0171B9D84AB5320096 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 5B15ED51D2DDC01FCECB0A6085564A83 /* Pods-PersistentStorageSerializable_MacExample-dummy.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; D57185FD8D82A912CD38F74EDDEBB42C /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( 58FAC51B72C06FEC4A6C73A97477B0A9 /* PersistentStorage.swift in Sources */, 10FB7310EAD5D4DA82EC2E3A01673CE1 /* PersistentStorageSerializable-iOS-dummy.m in Sources */, 0447EAC87AD27FB27515B70F15F4837C /* PersistentStorageSerializable.swift in Sources */, AB7641581E9798B5007279BE /* PropertiesIteration.swift in Sources */, 88D2CD8353F07F320B24053F75B0AA8A /* SwiftTryCatch.m in Sources */, AB2E65E61E97DB35009A8531 /* PlistStorage.swift in Sources */, E0534D41B876E82FD0472460B8D51179 /* UserDefaultsStorage.swift in Sources */, ABEACAEF1E9B6E4D004C1C2F /* SupportedSerializableType.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; E769480009C52559A3A3C28FF42D5C57 /* Sources */ = { isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( B6E3B1A8C83A31066CF8ED1A341AA5AA /* Callsite.swift in Sources */, C1DD2D7CE982C0064A8448E4E661098E /* Closures.swift in Sources */, 9C547F2004309855E778AE6D60A10291 /* Configuration.swift in Sources */, 43DCD3F2C3E435EAD0B167ACD20CE1CE /* DSL.swift in Sources */, E8B55982DC570A58CFCE688C476FD5F6 /* ErrorUtility.swift in Sources */, AB2BA417AEEFD18FE0F73F80C97987CC /* Example.swift in Sources */, 07731CF449EB16282C6A18D2739B0814 /* ExampleGroup.swift in Sources */, 7D2A4146047606E0D021403D9D2CA45A /* ExampleHooks.swift in Sources */, 3600CF9CB81FDA40631664F18C987565 /* ExampleMetadata.swift in Sources */, AC5137B44BDB6C4C38C6450791C1BAF4 /* Filter.swift in Sources */, 492FCC6E224A949B9883FA7F4568B0C3 /* HooksPhase.swift in Sources */, D9D0C0BB64E7C80001F92BE20AEDD20C /* NSBundle+CurrentTestBundle.swift in Sources */, C331C441134E33E71ED4C596B95C10EA /* NSString+QCKSelectorName.m in Sources */, FDD34D9019B0A1A2BD782EDF6F91DFBC /* QCKDSL.m in Sources */, B12039684B5C118037A233D091B8E832 /* Quick-dummy.m in Sources */, 9E605272EAFAAD942D11080DBE9CA985 /* QuickConfiguration.m in Sources */, B894AA08164D83B7428202D518B328CC /* QuickSelectedTestSuiteBuilder.swift in Sources */, C059821F074270276AE2F165C8A2FA05 /* QuickSpec.m in Sources */, BAEFDCBE1577A385DBE693446B7A43E4 /* QuickTestSuite.swift in Sources */, 810870C32C831856AA9056F4FBEC1512 /* SuiteHooks.swift in Sources */, 96E14093C91E8E1DB68029173EB8D45C /* URL+FileName.swift in Sources */, 18B7E2BF4A724A3632E02E0AA3918844 /* World+DSL.swift in Sources */, 514986E42D0AB20608C3841E710357D2 /* World.swift in Sources */, 4C9F41FE904E314F55D857A80457CADC /* XCTestSuite+QuickTestSuiteBuilder.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXSourcesBuildPhase section */ /* Begin PBXTargetDependency section */ 19808F654D7BD88967CF0E2657A11A8B /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = Quick; target = 78DD5EB06C96485107D83E0183C84D70 /* Quick */; targetProxy = 893F510CFF86D0DAA159249D0A0A391D /* PBXContainerItemProxy */; }; 41A8A32402B47D152FCBECD8CDC1284B /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "PersistentStorageSerializable-iOS"; target = 810EE9CC72099DB8CE653C742754EC04 /* PersistentStorageSerializable-iOS */; targetProxy = 4D2A85AFB5315F895ED8E20766C4B614 /* PBXContainerItemProxy */; }; 55F35D5044C2CC3CA3D74CF48AD3C182 /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "Reflection-OSX"; target = 8302DFE25125E545B660DD41FB4DAD67 /* Reflection-OSX */; targetProxy = B26D0DAB801E487506A768E6C181571B /* PBXContainerItemProxy */; }; A423C4C7B0ED8254F9B7640584BB8DDE /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = Nimble; target = 1321E318D10CFDC9F5B93A7952492CCD /* Nimble */; targetProxy = 362C7D8F64D2069669D0361A894B07DD /* PBXContainerItemProxy */; }; BAA858ED93A0AC61EAC4D3E4DF4753A9 /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "Reflection-OSX"; target = 8302DFE25125E545B660DD41FB4DAD67 /* Reflection-OSX */; targetProxy = D7611BE4244CB48B792553F5B14E126B /* PBXContainerItemProxy */; }; BD475F43DE62EFCA9655DB3CEE4B0892 /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "PersistentStorageSerializable-OSX"; target = B29FB212BE53D249CF080AF2FC6B42D5 /* PersistentStorageSerializable-OSX */; targetProxy = 3C951DED5AEBD73277E58FD83A3DEAC1 /* PBXContainerItemProxy */; }; C4FF8625191A1F15A28302281CEEE0EC /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "Reflection-iOS"; target = F0CEC1F3C61AFCB9ADA5919C64B003CE /* Reflection-iOS */; targetProxy = 830ED203775A09F2188E8B7988E838FD /* PBXContainerItemProxy */; }; F98C13D6D032C95C1913D4AFE48511C3 /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "Reflection-iOS"; target = F0CEC1F3C61AFCB9ADA5919C64B003CE /* Reflection-iOS */; targetProxy = 27510798F8AD1C92D9FB66C516C94881 /* PBXContainerItemProxy */; }; FA8AB738B2E50CEB9120D41F5442D7B4 /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "Reflection-iOS"; target = F0CEC1F3C61AFCB9ADA5919C64B003CE /* Reflection-iOS */; targetProxy = 0301C33F3EE8422150ECA9CD70476491 /* PBXContainerItemProxy */; }; FF9952B7AE33F3727AC1E9BAC6F1B3FE /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "PersistentStorageSerializable-iOS"; target = 810EE9CC72099DB8CE653C742754EC04 /* PersistentStorageSerializable-iOS */; targetProxy = D49CF07FCC46DBEEE26DD631094D3918 /* PBXContainerItemProxy */; }; /* End PBXTargetDependency section */ /* Begin XCBuildConfiguration section */ 04020B9E0797A7C9CA7A101EA9312572 /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = 09C1992E68D8FC0C0241FC40D3899B5D /* Nimble.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Nimble/Nimble-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Nimble/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/Nimble/Nimble.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_NAME = Nimble; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 29B40F1BF44286F6D16327598901710A /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = 272AA0D36A2B77FCF978B083C7D8673C /* Pods-PersistentStorageSerializable_iOSExample.release.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; INFOPLIST_FILE = "Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACH_O_TYPE = staticlib; MODULEMAP_FILE = "Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = Pods_PersistentStorageSerializable_iOSExample; SDKROOT = iphoneos; SKIP_INSTALL = YES; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 4097F18CFBDFBE7EBAE95F0F173786CD /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = AB379B8B8259CE097D226FB13A1FC648 /* PersistentStorageSerializable-iOS.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-prefix.pch"; INFOPLIST_FILE = "Target Support Files/PersistentStorageSerializable-iOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_NAME = PersistentStorageSerializable; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 5B9C2E6EB57249D6A19D3E25446FF8CE /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = B843A390CA2C46325E617109CE7C00B4 /* Pods-PersistentStorageSerializable_MacExample.release.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; INFOPLIST_FILE = "Target Support Files/Pods-PersistentStorageSerializable_MacExample/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACH_O_TYPE = staticlib; MACOSX_DEPLOYMENT_TARGET = 10.11; MODULEMAP_FILE = "Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = Pods_PersistentStorageSerializable_MacExample; SDKROOT = macosx; SKIP_INSTALL = YES; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 679D4439A688D71B8713513F5F23BFEA /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = 449695496334292237F7ABF92C612C79 /* Reflection-OSX.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Reflection-OSX/Reflection-OSX-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Reflection-OSX/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.9; MODULEMAP_FILE = "Target Support Files/Reflection-OSX/Reflection-OSX.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_NAME = Reflection; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_VERSION = 3.0; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 6E8030017BE83EE002A2BF0A731EC174 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 1AD12082F1076D96DAC1FD9A39D116A7 /* PersistentStorageSerializable-OSX.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX-prefix.pch"; INFOPLIST_FILE = "Target Support Files/PersistentStorageSerializable-OSX/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; MODULEMAP_FILE = "Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_NAME = PersistentStorageSerializable; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 3.0; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; 840DE5127F850E2FC63D976D4F8FAEAF /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = 66EA1514CB8DCAB8B490F192914CCE88 /* Reflection-iOS.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Reflection-iOS/Reflection-iOS-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Reflection-iOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/Reflection-iOS/Reflection-iOS.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_NAME = Reflection; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 89A950A3D7361552736E3DBD5B44A644 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_NONNULL = YES; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGNING_REQUIRED = NO; COPY_PHASE_STRIP = YES; ENABLE_NS_ASSERTIONS = NO; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_PREPROCESSOR_DEFINITIONS = ( "POD_CONFIGURATION_RELEASE=1", "$(inherited)", ); GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; STRIP_INSTALLED_PRODUCT = NO; SYMROOT = "${SRCROOT}/../build"; VALIDATE_PRODUCT = YES; }; name = Release; }; 9C8CB576F6643F5F347D1FE51EBABB18 /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = DDAB3E7FAA610141534F47F426392A3D /* Pods-PersistentStorageSerializable_Tests.release.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; INFOPLIST_FILE = "Target Support Files/Pods-PersistentStorageSerializable_Tests/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACH_O_TYPE = staticlib; MODULEMAP_FILE = "Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = Pods_PersistentStorageSerializable_Tests; SDKROOT = iphoneos; SKIP_INSTALL = YES; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; 9F1EF704CEE8D5453E50B02894CA45C7 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 66EA1514CB8DCAB8B490F192914CCE88 /* Reflection-iOS.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Reflection-iOS/Reflection-iOS-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Reflection-iOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/Reflection-iOS/Reflection-iOS.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_NAME = Reflection; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; A154D3F3116FDFA6DFDF3AFCAC7D10DC /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = A4B56A6EED0B50275C67F754263391DA /* Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; INFOPLIST_FILE = "Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACH_O_TYPE = staticlib; MODULEMAP_FILE = "Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = Pods_PersistentStorageSerializable_iOSExample; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; A34E7C9DDEF127A6C381600D79627F6E /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 37FEFD4566840955F87EC36E6CFA43F1 /* Pods-PersistentStorageSerializable_MacExample.debug.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; INFOPLIST_FILE = "Target Support Files/Pods-PersistentStorageSerializable_MacExample/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACH_O_TYPE = staticlib; MACOSX_DEPLOYMENT_TARGET = 10.11; MODULEMAP_FILE = "Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = Pods_PersistentStorageSerializable_MacExample; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; AEDA68C220B5001B4330958EF4FBC0B4 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 449695496334292237F7ABF92C612C79 /* Reflection-OSX.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Reflection-OSX/Reflection-OSX-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Reflection-OSX/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.9; MODULEMAP_FILE = "Target Support Files/Reflection-OSX/Reflection-OSX.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_NAME = Reflection; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 3.0; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; B2B17F20AE275AC92702CB806D8B274B /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = 1AD12082F1076D96DAC1FD9A39D116A7 /* PersistentStorageSerializable-OSX.xcconfig */; buildSettings = { CODE_SIGN_IDENTITY = "-"; "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; COMBINE_HIDPI_IMAGES = YES; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; FRAMEWORK_VERSION = A; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX-prefix.pch"; INFOPLIST_FILE = "Target Support Files/PersistentStorageSerializable-OSX/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; MODULEMAP_FILE = "Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_NAME = PersistentStorageSerializable; SDKROOT = macosx; SKIP_INSTALL = YES; SWIFT_VERSION = 3.0; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; BB9DA0E56B756C42D404519733DE368B /* Release */ = { isa = XCBuildConfiguration; baseConfigurationReference = 89CA505A4090716FCFBB675A171D4137 /* Quick.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Quick/Quick-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Quick/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/Quick/Quick.modulemap"; MTL_ENABLE_DEBUG_INFO = NO; PRODUCT_NAME = Quick; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Release; }; CD90A71C73D3EB0D8FE7F3BCF59812E2 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = B4F57D336E8CD0C8E07BF34E6FBCF86E /* Pods-PersistentStorageSerializable_Tests.debug.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; INFOPLIST_FILE = "Target Support Files/Pods-PersistentStorageSerializable_Tests/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACH_O_TYPE = staticlib; MODULEMAP_FILE = "Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; OTHER_LDFLAGS = ""; OTHER_LIBTOOLFLAGS = ""; PODS_ROOT = "$(SRCROOT)"; PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; PRODUCT_NAME = Pods_PersistentStorageSerializable_Tests; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; D7B9076A9C78E18A8605B3758EEE0B71 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 09C1992E68D8FC0C0241FC40D3899B5D /* Nimble.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Nimble/Nimble-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Nimble/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/Nimble/Nimble.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_NAME = Nimble; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; DE1F24C5EFD45C271798A6E55CB63E92 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_NONNULL = YES; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_OBJC_ARC = YES; CLANG_WARN_BOOL_CONVERSION = YES; CLANG_WARN_CONSTANT_CONVERSION = YES; CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; CLANG_WARN_EMPTY_BODY = YES; CLANG_WARN_ENUM_CONVERSION = YES; CLANG_WARN_INT_CONVERSION = YES; CLANG_WARN_OBJC_ROOT_CLASS = YES; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; CODE_SIGNING_REQUIRED = NO; COPY_PHASE_STRIP = NO; ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; GCC_OPTIMIZATION_LEVEL = 0; GCC_PREPROCESSOR_DEFINITIONS = ( "POD_CONFIGURATION_DEBUG=1", "DEBUG=1", "$(inherited)", ); GCC_SYMBOLS_PRIVATE_EXTERN = NO; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; GCC_WARN_ABOUT_RETURN_TYPE = YES; GCC_WARN_UNDECLARED_SELECTOR = YES; GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; ONLY_ACTIVE_ARCH = YES; PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; STRIP_INSTALLED_PRODUCT = NO; SYMROOT = "${SRCROOT}/../build"; }; name = Debug; }; E6010D63EC96090E53B0C2AC98D40EE4 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = 89CA505A4090716FCFBB675A171D4137 /* Quick.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/Quick/Quick-prefix.pch"; INFOPLIST_FILE = "Target Support Files/Quick/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 8.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/Quick/Quick.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_NAME = Quick; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; E6E38F573FCFA445F980B3CD803ECE08 /* Debug */ = { isa = XCBuildConfiguration; baseConfigurationReference = AB379B8B8259CE097D226FB13A1FC648 /* PersistentStorageSerializable-iOS.xcconfig */; buildSettings = { "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_NO_COMMON_BLOCKS = YES; GCC_PREFIX_HEADER = "Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-prefix.pch"; INFOPLIST_FILE = "Target Support Files/PersistentStorageSerializable-iOS/Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MODULEMAP_FILE = "Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS.modulemap"; MTL_ENABLE_DEBUG_INFO = YES; PRODUCT_NAME = PersistentStorageSerializable; SDKROOT = iphoneos; SKIP_INSTALL = YES; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; SWIFT_VERSION = 3.0; TARGETED_DEVICE_FAMILY = "1,2"; VERSIONING_SYSTEM = "apple-generic"; VERSION_INFO_PREFIX = ""; }; name = Debug; }; /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ 0FF05E191588DF44EB64DDDBD0AECCD0 /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable-OSX" */ = { isa = XCConfigurationList; buildConfigurations = ( 6E8030017BE83EE002A2BF0A731EC174 /* Debug */, B2B17F20AE275AC92702CB806D8B274B /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */ = { isa = XCConfigurationList; buildConfigurations = ( DE1F24C5EFD45C271798A6E55CB63E92 /* Debug */, 89A950A3D7361552736E3DBD5B44A644 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 2FAF241D791923DB8E7AE90EDE7027C3 /* Build configuration list for PBXNativeTarget "Pods-PersistentStorageSerializable_iOSExample" */ = { isa = XCConfigurationList; buildConfigurations = ( A154D3F3116FDFA6DFDF3AFCAC7D10DC /* Debug */, 29B40F1BF44286F6D16327598901710A /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 323621E0B680E87AA6892CEE3C97081D /* Build configuration list for PBXNativeTarget "Quick" */ = { isa = XCConfigurationList; buildConfigurations = ( E6010D63EC96090E53B0C2AC98D40EE4 /* Debug */, BB9DA0E56B756C42D404519733DE368B /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 6CDCABBEB0265ED19E8A8CF567DACD69 /* Build configuration list for PBXNativeTarget "Reflection-iOS" */ = { isa = XCConfigurationList; buildConfigurations = ( 9F1EF704CEE8D5453E50B02894CA45C7 /* Debug */, 840DE5127F850E2FC63D976D4F8FAEAF /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; 83E8B094BB06F88FAA1D579ECE15F50A /* Build configuration list for PBXNativeTarget "PersistentStorageSerializable-iOS" */ = { isa = XCConfigurationList; buildConfigurations = ( E6E38F573FCFA445F980B3CD803ECE08 /* Debug */, 4097F18CFBDFBE7EBAE95F0F173786CD /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; B1DBAFB75A3AF98C8C6B0863BDC7A2E3 /* Build configuration list for PBXNativeTarget "Nimble" */ = { isa = XCConfigurationList; buildConfigurations = ( D7B9076A9C78E18A8605B3758EEE0B71 /* Debug */, 04020B9E0797A7C9CA7A101EA9312572 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; D92D3AFFD976E7382A2EC7E51CCBA37C /* Build configuration list for PBXNativeTarget "Pods-PersistentStorageSerializable_MacExample" */ = { isa = XCConfigurationList; buildConfigurations = ( A34E7C9DDEF127A6C381600D79627F6E /* Debug */, 5B9C2E6EB57249D6A19D3E25446FF8CE /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; E224EA756B2648B2E5AB2028E714FD79 /* Build configuration list for PBXNativeTarget "Pods-PersistentStorageSerializable_Tests" */ = { isa = XCConfigurationList; buildConfigurations = ( CD90A71C73D3EB0D8FE7F3BCF59812E2 /* Debug */, 9C8CB576F6643F5F347D1FE51EBABB18 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; E9E41A62CDC5D28F3772CFCB3460DFD4 /* Build configuration list for PBXNativeTarget "Reflection-OSX" */ = { isa = XCConfigurationList; buildConfigurations = ( AEDA68C220B5001B4330958EF4FBC0B4 /* Debug */, 679D4439A688D71B8713513F5F23BFEA /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; /* End XCConfigurationList section */ }; rootObject = D41D8CD98F00B204E9800998ECF8427E /* Project object */; } ================================================ FILE: Example/Pods/Pods.xcodeproj/project.xcworkspace/contents.xcworkspacedata ================================================ ================================================ FILE: Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/PersistentStorageSerializable-OSX.xcscheme ================================================ ================================================ FILE: Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/PersistentStorageSerializable-iOS.xcscheme ================================================ ================================================ FILE: Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/Reflection-OSX.xcscheme ================================================ ================================================ FILE: Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/Reflection-iOS.xcscheme ================================================ ================================================ FILE: Example/Pods/Quick/LICENSE ================================================ Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright 2014, Quick Team Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ================================================ FILE: Example/Pods/Quick/README.md ================================================ ![](http://f.cl.ly/items/0r1E192C1R0b2g2Q3h2w/QuickLogo_Color.png) [![Build Status](https://travis-ci.org/Quick/Quick.svg?branch=master)](https://travis-ci.org/Quick/Quick) Quick is a behavior-driven development framework for Swift and Objective-C. Inspired by [RSpec](https://github.com/rspec/rspec), [Specta](https://github.com/specta/specta), and [Ginkgo](https://github.com/onsi/ginkgo). ![](https://raw.githubusercontent.com/Quick/Assets/master/Screenshots/QuickSpec%20screenshot.png) ```swift // Swift import Quick import Nimble class TableOfContentsSpec: QuickSpec { override func spec() { describe("the 'Documentation' directory") { it("has everything you need to get started") { let sections = Directory("Documentation").sections expect(sections).to(contain("Organized Tests with Quick Examples and Example Groups")) expect(sections).to(contain("Installing Quick")) } context("if it doesn't have what you're looking for") { it("needs to be updated") { let you = You(awesome: true) expect{you.submittedAnIssue}.toEventually(beTruthy()) } } } } } ``` #### Nimble Quick comes together with [Nimble](https://github.com/Quick/Nimble) — a matcher framework for your tests. You can learn why `XCTAssert()` statements make your expectations unclear and how to fix that using Nimble assertions [here](./Documentation/en-us/NimbleAssertions.md). ## Swift Version Certain versions of Quick and Nimble only support certain versions of Swift. Depending on which version of Swift your project uses, you should use specific versions of Quick and Nimble. Use the table below to determine which versions of Quick and Nimble are compatible with your project. |Swift version |Quick version |Nimble version | |:--------------------|:---------------|:--------------| |Swift 3 |v0.10.0 or later|v5.0.0 or later| |Swift 2.2 / Swift 2.3|v0.9.3 |v4.1.0 | ## Documentation All documentation can be found in the [Documentation folder](./Documentation), including [detailed installation instructions](./Documentation/en-us/InstallingQuick.md) for CocoaPods, Carthage, Git submodules, and more. For example, you can install Quick and [Nimble](https://github.com/Quick/Nimble) using CocoaPods by adding the following to your Podfile: ```rb # Podfile use_frameworks! def testing_pods pod 'Quick' pod 'Nimble' end target 'MyTests' do testing_pods end target 'MyUITests' do testing_pods end ``` ## Projects using Quick Many apps use both Quick and Nimble however, as they are not included in the app binary, neither appear in “Top Used Libraries” blog posts. Therefore, it would be greatly appreciated to remind contributors that their efforts are valued by compiling a list of organizations and projects that use them. Does your organization or project use Quick and Nimble? If yes, [please add your project to the list](https://github.com/Quick/Quick/wiki/Projects-using-Quick). ## Who uses Quick Similar to projects using Quick, it would be nice to hear why people use Quick and Nimble. Are there features you love? Are there features that are just okay? Are there some features we have that no one uses? Have something positive to say about Quick (or Nimble)? If yes, [provide a testimonial here](https://github.com/Quick/Quick/wiki/Who-uses-Quick). ## License Apache 2.0 license. See the [`LICENSE`](LICENSE) file for details. ================================================ FILE: Example/Pods/Quick/Sources/Quick/Callsite.swift ================================================ import Foundation /** An object encapsulating the file and line number at which a particular example is defined. */ final public class Callsite: NSObject { /** The absolute path of the file in which an example is defined. */ public let file: String /** The line number on which an example is defined. */ public let line: UInt internal init(file: String, line: UInt) { self.file = file self.line = line } } /** Returns a boolean indicating whether two Callsite objects are equal. If two callsites are in the same file and on the same line, they must be equal. */ public func == (lhs: Callsite, rhs: Callsite) -> Bool { return lhs.file == rhs.file && lhs.line == rhs.line } ================================================ FILE: Example/Pods/Quick/Sources/Quick/Configuration/Configuration.swift ================================================ import Foundation /** A closure that temporarily exposes a Configuration object within the scope of the closure. */ public typealias QuickConfigurer = (_ configuration: Configuration) -> () /** A closure that, given metadata about an example, returns a boolean value indicating whether that example should be run. */ public typealias ExampleFilter = (_ example: Example) -> Bool /** A configuration encapsulates various options you can use to configure Quick's behavior. */ final public class Configuration: NSObject { internal let exampleHooks = ExampleHooks() internal let suiteHooks = SuiteHooks() internal var exclusionFilters: [ExampleFilter] = [ { example in if let pending = example.filterFlags[Filter.pending] { return pending } else { return false } }] internal var inclusionFilters: [ExampleFilter] = [ { example in if let focused = example.filterFlags[Filter.focused] { return focused } else { return false } }] /** Run all examples if none match the configured filters. True by default. */ public var runAllWhenEverythingFiltered = true /** Registers an inclusion filter. All examples are filtered using all inclusion filters. The remaining examples are run. If no examples remain, all examples are run. - parameter filter: A filter that, given an example, returns a value indicating whether that example should be included in the examples that are run. */ public func include(_ filter: @escaping ExampleFilter) { inclusionFilters.append(filter) } /** Registers an exclusion filter. All examples that remain after being filtered by the inclusion filters are then filtered via all exclusion filters. - parameter filter: A filter that, given an example, returns a value indicating whether that example should be excluded from the examples that are run. */ public func exclude(_ filter: @escaping ExampleFilter) { exclusionFilters.append(filter) } /** Identical to Quick.Configuration.beforeEach, except the closure is provided with metadata on the example that the closure is being run prior to. */ #if _runtime(_ObjC) @objc(beforeEachWithMetadata:) public func beforeEach(_ closure: @escaping BeforeExampleWithMetadataClosure) { exampleHooks.appendBefore(closure) } #else public func beforeEach(_ closure: @escaping BeforeExampleWithMetadataClosure) { exampleHooks.appendBefore(closure) } #endif /** Like Quick.DSL.beforeEach, this configures Quick to execute the given closure before each example that is run. The closure passed to this method is executed before each example Quick runs, globally across the test suite. You may call this method multiple times across mulitple +[QuickConfigure configure:] methods in order to define several closures to run before each example. Note that, since Quick makes no guarantee as to the order in which +[QuickConfiguration configure:] methods are evaluated, there is no guarantee as to the order in which beforeEach closures are evaluated either. Mulitple beforeEach defined on a single configuration, however, will be executed in the order they're defined. - parameter closure: The closure to be executed before each example in the test suite. */ public func beforeEach(_ closure: @escaping BeforeExampleClosure) { exampleHooks.appendBefore(closure) } /** Identical to Quick.Configuration.afterEach, except the closure is provided with metadata on the example that the closure is being run after. */ #if _runtime(_ObjC) @objc(afterEachWithMetadata:) public func afterEach(_ closure: @escaping AfterExampleWithMetadataClosure) { exampleHooks.appendAfter(closure) } #else public func afterEach(_ closure: @escaping AfterExampleWithMetadataClosure) { exampleHooks.appendAfter(closure) } #endif /** Like Quick.DSL.afterEach, this configures Quick to execute the given closure after each example that is run. The closure passed to this method is executed after each example Quick runs, globally across the test suite. You may call this method multiple times across mulitple +[QuickConfigure configure:] methods in order to define several closures to run after each example. Note that, since Quick makes no guarantee as to the order in which +[QuickConfiguration configure:] methods are evaluated, there is no guarantee as to the order in which afterEach closures are evaluated either. Mulitple afterEach defined on a single configuration, however, will be executed in the order they're defined. - parameter closure: The closure to be executed before each example in the test suite. */ public func afterEach(_ closure: @escaping AfterExampleClosure) { exampleHooks.appendAfter(closure) } /** Like Quick.DSL.beforeSuite, this configures Quick to execute the given closure prior to any and all examples that are run. The two methods are functionally equivalent. */ public func beforeSuite(_ closure: @escaping BeforeSuiteClosure) { suiteHooks.appendBefore(closure) } /** Like Quick.DSL.afterSuite, this configures Quick to execute the given closure after all examples have been run. The two methods are functionally equivalent. */ public func afterSuite(_ closure: @escaping AfterSuiteClosure) { suiteHooks.appendAfter(closure) } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/DSL/DSL.swift ================================================ /** Defines a closure to be run prior to any examples in the test suite. You may define an unlimited number of these closures, but there is no guarantee as to the order in which they're run. If the test suite crashes before the first example is run, this closure will not be executed. - parameter closure: The closure to be run prior to any examples in the test suite. */ public func beforeSuite(_ closure: @escaping BeforeSuiteClosure) { World.sharedWorld.beforeSuite(closure) } /** Defines a closure to be run after all of the examples in the test suite. You may define an unlimited number of these closures, but there is no guarantee as to the order in which they're run. If the test suite crashes before all examples are run, this closure will not be executed. - parameter closure: The closure to be run after all of the examples in the test suite. */ public func afterSuite(_ closure: @escaping AfterSuiteClosure) { World.sharedWorld.afterSuite(closure) } /** Defines a group of shared examples. These examples can be re-used in several locations by using the `itBehavesLike` function. - parameter name: The name of the shared example group. This must be unique across all shared example groups defined in a test suite. - parameter closure: A closure containing the examples. This behaves just like an example group defined using `describe` or `context`--the closure may contain any number of `beforeEach` and `afterEach` closures, as well as any number of examples (defined using `it`). */ public func sharedExamples(_ name: String, closure: @escaping () -> ()) { World.sharedWorld.sharedExamples(name, closure: { (NSDictionary) in closure() }) } /** Defines a group of shared examples. These examples can be re-used in several locations by using the `itBehavesLike` function. - parameter name: The name of the shared example group. This must be unique across all shared example groups defined in a test suite. - parameter closure: A closure containing the examples. This behaves just like an example group defined using `describe` or `context`--the closure may contain any number of `beforeEach` and `afterEach` closures, as well as any number of examples (defined using `it`). The closure takes a SharedExampleContext as an argument. This context is a function that can be executed to retrieve parameters passed in via an `itBehavesLike` function. */ public func sharedExamples(_ name: String, closure: @escaping SharedExampleClosure) { World.sharedWorld.sharedExamples(name, closure: closure) } /** Defines an example group. Example groups are logical groupings of examples. Example groups can share setup and teardown code. - parameter description: An arbitrary string describing the example group. - parameter closure: A closure that can contain other examples. - parameter flags: A mapping of string keys to booleans that can be used to filter examples or example groups. */ public func describe(_ description: String, flags: FilterFlags = [:], closure: () -> ()) { World.sharedWorld.describe(description, flags: flags, closure: closure) } /** Defines an example group. Equivalent to `describe`. */ public func context(_ description: String, flags: FilterFlags = [:], closure: () -> ()) { World.sharedWorld.context(description, flags: flags, closure: closure) } /** Defines a closure to be run prior to each example in the current example group. This closure is not run for pending or otherwise disabled examples. An example group may contain an unlimited number of beforeEach. They'll be run in the order they're defined, but you shouldn't rely on that behavior. - parameter closure: The closure to be run prior to each example. */ public func beforeEach(_ closure: @escaping BeforeExampleClosure) { World.sharedWorld.beforeEach(closure) } /** Identical to Quick.DSL.beforeEach, except the closure is provided with metadata on the example that the closure is being run prior to. */ public func beforeEach(_ closure: @escaping BeforeExampleWithMetadataClosure) { World.sharedWorld.beforeEach(closure: closure) } /** Defines a closure to be run after each example in the current example group. This closure is not run for pending or otherwise disabled examples. An example group may contain an unlimited number of afterEach. They'll be run in the order they're defined, but you shouldn't rely on that behavior. - parameter closure: The closure to be run after each example. */ public func afterEach(_ closure: @escaping AfterExampleClosure) { World.sharedWorld.afterEach(closure) } /** Identical to Quick.DSL.afterEach, except the closure is provided with metadata on the example that the closure is being run after. */ public func afterEach(_ closure: @escaping AfterExampleWithMetadataClosure) { World.sharedWorld.afterEach(closure: closure) } /** Defines an example. Examples use assertions to demonstrate how code should behave. These are like "tests" in XCTest. - parameter description: An arbitrary string describing what the example is meant to specify. - parameter closure: A closure that can contain assertions. - parameter flags: A mapping of string keys to booleans that can be used to filter examples or example groups. Empty by default. - parameter file: The absolute path to the file containing the example. A sensible default is provided. - parameter line: The line containing the example. A sensible default is provided. */ public func it(_ description: String, flags: FilterFlags = [:], file: String = #file, line: UInt = #line, closure: @escaping () -> ()) { World.sharedWorld.it(description, flags: flags, file: file, line: line, closure: closure) } /** Inserts the examples defined using a `sharedExamples` function into the current example group. The shared examples are executed at this location, as if they were written out manually. - parameter name: The name of the shared examples group to be executed. This must be identical to the name of a shared examples group defined using `sharedExamples`. If there are no shared examples that match the name given, an exception is thrown and the test suite will crash. - parameter flags: A mapping of string keys to booleans that can be used to filter examples or example groups. Empty by default. - parameter file: The absolute path to the file containing the current example group. A sensible default is provided. - parameter line: The line containing the current example group. A sensible default is provided. */ public func itBehavesLike(_ name: String, flags: FilterFlags = [:], file: String = #file, line: UInt = #line) { itBehavesLike(name, flags: flags, file: file, line: line, sharedExampleContext: { return [:] }) } /** Inserts the examples defined using a `sharedExamples` function into the current example group. The shared examples are executed at this location, as if they were written out manually. This function also passes those shared examples a context that can be evaluated to give the shared examples extra information on the subject of the example. - parameter name: The name of the shared examples group to be executed. This must be identical to the name of a shared examples group defined using `sharedExamples`. If there are no shared examples that match the name given, an exception is thrown and the test suite will crash. - parameter sharedExampleContext: A closure that, when evaluated, returns key-value pairs that provide the shared examples with extra information on the subject of the example. - parameter flags: A mapping of string keys to booleans that can be used to filter examples or example groups. Empty by default. - parameter file: The absolute path to the file containing the current example group. A sensible default is provided. - parameter line: The line containing the current example group. A sensible default is provided. */ public func itBehavesLike(_ name: String, flags: FilterFlags = [:], file: String = #file, line: UInt = #line, sharedExampleContext: @escaping SharedExampleContext) { World.sharedWorld.itBehavesLike(name, sharedExampleContext: sharedExampleContext, flags: flags, file: file, line: line) } /** Defines an example or example group that should not be executed. Use `pending` to temporarily disable examples or groups that should not be run yet. - parameter description: An arbitrary string describing the example or example group. - parameter closure: A closure that will not be evaluated. */ public func pending(_ description: String, closure: () -> ()) { World.sharedWorld.pending(description, closure: closure) } /** Use this to quickly mark a `describe` closure as pending. This disables all examples within the closure. */ public func xdescribe(_ description: String, flags: FilterFlags, closure: () -> ()) { World.sharedWorld.xdescribe(description, flags: flags, closure: closure) } /** Use this to quickly mark a `context` closure as pending. This disables all examples within the closure. */ public func xcontext(_ description: String, flags: FilterFlags, closure: () -> ()) { xdescribe(description, flags: flags, closure: closure) } /** Use this to quickly mark an `it` closure as pending. This disables the example and ensures the code within the closure is never run. */ public func xit(_ description: String, flags: FilterFlags = [:], file: String = #file, line: UInt = #line, closure: @escaping () -> ()) { World.sharedWorld.xit(description, flags: flags, file: file, line: line, closure: closure) } /** Use this to quickly focus a `describe` closure, focusing the examples in the closure. If any examples in the test suite are focused, only those examples are executed. This trumps any explicitly focused or unfocused examples within the closure--they are all treated as focused. */ public func fdescribe(_ description: String, flags: FilterFlags = [:], closure: () -> ()) { World.sharedWorld.fdescribe(description, flags: flags, closure: closure) } /** Use this to quickly focus a `context` closure. Equivalent to `fdescribe`. */ public func fcontext(_ description: String, flags: FilterFlags = [:], closure: () -> ()) { fdescribe(description, flags: flags, closure: closure) } /** Use this to quickly focus an `it` closure, focusing the example. If any examples in the test suite are focused, only those examples are executed. */ public func fit(_ description: String, flags: FilterFlags = [:], file: String = #file, line: UInt = #line, closure: @escaping () -> ()) { World.sharedWorld.fit(description, flags: flags, file: file, line: line, closure: closure) } ================================================ FILE: Example/Pods/Quick/Sources/Quick/DSL/World+DSL.swift ================================================ import Foundation /** Adds methods to World to support top-level DSL functions (Swift) and macros (Objective-C). These functions map directly to the DSL that test writers use in their specs. */ extension World { internal func beforeSuite(_ closure: @escaping BeforeSuiteClosure) { suiteHooks.appendBefore(closure) } internal func afterSuite(_ closure: @escaping AfterSuiteClosure) { suiteHooks.appendAfter(closure) } internal func sharedExamples(_ name: String, closure: @escaping SharedExampleClosure) { registerSharedExample(name, closure: closure) } internal func describe(_ description: String, flags: FilterFlags, closure: () -> ()) { guard currentExampleMetadata == nil else { raiseError("'describe' cannot be used inside '\(currentPhase)', 'describe' may only be used inside 'context' or 'describe'. ") } guard currentExampleGroup != nil else { raiseError("Error: example group was not created by its parent QuickSpec spec. Check that describe() or context() was used in QuickSpec.spec() and not a more general context (i.e. an XCTestCase test)") } let group = ExampleGroup(description: description, flags: flags) currentExampleGroup.appendExampleGroup(group) performWithCurrentExampleGroup(group, closure: closure) } internal func context(_ description: String, flags: FilterFlags, closure: () -> ()) { guard currentExampleMetadata == nil else { raiseError("'context' cannot be used inside '\(currentPhase)', 'context' may only be used inside 'context' or 'describe'. ") } self.describe(description, flags: flags, closure: closure) } internal func fdescribe(_ description: String, flags: FilterFlags, closure: () -> ()) { var focusedFlags = flags focusedFlags[Filter.focused] = true self.describe(description, flags: focusedFlags, closure: closure) } internal func xdescribe(_ description: String, flags: FilterFlags, closure: () -> ()) { var pendingFlags = flags pendingFlags[Filter.pending] = true self.describe(description, flags: pendingFlags, closure: closure) } internal func beforeEach(_ closure: @escaping BeforeExampleClosure) { guard currentExampleMetadata == nil else { raiseError("'beforeEach' cannot be used inside '\(currentPhase)', 'beforeEach' may only be used inside 'context' or 'describe'. ") } currentExampleGroup.hooks.appendBefore(closure) } #if _runtime(_ObjC) @objc(beforeEachWithMetadata:) internal func beforeEach(closure: @escaping BeforeExampleWithMetadataClosure) { currentExampleGroup.hooks.appendBefore(closure) } #else internal func beforeEach(closure: @escaping BeforeExampleWithMetadataClosure) { currentExampleGroup.hooks.appendBefore(closure) } #endif internal func afterEach(_ closure: @escaping AfterExampleClosure) { guard currentExampleMetadata == nil else { raiseError("'afterEach' cannot be used inside '\(currentPhase)', 'afterEach' may only be used inside 'context' or 'describe'. ") } currentExampleGroup.hooks.appendAfter(closure) } #if _runtime(_ObjC) @objc(afterEachWithMetadata:) internal func afterEach(closure: @escaping AfterExampleWithMetadataClosure) { currentExampleGroup.hooks.appendAfter(closure) } #else internal func afterEach(closure: @escaping AfterExampleWithMetadataClosure) { currentExampleGroup.hooks.appendAfter(closure) } #endif internal func it(_ description: String, flags: FilterFlags, file: String, line: UInt, closure: @escaping () -> ()) { if beforesCurrentlyExecuting { raiseError("'it' cannot be used inside 'beforeEach', 'it' may only be used inside 'context' or 'describe'. ") } if aftersCurrentlyExecuting { raiseError("'it' cannot be used inside 'afterEach', 'it' may only be used inside 'context' or 'describe'. ") } guard currentExampleMetadata == nil else { raiseError("'it' cannot be used inside 'it', 'it' may only be used inside 'context' or 'describe'. ") } let callsite = Callsite(file: file, line: line) let example = Example(description: description, callsite: callsite, flags: flags, closure: closure) currentExampleGroup.appendExample(example) } internal func fit(_ description: String, flags: FilterFlags, file: String, line: UInt, closure: @escaping () -> ()) { var focusedFlags = flags focusedFlags[Filter.focused] = true self.it(description, flags: focusedFlags, file: file, line: line, closure: closure) } internal func xit(_ description: String, flags: FilterFlags, file: String, line: UInt, closure: @escaping () -> ()) { var pendingFlags = flags pendingFlags[Filter.pending] = true self.it(description, flags: pendingFlags, file: file, line: line, closure: closure) } internal func itBehavesLike(_ name: String, sharedExampleContext: @escaping SharedExampleContext, flags: FilterFlags, file: String, line: UInt) { guard currentExampleMetadata == nil else { raiseError("'itBehavesLike' cannot be used inside '\(currentPhase)', 'itBehavesLike' may only be used inside 'context' or 'describe'. ") } let callsite = Callsite(file: file, line: line) let closure = World.sharedWorld.sharedExample(name) let group = ExampleGroup(description: name, flags: flags) currentExampleGroup.appendExampleGroup(group) performWithCurrentExampleGroup(group) { closure(sharedExampleContext) } group.walkDownExamples { (example: Example) in example.isSharedExample = true example.callsite = callsite } } #if _runtime(_ObjC) @objc(itWithDescription:flags:file:line:closure:) private func objc_it(_ description: String, flags: FilterFlags, file: String, line: UInt, closure: @escaping () -> ()) { it(description, flags: flags, file: file, line: line, closure: closure) } @objc(fitWithDescription:flags:file:line:closure:) private func objc_fit(_ description: String, flags: FilterFlags, file: String, line: UInt, closure: @escaping () -> ()) { fit(description, flags: flags, file: file, line: line, closure: closure) } @objc(xitWithDescription:flags:file:line:closure:) private func objc_xit(_ description: String, flags: FilterFlags, file: String, line: UInt, closure: @escaping () -> ()) { xit(description, flags: flags, file: file, line: line, closure: closure) } @objc(itBehavesLikeSharedExampleNamed:sharedExampleContext:flags:file:line:) private func objc_itBehavesLike(_ name: String, sharedExampleContext: @escaping SharedExampleContext, flags: FilterFlags, file: String, line: UInt) { itBehavesLike(name, sharedExampleContext: sharedExampleContext, flags: flags, file: file, line: line) } #endif internal func pending(_ description: String, closure: () -> ()) { print("Pending: \(description)") } private var currentPhase: String { if beforesCurrentlyExecuting { return "beforeEach" } else if aftersCurrentlyExecuting { return "afterEach" } return "it" } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/ErrorUtility.swift ================================================ import Foundation internal func raiseError(_ message: String) -> Never { #if _runtime(_ObjC) NSException(name: .internalInconsistencyException, reason: message, userInfo: nil).raise() #endif // This won't be reached when ObjC is available and the exception above is raisd fatalError(message) } ================================================ FILE: Example/Pods/Quick/Sources/Quick/Example.swift ================================================ import Foundation private var numberOfExamplesRun = 0 /** Examples, defined with the `it` function, use assertions to demonstrate how code should behave. These are like "tests" in XCTest. */ final public class Example: NSObject { /** A boolean indicating whether the example is a shared example; i.e.: whether it is an example defined with `itBehavesLike`. */ public var isSharedExample = false /** The site at which the example is defined. This must be set correctly in order for Xcode to highlight the correct line in red when reporting a failure. */ public var callsite: Callsite weak internal var group: ExampleGroup? private let internalDescription: String private let closure: () -> () private let flags: FilterFlags internal init(description: String, callsite: Callsite, flags: FilterFlags, closure: @escaping () -> ()) { self.internalDescription = description self.closure = closure self.callsite = callsite self.flags = flags } public override var description: String { return internalDescription } /** The example name. A name is a concatenation of the name of the example group the example belongs to, followed by the description of the example itself. The example name is used to generate a test method selector to be displayed in Xcode's test navigator. */ public var name: String { guard let groupName = group?.name else { return description } return "\(groupName), \(description)" } /** Executes the example closure, as well as all before and after closures defined in the its surrounding example groups. */ public func run() { let world = World.sharedWorld if numberOfExamplesRun == 0 { world.suiteHooks.executeBefores() } let exampleMetadata = ExampleMetadata(example: self, exampleIndex: numberOfExamplesRun) world.currentExampleMetadata = exampleMetadata world.exampleHooks.executeBefores(exampleMetadata) group!.phase = .beforesExecuting for before in group!.befores { before(exampleMetadata) } group!.phase = .beforesFinished closure() group!.phase = .aftersExecuting for after in group!.afters { after(exampleMetadata) } group!.phase = .aftersFinished world.exampleHooks.executeAfters(exampleMetadata) numberOfExamplesRun += 1 if !world.isRunningAdditionalSuites && numberOfExamplesRun >= world.includedExampleCount { world.suiteHooks.executeAfters() } } /** Evaluates the filter flags set on this example and on the example groups this example belongs to. Flags set on the example are trumped by flags on the example group it belongs to. Flags on inner example groups are trumped by flags on outer example groups. */ internal var filterFlags: FilterFlags { var aggregateFlags = flags for (key, value) in group!.filterFlags { aggregateFlags[key] = value } return aggregateFlags } } /** Returns a boolean indicating whether two Example objects are equal. If two examples are defined at the exact same callsite, they must be equal. */ public func == (lhs: Example, rhs: Example) -> Bool { return lhs.callsite == rhs.callsite } ================================================ FILE: Example/Pods/Quick/Sources/Quick/ExampleGroup.swift ================================================ import Foundation /** Example groups are logical groupings of examples, defined with the `describe` and `context` functions. Example groups can share setup and teardown code. */ final public class ExampleGroup: NSObject { weak internal var parent: ExampleGroup? internal let hooks = ExampleHooks() internal var phase: HooksPhase = .nothingExecuted private let internalDescription: String private let flags: FilterFlags private let isInternalRootExampleGroup: Bool private var childGroups = [ExampleGroup]() private var childExamples = [Example]() internal init(description: String, flags: FilterFlags, isInternalRootExampleGroup: Bool = false) { self.internalDescription = description self.flags = flags self.isInternalRootExampleGroup = isInternalRootExampleGroup } public override var description: String { return internalDescription } /** Returns a list of examples that belong to this example group, or to any of its descendant example groups. */ public var examples: [Example] { var examples = childExamples for group in childGroups { examples.append(contentsOf: group.examples) } return examples } internal var name: String? { if let parent = parent { guard let name = parent.name else { return description } return "\(name), \(description)" } else { return isInternalRootExampleGroup ? nil : description } } internal var filterFlags: FilterFlags { var aggregateFlags = flags walkUp() { (group: ExampleGroup) -> () in for (key, value) in group.flags { aggregateFlags[key] = value } } return aggregateFlags } internal var befores: [BeforeExampleWithMetadataClosure] { var closures = Array(hooks.befores.reversed()) walkUp() { (group: ExampleGroup) -> () in closures.append(contentsOf: Array(group.hooks.befores.reversed())) } return Array(closures.reversed()) } internal var afters: [AfterExampleWithMetadataClosure] { var closures = hooks.afters walkUp() { (group: ExampleGroup) -> () in closures.append(contentsOf: group.hooks.afters) } return closures } internal func walkDownExamples(_ callback: (_ example: Example) -> ()) { for example in childExamples { callback(example) } for group in childGroups { group.walkDownExamples(callback) } } internal func appendExampleGroup(_ group: ExampleGroup) { group.parent = self childGroups.append(group) } internal func appendExample(_ example: Example) { example.group = self childExamples.append(example) } private func walkUp(_ callback: (_ group: ExampleGroup) -> ()) { var group = self while let parent = group.parent { callback(parent) group = parent } } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/ExampleMetadata.swift ================================================ import Foundation /** A class that encapsulates information about an example, including the index at which the example was executed, as well as the example itself. */ final public class ExampleMetadata: NSObject { /** The example for which this metadata was collected. */ public let example: Example /** The index at which this example was executed in the test suite. */ public let exampleIndex: Int internal init(example: Example, exampleIndex: Int) { self.example = example self.exampleIndex = exampleIndex } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/Filter.swift ================================================ import Foundation /** A mapping of string keys to booleans that can be used to filter examples or example groups. For example, a "focused" example would have the flags [Focused: true]. */ public typealias FilterFlags = [String: Bool] /** A namespace for filter flag keys, defined primarily to make the keys available in Objective-C. */ final public class Filter: NSObject { /** Example and example groups with [Focused: true] are included in test runs, excluding all other examples without this flag. Use this to only run one or two tests that you're currently focusing on. */ public class var focused: String { return "focused" } /** Example and example groups with [Pending: true] are excluded from test runs. Use this to temporarily suspend examples that you know do not pass yet. */ public class var pending: String { return "pending" } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/Hooks/Closures.swift ================================================ // MARK: Example Hooks /** A closure executed before an example is run. */ public typealias BeforeExampleClosure = () -> () /** A closure executed before an example is run. The closure is given example metadata, which contains information about the example that is about to be run. */ public typealias BeforeExampleWithMetadataClosure = (_ exampleMetadata: ExampleMetadata) -> () /** A closure executed after an example is run. */ public typealias AfterExampleClosure = BeforeExampleClosure /** A closure executed after an example is run. The closure is given example metadata, which contains information about the example that has just finished running. */ public typealias AfterExampleWithMetadataClosure = BeforeExampleWithMetadataClosure // MARK: Suite Hooks /** A closure executed before any examples are run. */ public typealias BeforeSuiteClosure = () -> () /** A closure executed after all examples have finished running. */ public typealias AfterSuiteClosure = BeforeSuiteClosure ================================================ FILE: Example/Pods/Quick/Sources/Quick/Hooks/ExampleHooks.swift ================================================ /** A container for closures to be executed before and after each example. */ final internal class ExampleHooks { internal var befores: [BeforeExampleWithMetadataClosure] = [] internal var afters: [AfterExampleWithMetadataClosure] = [] internal var phase: HooksPhase = .nothingExecuted internal func appendBefore(_ closure: @escaping BeforeExampleWithMetadataClosure) { befores.append(closure) } internal func appendBefore(_ closure: @escaping BeforeExampleClosure) { befores.append { (exampleMetadata: ExampleMetadata) in closure() } } internal func appendAfter(_ closure: @escaping AfterExampleWithMetadataClosure) { afters.append(closure) } internal func appendAfter(_ closure: @escaping AfterExampleClosure) { afters.append { (exampleMetadata: ExampleMetadata) in closure() } } internal func executeBefores(_ exampleMetadata: ExampleMetadata) { phase = .beforesExecuting for before in befores { before(exampleMetadata) } phase = .beforesFinished } internal func executeAfters(_ exampleMetadata: ExampleMetadata) { phase = .aftersExecuting for after in afters { after(exampleMetadata) } phase = .aftersFinished } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/Hooks/HooksPhase.swift ================================================ /** A description of the execution cycle of the current example with respect to the hooks of that example. */ internal enum HooksPhase { case nothingExecuted case beforesExecuting case beforesFinished case aftersExecuting case aftersFinished } ================================================ FILE: Example/Pods/Quick/Sources/Quick/Hooks/SuiteHooks.swift ================================================ /** A container for closures to be executed before and after all examples. */ final internal class SuiteHooks { internal var befores: [BeforeSuiteClosure] = [] internal var afters: [AfterSuiteClosure] = [] internal var phase: HooksPhase = .nothingExecuted internal func appendBefore(_ closure: @escaping BeforeSuiteClosure) { befores.append(closure) } internal func appendAfter(_ closure: @escaping AfterSuiteClosure) { afters.append(closure) } internal func executeBefores() { phase = .beforesExecuting for before in befores { before() } phase = .beforesFinished } internal func executeAfters() { phase = .aftersExecuting for after in afters { after() } phase = .aftersFinished } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/NSBundle+CurrentTestBundle.swift ================================================ #if os(OSX) || os(iOS) || os(watchOS) || os(tvOS) import Foundation extension Bundle { /** Locates the first bundle with a '.xctest' file extension. */ internal static var currentTestBundle: Bundle? { return allBundles.first { $0.bundlePath.hasSuffix(".xctest") } } } #endif ================================================ FILE: Example/Pods/Quick/Sources/Quick/QuickSelectedTestSuiteBuilder.swift ================================================ #if os(OSX) || os(iOS) || os(watchOS) || os(tvOS) import Foundation /** Responsible for building a "Selected tests" suite. This corresponds to a single spec, and all its examples. */ internal class QuickSelectedTestSuiteBuilder: QuickTestSuiteBuilder { /** The test spec class to run. */ let testCaseClass: AnyClass! /** For Objective-C classes, returns the class name. For Swift classes without, an explicit Objective-C name, returns a module-namespaced class name (e.g., "FooTests.FooSpec"). */ var testSuiteClassName: String { return NSStringFromClass(testCaseClass) } /** Given a test case name: FooSpec/testFoo Optionally constructs a test suite builder for the named test case class in the running test bundle. If no test bundle can be found, or the test case class can't be found, initialization fails and returns `nil`. */ init?(forTestCaseWithName name: String) { guard let testCaseClass = testCaseClassForTestCaseWithName(name) else { self.testCaseClass = nil return nil } self.testCaseClass = testCaseClass } /** Returns a `QuickTestSuite` that runs the associated test case class. */ func buildTestSuite() -> QuickTestSuite { return QuickTestSuite(forTestCaseClass: testCaseClass) } } /** Searches `Bundle.allBundles()` for an xctest bundle, then looks up the named test case class in that bundle. Returns `nil` if a bundle or test case class cannot be found. */ private func testCaseClassForTestCaseWithName(_ name: String) -> AnyClass? { func extractClassName(_ name: String) -> String? { return name.components(separatedBy: "/").first } guard let className = extractClassName(name) else { return nil } guard let bundle = Bundle.currentTestBundle else { return nil } if let testCaseClass = bundle.classNamed(className) { return testCaseClass } let bundleFileName = bundle.bundleURL.fileName let moduleName = bundleFileName.replacingOccurrences(of: " ", with: "_") return NSClassFromString("\(moduleName).\(className)") } #endif ================================================ FILE: Example/Pods/Quick/Sources/Quick/QuickTestSuite.swift ================================================ #if os(OSX) || os(iOS) || os(watchOS) || os(tvOS) import XCTest /** This protocol defines the role of an object that builds test suites. */ internal protocol QuickTestSuiteBuilder { /** Construct a `QuickTestSuite` instance with the appropriate test cases added as tests. Subsequent calls to this method should return equivalent test suites. */ func buildTestSuite() -> QuickTestSuite } /** A base class for a class cluster of Quick test suites, that should correctly build dynamic test suites for XCTest to execute. */ public class QuickTestSuite: XCTestSuite { private static var builtTestSuites: Set = Set() /** Construct a test suite for a specific, selected subset of test cases (rather than the default, which as all test cases). If this method is called multiple times for the same test case class, e.g.. FooSpec/testFoo FooSpec/testBar It is expected that the first call should return a valid test suite, and all subsequent calls should return `nil`. */ public static func selectedTestSuite(forTestCaseWithName name: String) -> QuickTestSuite? { guard let builder = QuickSelectedTestSuiteBuilder(forTestCaseWithName: name) else { return nil } if builtTestSuites.contains(builder.testSuiteClassName) { return nil } else { builtTestSuites.insert(builder.testSuiteClassName) return builder.buildTestSuite() } } } #endif ================================================ FILE: Example/Pods/Quick/Sources/Quick/URL+FileName.swift ================================================ import Foundation extension URL { /** Returns the path file name without file extension. */ var fileName: String { return self.deletingPathExtension().lastPathComponent } } ================================================ FILE: Example/Pods/Quick/Sources/Quick/World.swift ================================================ import Foundation /** A closure that, when evaluated, returns a dictionary of key-value pairs that can be accessed from within a group of shared examples. */ public typealias SharedExampleContext = () -> (NSDictionary) /** A closure that is used to define a group of shared examples. This closure may contain any number of example and example groups. */ public typealias SharedExampleClosure = (@escaping SharedExampleContext) -> () /** A collection of state Quick builds up in order to work its magic. World is primarily responsible for maintaining a mapping of QuickSpec classes to root example groups for those classes. It also maintains a mapping of shared example names to shared example closures. You may configure how Quick behaves by calling the -[World configure:] method from within an overridden +[QuickConfiguration configure:] method. */ final internal class World: NSObject { /** The example group that is currently being run. The DSL requires that this group is correctly set in order to build a correct hierarchy of example groups and their examples. */ internal var currentExampleGroup: ExampleGroup! /** The example metadata of the test that is currently being run. This is useful for using the Quick test metadata (like its name) at runtime. */ internal var currentExampleMetadata: ExampleMetadata? /** A flag that indicates whether additional test suites are being run within this test suite. This is only true within the context of Quick functional tests. */ #if _runtime(_ObjC) // Convention of generating Objective-C selector has been changed on Swift 3 @objc(isRunningAdditionalSuites) internal var isRunningAdditionalSuites = false #else internal var isRunningAdditionalSuites = false #endif private var specs: Dictionary = [:] private var sharedExamples: [String: SharedExampleClosure] = [:] private let configuration = Configuration() private var isConfigurationFinalized = false internal var exampleHooks: ExampleHooks {return configuration.exampleHooks } internal var suiteHooks: SuiteHooks { return configuration.suiteHooks } // MARK: Singleton Constructor private override init() {} static let sharedWorld = World() // MARK: Public Interface /** Exposes the World's Configuration object within the scope of the closure so that it may be configured. This method must not be called outside of an overridden +[QuickConfiguration configure:] method. - parameter closure: A closure that takes a Configuration object that can be mutated to change Quick's behavior. */ internal func configure(_ closure: QuickConfigurer) { assert(!isConfigurationFinalized, "Quick cannot be configured outside of a +[QuickConfiguration configure:] method. You should not call -[World configure:] directly. Instead, subclass QuickConfiguration and override the +[QuickConfiguration configure:] method.") closure(configuration) } /** Finalizes the World's configuration. Any subsequent calls to World.configure() will raise. */ internal func finalizeConfiguration() { isConfigurationFinalized = true } /** Returns an internally constructed root example group for the given QuickSpec class. A root example group with the description "root example group" is lazily initialized for each QuickSpec class. This root example group wraps the top level of a -[QuickSpec spec] method--it's thanks to this group that users can define beforeEach and it closures at the top level, like so: override func spec() { // These belong to the root example group beforeEach {} it("is at the top level") {} } - parameter cls: The QuickSpec class for which to retrieve the root example group. - returns: The root example group for the class. */ internal func rootExampleGroupForSpecClass(_ cls: AnyClass) -> ExampleGroup { let name = String(describing: cls) if let group = specs[name] { return group } else { let group = ExampleGroup( description: "root example group", flags: [:], isInternalRootExampleGroup: true ) specs[name] = group return group } } /** Returns all examples that should be run for a given spec class. There are two filtering passes that occur when determining which examples should be run. That is, these examples are the ones that are included by inclusion filters, and are not excluded by exclusion filters. - parameter specClass: The QuickSpec subclass for which examples are to be returned. - returns: A list of examples to be run as test invocations. */ internal func examples(_ specClass: AnyClass) -> [Example] { // 1. Grab all included examples. let included = includedExamples // 2. Grab the intersection of (a) examples for this spec, and (b) included examples. let spec = rootExampleGroupForSpecClass(specClass).examples.filter { included.contains($0) } // 3. Remove all excluded examples. return spec.filter { example in !self.configuration.exclusionFilters.reduce(false) { $0 || $1(example) } } } #if _runtime(_ObjC) @objc(examplesForSpecClass:) private func objc_examples(_ specClass: AnyClass) -> [Example] { return examples(specClass) } #endif // MARK: Internal internal func registerSharedExample(_ name: String, closure: @escaping SharedExampleClosure) { raiseIfSharedExampleAlreadyRegistered(name) sharedExamples[name] = closure } internal func sharedExample(_ name: String) -> SharedExampleClosure { raiseIfSharedExampleNotRegistered(name) return sharedExamples[name]! } internal var includedExampleCount: Int { return includedExamples.count } internal var beforesCurrentlyExecuting: Bool { let suiteBeforesExecuting = suiteHooks.phase == .beforesExecuting let exampleBeforesExecuting = exampleHooks.phase == .beforesExecuting var groupBeforesExecuting = false if let runningExampleGroup = currentExampleMetadata?.example.group { groupBeforesExecuting = runningExampleGroup.phase == .beforesExecuting } return suiteBeforesExecuting || exampleBeforesExecuting || groupBeforesExecuting } internal var aftersCurrentlyExecuting: Bool { let suiteAftersExecuting = suiteHooks.phase == .aftersExecuting let exampleAftersExecuting = exampleHooks.phase == .aftersExecuting var groupAftersExecuting = false if let runningExampleGroup = currentExampleMetadata?.example.group { groupAftersExecuting = runningExampleGroup.phase == .aftersExecuting } return suiteAftersExecuting || exampleAftersExecuting || groupAftersExecuting } internal func performWithCurrentExampleGroup(_ group: ExampleGroup, closure: () -> Void) { let previousExampleGroup = currentExampleGroup currentExampleGroup = group closure() currentExampleGroup = previousExampleGroup } private var allExamples: [Example] { var all: [Example] = [] for (_, group) in specs { group.walkDownExamples { all.append($0) } } return all } private var includedExamples: [Example] { let all = allExamples let included = all.filter { example in return self.configuration.inclusionFilters.reduce(false) { $0 || $1(example) } } if included.isEmpty && configuration.runAllWhenEverythingFiltered { return all } else { return included } } private func raiseIfSharedExampleAlreadyRegistered(_ name: String) { if sharedExamples[name] != nil { raiseError("A shared example named '\(name)' has already been registered.") } } private func raiseIfSharedExampleNotRegistered(_ name: String) { if sharedExamples[name] == nil { raiseError("No shared example named '\(name)' has been registered. Registered shared examples: '\(Array(sharedExamples.keys))'") } } } ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/Configuration/QuickConfiguration.h ================================================ #import @class Configuration; /** Subclass QuickConfiguration and override the +[QuickConfiguration configure:] method in order to configure how Quick behaves when running specs, or to define shared examples that are used across spec files. */ @interface QuickConfiguration : NSObject /** This method is executed on each subclass of this class before Quick runs any examples. You may override this method on as many subclasses as you like, but there is no guarantee as to the order in which these methods are executed. You can override this method in order to: 1. Configure how Quick behaves, by modifying properties on the Configuration object. Setting the same properties in several methods has undefined behavior. 2. Define shared examples using `sharedExamples`. @param configuration A mutable object that is used to configure how Quick behaves on a framework level. For details on all the options, see the documentation in Configuration.swift. */ + (void)configure:(Configuration *)configuration; @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/Configuration/QuickConfiguration.m ================================================ #import "QuickConfiguration.h" #import "World.h" #import typedef void (^QCKClassEnumerationBlock)(Class klass); /** Finds all direct subclasses of the given class and passes them to the block provided. The classes are iterated over in the order that objc_getClassList returns them. @param klass The base class to find subclasses of. @param block A block that takes a Class. This block will be executed once for each subclass of klass. */ void qck_enumerateSubclasses(Class klass, QCKClassEnumerationBlock block) { Class *classes = NULL; int classesCount = objc_getClassList(NULL, 0); if (classesCount > 0) { classes = (Class *)calloc(sizeof(Class), classesCount); classesCount = objc_getClassList(classes, classesCount); Class subclass, superclass; for(int i = 0; i < classesCount; i++) { subclass = classes[i]; superclass = class_getSuperclass(subclass); if (superclass == klass && block) { block(subclass); } } free(classes); } } @implementation QuickConfiguration #pragma mark - Object Lifecycle /** QuickConfiguration is not meant to be instantiated; it merely provides a hook for users to configure how Quick behaves. Raise an exception if an instance of QuickConfiguration is created. */ - (instancetype)init { NSString *className = NSStringFromClass([self class]); NSString *selectorName = NSStringFromSelector(@selector(configure:)); [NSException raise:NSInternalInconsistencyException format:@"%@ is not meant to be instantiated; " @"subclass %@ and override %@ to configure Quick.", className, className, selectorName]; return nil; } #pragma mark - NSObject Overrides /** Hook into when QuickConfiguration is initialized in the runtime in order to call +[QuickConfiguration configure:] on each of its subclasses. */ + (void)initialize { // Only enumerate over the subclasses of QuickConfiguration, not any of its subclasses. if ([self class] == [QuickConfiguration class]) { // Only enumerate over subclasses once, even if +[QuickConfiguration initialize] // were to be called several times. This is necessary because +[QuickSpec initialize] // manually calls +[QuickConfiguration initialize]. static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ qck_enumerateSubclasses([QuickConfiguration class], ^(__unsafe_unretained Class klass) { [[World sharedWorld] configure:^(Configuration *configuration) { [klass configure:configuration]; }]; }); [[World sharedWorld] finalizeConfiguration]; }); } } #pragma mark - Public Interface + (void)configure:(Configuration *)configuration { } @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/DSL/QCKDSL.h ================================================ #import @class ExampleMetadata; /** Provides a hook for Quick to be configured before any examples are run. Within this scope, override the +[QuickConfiguration configure:] method to set properties on a configuration object to customize Quick behavior. For details, see the documentation for Configuraiton.swift. @param name The name of the configuration class. Like any Objective-C class name, this must be unique to the current runtime environment. */ #define QuickConfigurationBegin(name) \ @interface name : QuickConfiguration; @end \ @implementation name \ /** Marks the end of a Quick configuration. Make sure you put this after `QuickConfigurationBegin`. */ #define QuickConfigurationEnd \ @end \ /** Defines a new QuickSpec. Define examples and example groups within the space between this and `QuickSpecEnd`. @param name The name of the spec class. Like any Objective-C class name, this must be unique to the current runtime environment. */ #define QuickSpecBegin(name) \ @interface name : QuickSpec; @end \ @implementation name \ - (void)spec { \ /** Marks the end of a QuickSpec. Make sure you put this after `QuickSpecBegin`. */ #define QuickSpecEnd \ } \ @end \ typedef NSDictionary *(^QCKDSLSharedExampleContext)(void); typedef void (^QCKDSLSharedExampleBlock)(QCKDSLSharedExampleContext); typedef void (^QCKDSLEmptyBlock)(void); typedef void (^QCKDSLExampleMetadataBlock)(ExampleMetadata *exampleMetadata); #define QUICK_EXPORT FOUNDATION_EXPORT QUICK_EXPORT void qck_beforeSuite(QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_afterSuite(QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_sharedExamples(NSString *name, QCKDSLSharedExampleBlock closure); QUICK_EXPORT void qck_describe(NSString *description, QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_context(NSString *description, QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_beforeEach(QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_beforeEachWithMetadata(QCKDSLExampleMetadataBlock closure); QUICK_EXPORT void qck_afterEach(QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_afterEachWithMetadata(QCKDSLExampleMetadataBlock closure); QUICK_EXPORT void qck_pending(NSString *description, QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_xdescribe(NSString *description, QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_xcontext(NSString *description, QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_fdescribe(NSString *description, QCKDSLEmptyBlock closure); QUICK_EXPORT void qck_fcontext(NSString *description, QCKDSLEmptyBlock closure); #ifndef QUICK_DISABLE_SHORT_SYNTAX /** Defines a closure to be run prior to any examples in the test suite. You may define an unlimited number of these closures, but there is no guarantee as to the order in which they're run. If the test suite crashes before the first example is run, this closure will not be executed. @param closure The closure to be run prior to any examples in the test suite. */ static inline void beforeSuite(QCKDSLEmptyBlock closure) { qck_beforeSuite(closure); } /** Defines a closure to be run after all of the examples in the test suite. You may define an unlimited number of these closures, but there is no guarantee as to the order in which they're run. If the test suite crashes before all examples are run, this closure will not be executed. @param closure The closure to be run after all of the examples in the test suite. */ static inline void afterSuite(QCKDSLEmptyBlock closure) { qck_afterSuite(closure); } /** Defines a group of shared examples. These examples can be re-used in several locations by using the `itBehavesLike` function. @param name The name of the shared example group. This must be unique across all shared example groups defined in a test suite. @param closure A closure containing the examples. This behaves just like an example group defined using `describe` or `context`--the closure may contain any number of `beforeEach` and `afterEach` closures, as well as any number of examples (defined using `it`). */ static inline void sharedExamples(NSString *name, QCKDSLSharedExampleBlock closure) { qck_sharedExamples(name, closure); } /** Defines an example group. Example groups are logical groupings of examples. Example groups can share setup and teardown code. @param description An arbitrary string describing the example group. @param closure A closure that can contain other examples. */ static inline void describe(NSString *description, QCKDSLEmptyBlock closure) { qck_describe(description, closure); } /** Defines an example group. Equivalent to `describe`. */ static inline void context(NSString *description, QCKDSLEmptyBlock closure) { qck_context(description, closure); } /** Defines a closure to be run prior to each example in the current example group. This closure is not run for pending or otherwise disabled examples. An example group may contain an unlimited number of beforeEach. They'll be run in the order they're defined, but you shouldn't rely on that behavior. @param closure The closure to be run prior to each example. */ static inline void beforeEach(QCKDSLEmptyBlock closure) { qck_beforeEach(closure); } /** Identical to QCKDSL.beforeEach, except the closure is provided with metadata on the example that the closure is being run prior to. */ static inline void beforeEachWithMetadata(QCKDSLExampleMetadataBlock closure) { qck_beforeEachWithMetadata(closure); } /** Defines a closure to be run after each example in the current example group. This closure is not run for pending or otherwise disabled examples. An example group may contain an unlimited number of afterEach. They'll be run in the order they're defined, but you shouldn't rely on that behavior. @param closure The closure to be run after each example. */ static inline void afterEach(QCKDSLEmptyBlock closure) { qck_afterEach(closure); } /** Identical to QCKDSL.afterEach, except the closure is provided with metadata on the example that the closure is being run after. */ static inline void afterEachWithMetadata(QCKDSLExampleMetadataBlock closure) { qck_afterEachWithMetadata(closure); } /** Defines an example or example group that should not be executed. Use `pending` to temporarily disable examples or groups that should not be run yet. @param description An arbitrary string describing the example or example group. @param closure A closure that will not be evaluated. */ static inline void pending(NSString *description, QCKDSLEmptyBlock closure) { qck_pending(description, closure); } /** Use this to quickly mark a `describe` block as pending. This disables all examples within the block. */ static inline void xdescribe(NSString *description, QCKDSLEmptyBlock closure) { qck_xdescribe(description, closure); } /** Use this to quickly mark a `context` block as pending. This disables all examples within the block. */ static inline void xcontext(NSString *description, QCKDSLEmptyBlock closure) { qck_xcontext(description, closure); } /** Use this to quickly focus a `describe` block, focusing the examples in the block. If any examples in the test suite are focused, only those examples are executed. This trumps any explicitly focused or unfocused examples within the block--they are all treated as focused. */ static inline void fdescribe(NSString *description, QCKDSLEmptyBlock closure) { qck_fdescribe(description, closure); } /** Use this to quickly focus a `context` block. Equivalent to `fdescribe`. */ static inline void fcontext(NSString *description, QCKDSLEmptyBlock closure) { qck_fcontext(description, closure); } #define it qck_it #define xit qck_xit #define fit qck_fit #define itBehavesLike qck_itBehavesLike #define xitBehavesLike qck_xitBehavesLike #define fitBehavesLike qck_fitBehavesLike #endif #define qck_it qck_it_builder(@{}, @(__FILE__), __LINE__) #define qck_xit qck_it_builder(@{Filter.pending: @YES}, @(__FILE__), __LINE__) #define qck_fit qck_it_builder(@{Filter.focused: @YES}, @(__FILE__), __LINE__) #define qck_itBehavesLike qck_itBehavesLike_builder(@{}, @(__FILE__), __LINE__) #define qck_xitBehavesLike qck_itBehavesLike_builder(@{Filter.pending: @YES}, @(__FILE__), __LINE__) #define qck_fitBehavesLike qck_itBehavesLike_builder(@{Filter.focused: @YES}, @(__FILE__), __LINE__) typedef void (^QCKItBlock)(NSString *description, QCKDSLEmptyBlock closure); typedef void (^QCKItBehavesLikeBlock)(NSString *description, QCKDSLSharedExampleContext context); QUICK_EXPORT QCKItBlock qck_it_builder(NSDictionary *flags, NSString *file, NSUInteger line); QUICK_EXPORT QCKItBehavesLikeBlock qck_itBehavesLike_builder(NSDictionary *flags, NSString *file, NSUInteger line); ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/DSL/QCKDSL.m ================================================ #import "QCKDSL.h" #import "World.h" #import "World+DSL.h" void qck_beforeSuite(QCKDSLEmptyBlock closure) { [[World sharedWorld] beforeSuite:closure]; } void qck_afterSuite(QCKDSLEmptyBlock closure) { [[World sharedWorld] afterSuite:closure]; } void qck_sharedExamples(NSString *name, QCKDSLSharedExampleBlock closure) { [[World sharedWorld] sharedExamples:name closure:closure]; } void qck_describe(NSString *description, QCKDSLEmptyBlock closure) { [[World sharedWorld] describe:description flags:@{} closure:closure]; } void qck_context(NSString *description, QCKDSLEmptyBlock closure) { qck_describe(description, closure); } void qck_beforeEach(QCKDSLEmptyBlock closure) { [[World sharedWorld] beforeEach:closure]; } void qck_beforeEachWithMetadata(QCKDSLExampleMetadataBlock closure) { [[World sharedWorld] beforeEachWithMetadata:closure]; } void qck_afterEach(QCKDSLEmptyBlock closure) { [[World sharedWorld] afterEach:closure]; } void qck_afterEachWithMetadata(QCKDSLExampleMetadataBlock closure) { [[World sharedWorld] afterEachWithMetadata:closure]; } QCKItBlock qck_it_builder(NSDictionary *flags, NSString *file, NSUInteger line) { return ^(NSString *description, QCKDSLEmptyBlock closure) { [[World sharedWorld] itWithDescription:description flags:flags file:file line:line closure:closure]; }; } QCKItBehavesLikeBlock qck_itBehavesLike_builder(NSDictionary *flags, NSString *file, NSUInteger line) { return ^(NSString *name, QCKDSLSharedExampleContext context) { [[World sharedWorld] itBehavesLikeSharedExampleNamed:name sharedExampleContext:context flags:flags file:file line:line]; }; } void qck_pending(NSString *description, QCKDSLEmptyBlock closure) { [[World sharedWorld] pending:description closure:closure]; } void qck_xdescribe(NSString *description, QCKDSLEmptyBlock closure) { [[World sharedWorld] xdescribe:description flags:@{} closure:closure]; } void qck_xcontext(NSString *description, QCKDSLEmptyBlock closure) { qck_xdescribe(description, closure); } void qck_fdescribe(NSString *description, QCKDSLEmptyBlock closure) { [[World sharedWorld] fdescribe:description flags:@{} closure:closure]; } void qck_fcontext(NSString *description, QCKDSLEmptyBlock closure) { qck_fdescribe(description, closure); } ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/DSL/World+DSL.h ================================================ #import @interface World (SWIFT_EXTENSION(Quick)) - (void)beforeSuite:(void (^ __nonnull)(void))closure; - (void)afterSuite:(void (^ __nonnull)(void))closure; - (void)sharedExamples:(NSString * __nonnull)name closure:(void (^ __nonnull)(NSDictionary * __nonnull (^ __nonnull)(void)))closure; - (void)describe:(NSString * __nonnull)description flags:(NSDictionary * __nonnull)flags closure:(void (^ __nonnull)(void))closure; - (void)context:(NSString * __nonnull)description flags:(NSDictionary * __nonnull)flags closure:(void (^ __nonnull)(void))closure; - (void)fdescribe:(NSString * __nonnull)description flags:(NSDictionary * __nonnull)flags closure:(void (^ __nonnull)(void))closure; - (void)xdescribe:(NSString * __nonnull)description flags:(NSDictionary * __nonnull)flags closure:(void (^ __nonnull)(void))closure; - (void)beforeEach:(void (^ __nonnull)(void))closure; - (void)beforeEachWithMetadata:(void (^ __nonnull)(ExampleMetadata * __nonnull))closure; - (void)afterEach:(void (^ __nonnull)(void))closure; - (void)afterEachWithMetadata:(void (^ __nonnull)(ExampleMetadata * __nonnull))closure; - (void)itWithDescription:(NSString * __nonnull)description flags:(NSDictionary * __nonnull)flags file:(NSString * __nonnull)file line:(NSUInteger)line closure:(void (^ __nonnull)(void))closure; - (void)fitWithDescription:(NSString * __nonnull)description flags:(NSDictionary * __nonnull)flags file:(NSString * __nonnull)file line:(NSUInteger)line closure:(void (^ __nonnull)(void))closure; - (void)xitWithDescription:(NSString * __nonnull)description flags:(NSDictionary * __nonnull)flags file:(NSString * __nonnull)file line:(NSUInteger)line closure:(void (^ __nonnull)(void))closure; - (void)itBehavesLikeSharedExampleNamed:(NSString * __nonnull)name sharedExampleContext:(NSDictionary * __nonnull (^ __nonnull)(void))sharedExampleContext flags:(NSDictionary * __nonnull)flags file:(NSString * __nonnull)file line:(NSUInteger)line; - (void)pending:(NSString * __nonnull)description closure:(void (^ __nonnull)(void))closure; @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/NSString+QCKSelectorName.h ================================================ #import /** QuickSpec converts example names into test methods. Those test methods need valid selector names, which means no whitespace, control characters, etc. This category gives NSString objects an easy way to replace those illegal characters with underscores. */ @interface NSString (QCKSelectorName) /** Returns a string with underscores in place of all characters that cannot be included in a selector (SEL) name. */ @property (nonatomic, readonly) NSString *qck_selectorName; @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/NSString+QCKSelectorName.m ================================================ #import "NSString+QCKSelectorName.h" @implementation NSString (QCKSelectorName) - (NSString *)qck_selectorName { static NSMutableCharacterSet *invalidCharacters = nil; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ invalidCharacters = [NSMutableCharacterSet new]; NSCharacterSet *whitespaceCharacterSet = [NSCharacterSet whitespaceCharacterSet]; NSCharacterSet *newlineCharacterSet = [NSCharacterSet newlineCharacterSet]; NSCharacterSet *illegalCharacterSet = [NSCharacterSet illegalCharacterSet]; NSCharacterSet *controlCharacterSet = [NSCharacterSet controlCharacterSet]; NSCharacterSet *punctuationCharacterSet = [NSCharacterSet punctuationCharacterSet]; NSCharacterSet *nonBaseCharacterSet = [NSCharacterSet nonBaseCharacterSet]; NSCharacterSet *symbolCharacterSet = [NSCharacterSet symbolCharacterSet]; [invalidCharacters formUnionWithCharacterSet:whitespaceCharacterSet]; [invalidCharacters formUnionWithCharacterSet:newlineCharacterSet]; [invalidCharacters formUnionWithCharacterSet:illegalCharacterSet]; [invalidCharacters formUnionWithCharacterSet:controlCharacterSet]; [invalidCharacters formUnionWithCharacterSet:punctuationCharacterSet]; [invalidCharacters formUnionWithCharacterSet:nonBaseCharacterSet]; [invalidCharacters formUnionWithCharacterSet:symbolCharacterSet]; }); NSArray *validComponents = [self componentsSeparatedByCharactersInSet:invalidCharacters]; NSString *result = [validComponents componentsJoinedByString:@"_"]; return ([result length] == 0 ? @"_" : result); } @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/Quick.h ================================================ #import //! Project version number for Quick. FOUNDATION_EXPORT double QuickVersionNumber; //! Project version string for Quick. FOUNDATION_EXPORT const unsigned char QuickVersionString[]; #import "QuickSpec.h" #import "QCKDSL.h" #import "QuickConfiguration.h" ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/QuickSpec.h ================================================ #import /** QuickSpec is a base class all specs written in Quick inherit from. They need to inherit from QuickSpec, a subclass of XCTestCase, in order to be discovered by the XCTest framework. XCTest automatically compiles a list of XCTestCase subclasses included in the test target. It iterates over each class in that list, and creates a new instance of that class for each test method. It then creates an "invocation" to execute that test method. The invocation is an instance of NSInvocation, which represents a single message send in Objective-C. The invocation is set on the XCTestCase instance, and the test is run. Most of the code in QuickSpec is dedicated to hooking into XCTest events. First, when the spec is first loaded and before it is sent any messages, the +[NSObject initialize] method is called. QuickSpec overrides this method to call +[QuickSpec spec]. This builds the example group stacks and registers them with Quick.World, a global register of examples. Then, XCTest queries QuickSpec for a list of test methods. Normally, XCTest automatically finds all methods whose selectors begin with the string "test". However, QuickSpec overrides this default behavior by implementing the +[XCTestCase testInvocations] method. This method iterates over each example registered in Quick.World, defines a new method for that example, and returns an invocation to call that method to XCTest. Those invocations are the tests that are run by XCTest. Their selector names are displayed in the Xcode test navigation bar. */ @interface QuickSpec : XCTestCase /** Override this method in your spec to define a set of example groups and examples. @code override func spec() { describe("winter") { it("is coming") { // ... } } } @endcode See DSL.swift for more information on what syntax is available. */ - (void)spec; @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/QuickSpec.m ================================================ #import "QuickSpec.h" #import "QuickConfiguration.h" #import "NSString+QCKSelectorName.h" #import "World.h" #import static QuickSpec *currentSpec = nil; const void * const QCKExampleKey = &QCKExampleKey; @interface QuickSpec () @property (nonatomic, strong) Example *example; @end @implementation QuickSpec #pragma mark - XCTestCase Overrides /** The runtime sends initialize to each class in a program just before the class, or any class that inherits from it, is sent its first message from within the program. QuickSpec hooks into this event to compile the example groups for this spec subclass. If an exception occurs when compiling the examples, report it to the user. Chances are they included an expectation outside of a "it", "describe", or "context" block. */ + (void)initialize { [QuickConfiguration initialize]; World *world = [World sharedWorld]; [world performWithCurrentExampleGroup:[world rootExampleGroupForSpecClass:self] closure:^{ QuickSpec *spec = [self new]; @try { [spec spec]; } @catch (NSException *exception) { [NSException raise:NSInternalInconsistencyException format:@"An exception occurred when building Quick's example groups.\n" @"Some possible reasons this might happen include:\n\n" @"- An 'expect(...).to' expectation was evaluated outside of " @"an 'it', 'context', or 'describe' block\n" @"- 'sharedExamples' was called twice with the same name\n" @"- 'itBehavesLike' was called with a name that is not registered as a shared example\n\n" @"Here's the original exception: '%@', reason: '%@', userInfo: '%@'", exception.name, exception.reason, exception.userInfo]; } [self testInvocations]; }]; } /** Invocations for each test method in the test case. QuickSpec overrides this method to define a new method for each example defined in +[QuickSpec spec]. @return An array of invocations that execute the newly defined example methods. */ + (NSArray *)testInvocations { NSArray *examples = [[World sharedWorld] examplesForSpecClass:[self class]]; NSMutableArray *invocations = [NSMutableArray arrayWithCapacity:[examples count]]; NSMutableSet *selectorNames = [NSMutableSet set]; for (Example *example in examples) { SEL selector = [self addInstanceMethodForExample:example classSelectorNames:selectorNames]; NSInvocation *invocation = [self invocationForInstanceMethodWithSelector:selector example:example]; [invocations addObject:invocation]; } return invocations; } /** XCTest sets the invocation for the current test case instance using this setter. QuickSpec hooks into this event to give the test case a reference to the current example. It will need this reference to correctly report its name to XCTest. */ - (void)setInvocation:(NSInvocation *)invocation { self.example = objc_getAssociatedObject(invocation, QCKExampleKey); [super setInvocation:invocation]; } #pragma mark - Public Interface - (void)spec { } #pragma mark - Internal Methods /** QuickSpec uses this method to dynamically define a new instance method for the given example. The instance method runs the example, catching any exceptions. The exceptions are then reported as test failures. In order to report the correct file and line number, examples must raise exceptions containing following keys in their userInfo: - "SenTestFilenameKey": A String representing the file name - "SenTestLineNumberKey": An Int representing the line number These keys used to be used by SenTestingKit, and are still used by some testing tools in the wild. See: https://github.com/Quick/Quick/pull/41 @return The selector of the newly defined instance method. */ + (SEL)addInstanceMethodForExample:(Example *)example classSelectorNames:(NSMutableSet *)selectorNames { IMP implementation = imp_implementationWithBlock(^(QuickSpec *self){ currentSpec = self; [example run]; }); NSCharacterSet *characterSet = [NSCharacterSet alphanumericCharacterSet]; NSMutableString *sanitizedFileName = [NSMutableString string]; for (NSUInteger i = 0; i < example.callsite.file.length; i++) { unichar ch = [example.callsite.file characterAtIndex:i]; if ([characterSet characterIsMember:ch]) { [sanitizedFileName appendFormat:@"%c", ch]; } } const char *types = [[NSString stringWithFormat:@"%s%s%s", @encode(id), @encode(id), @encode(SEL)] UTF8String]; NSString *originalName = example.name.qck_selectorName; NSString *selectorName = originalName; NSUInteger i = 2; while ([selectorNames containsObject:selectorName]) { selectorName = [NSString stringWithFormat:@"%@_%tu", originalName, i++]; } [selectorNames addObject:selectorName]; SEL selector = NSSelectorFromString(selectorName); class_addMethod(self, selector, implementation, types); return selector; } + (NSInvocation *)invocationForInstanceMethodWithSelector:(SEL)selector example:(Example *)example { NSMethodSignature *signature = [self instanceMethodSignatureForSelector:selector]; NSInvocation *invocation = [NSInvocation invocationWithMethodSignature:signature]; invocation.selector = selector; objc_setAssociatedObject(invocation, QCKExampleKey, example, OBJC_ASSOCIATION_RETAIN_NONATOMIC); return invocation; } /** This method is used to record failures, whether they represent example expectations that were not met, or exceptions raised during test setup and teardown. By default, the failure will be reported as an XCTest failure, and the example will be highlighted in Xcode. */ - (void)recordFailureWithDescription:(NSString *)description inFile:(NSString *)filePath atLine:(NSUInteger)lineNumber expected:(BOOL)expected { if (self.example.isSharedExample) { filePath = self.example.callsite.file; lineNumber = self.example.callsite.line; } [currentSpec.testRun recordFailureWithDescription:description inFile:filePath atLine:lineNumber expected:expected]; } @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/World.h ================================================ #import @class ExampleGroup; @class ExampleMetadata; SWIFT_CLASS("_TtC5Quick5World") @interface World @property (nonatomic) ExampleGroup * __nullable currentExampleGroup; @property (nonatomic) ExampleMetadata * __nullable currentExampleMetadata; @property (nonatomic) BOOL isRunningAdditionalSuites; + (World * __nonnull)sharedWorld; - (void)configure:(void (^ __nonnull)(Configuration * __nonnull))closure; - (void)finalizeConfiguration; - (ExampleGroup * __nonnull)rootExampleGroupForSpecClass:(Class __nonnull)cls; - (NSArray * __nonnull)examplesForSpecClass:(Class __nonnull)specClass; - (void)performWithCurrentExampleGroup:(ExampleGroup * __nonnull)group closure:(void (^ __nonnull)(void))closure; @end ================================================ FILE: Example/Pods/Quick/Sources/QuickObjectiveC/XCTestSuite+QuickTestSuiteBuilder.m ================================================ #import #import #import @interface XCTestSuite (QuickTestSuiteBuilder) @end @implementation XCTestSuite (QuickTestSuiteBuilder) /** In order to ensure we can correctly build dynamic test suites, we need to replace some of the default test suite constructors. */ + (void)load { Method testCaseWithName = class_getClassMethod(self, @selector(testSuiteForTestCaseWithName:)); Method hooked_testCaseWithName = class_getClassMethod(self, @selector(qck_hooked_testSuiteForTestCaseWithName:)); method_exchangeImplementations(testCaseWithName, hooked_testCaseWithName); } /** The `+testSuiteForTestCaseWithName:` method is called when a specific test case class is run from the Xcode test navigator. If the built test suite is `nil`, Xcode will not run any tests for that test case. Given if the following test case class is run from the Xcode test navigator: FooSpec testFoo testBar XCTest will invoke this once per test case, with test case names following this format: FooSpec/testFoo FooSpec/testBar */ + (nullable instancetype)qck_hooked_testSuiteForTestCaseWithName:(nonnull NSString *)name { return [QuickTestSuite selectedTestSuiteForTestCaseWithName:name]; } @end ================================================ FILE: Example/Pods/Reflection/LICENSE ================================================ The MIT License (MIT) Copyright (c) 2016 Brad Hilton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: Example/Pods/Reflection/README.md ================================================ # Reflection [![Swift][swift-badge]][swift-url] [![License][mit-badge]][mit-url] [![Slack][slack-badge]][slack-url] [![Travis][travis-badge]][travis-url] [![Codecov][codecov-badge]][codecov-url] [![Codebeat][codebeat-badge]][codebeat-url] **Reflection** provides an API for advanced reflection at runtime including dynamic construction of types. ## Usage ```swift import Reflection struct Person { var firstName: String var lastName: String var age: Int } // Reflects the instance properties of type `Person` let properties = try properties(Person) var person = Person(firstName: "John", lastName: "Smith", age: 35) // Retrieves the value of `person.firstName` let firstName: String = try get("firstName", from: person) // Sets the value of `person.age` try set(36, key: "age", for: &person) // Creates a `Person` from a dictionary let friend: Person = try construct(dictionary: ["firstName" : "Sarah", "lastName" : "Gates", "age" : 28]) ``` ## Installation ```swift import PackageDescription let package = Package( dependencies: [ .Package(url: "https://github.com/Zewo/Reflection.git", majorVersion: 0, minor: 14), ] ) ``` ## Advanced Usage ```swift // `Reflection` can be extended for higher-level packages to do mapping and serializing. // Here is a simple `Mappable` protocol that allows deserializing of arbitrary nested structures. import Reflection typealias MappableDictionary = [String : Any] enum Error : ErrorProtocol { case missingRequiredValue(key: String) } protocol Mappable { init(dictionary: MappableDictionary) throws } extension Mappable { init(dictionary: MappableDictionary) throws { self = try construct { property in if let value = dictionary[property.key] { if let type = property.type as? Mappable.Type, let value = value as? MappableDictionary { return try type.init(dictionary: value) } else { return value } } else { throw Error.missingRequiredValue(key: property.key) } } } } struct Person : Mappable { var firstName: String var lastName: String var age: Int var phoneNumber: PhoneNumber } struct PhoneNumber : Mappable { var number: String var type: String } let dictionary = [ "firstName" : "Jane", "lastName" : "Miller", "age" : 54, "phoneNumber" : [ "number" : "924-555-0294", "type" : "work" ] as MappableDictionary ] as MappableDictionary let person = try Person(dictionary: dictionary) ``` ## Support If you need any help you can join our [Slack](http://slack.zewo.io) and go to the **#help** channel. Or you can create a Github [issue](https://github.com/Zewo/Zewo/issues/new) in our main repository. When stating your issue be sure to add enough details, specify what module is causing the problem and reproduction steps. ## Community [![Slack][slack-image]][slack-url] The entire Zewo code base is licensed under MIT. By contributing to Zewo you are contributing to an open and engaged community of brilliant Swift programmers. Join us on [Slack](http://slack.zewo.io) to get to know us! ## License This project is released under the MIT license. See [LICENSE](LICENSE) for details. [swift-badge]: https://img.shields.io/badge/Swift-3.0-orange.svg?style=flat [swift-url]: https://swift.org [mit-badge]: https://img.shields.io/badge/License-MIT-blue.svg?style=flat [mit-url]: https://tldrlegal.com/license/mit-license [slack-image]: http://s13.postimg.org/ybwy92ktf/Slack.png [slack-badge]: https://zewo-slackin.herokuapp.com/badge.svg [slack-url]: http://slack.zewo.io [travis-badge]: https://travis-ci.org/Zewo/Reflection.svg?branch=master [travis-url]: https://travis-ci.org/Zewo/Reflection [codecov-badge]: https://codecov.io/gh/Zewo/Reflection/branch/master/graph/badge.svg [codecov-url]: https://codecov.io/gh/Zewo/Reflection [codebeat-badge]: https://codebeat.co/badges/85f3c10b-6574-4956-8c58-bb6ad3ea1268 [codebeat-url]: https://codebeat.co/projects/github-com-zewo-reflection ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Advance.swift ================================================ // TODO: Remove uses of advance() extension Strideable { mutating func advance() { self = advanced(by: 1) } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Any+Extensions.swift ================================================ // // Any+Extensions.swift // Reflection // // Created by Bradley Hilton on 10/17/16. // // protocol AnyExtensions {} extension AnyExtensions { static func construct(constructor: (Property.Description) throws -> Any) throws -> Any { return try Reflection.construct(self, constructor: constructor) } static func construct(dictionary: [String: Any]) throws -> Any { return try Reflection.construct(self, dictionary: dictionary) } static func isValueTypeOrSubtype(_ value: Any) -> Bool { return value is Self } static func value(from storage: UnsafeRawPointer) -> Any { return storage.assumingMemoryBound(to: self).pointee } static func write(_ value: Any, to storage: UnsafeMutableRawPointer) throws { guard let this = value as? Self else { throw ReflectionError.valueIsNotType(value: value, type: self) } storage.assumingMemoryBound(to: self).initialize(to: this) } } func extensions(of type: Any.Type) -> AnyExtensions.Type { struct Extensions : AnyExtensions {} var extensions: AnyExtensions.Type = Extensions.self withUnsafePointer(to: &extensions) { pointer in UnsafeMutableRawPointer(mutating: pointer).assumingMemoryBound(to: Any.Type.self).pointee = type } return extensions } func extensions(of value: Any) -> AnyExtensions { struct Extensions : AnyExtensions {} var extensions: AnyExtensions = Extensions() withUnsafePointer(to: &extensions) { pointer in UnsafeMutableRawPointer(mutating: pointer).assumingMemoryBound(to: Any.self).pointee = value } return extensions } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Array+Extensions.swift ================================================ protocol UTF8Initializable { init?(validatingUTF8: UnsafePointer) } extension String : UTF8Initializable {} extension Array where Element : UTF8Initializable { init(utf8Strings: UnsafePointer) { var strings = [Element]() var pointer = utf8Strings while let string = Element(validatingUTF8: pointer) { strings.append(string) while pointer.pointee != 0 { pointer.advance() } pointer.advance() guard pointer.pointee != 0 else { break } } self = strings } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Construct.swift ================================================ /// Create a struct with a constructor method. Return a value of `property.type` for each property. public func construct(_ type: T.Type = T.self, constructor: (Property.Description) throws -> Any) throws -> T { if Metadata(type: T.self)?.kind == .struct { return try constructValueType(constructor) } else { throw ReflectionError.notStruct(type: T.self) } } /// Create a struct with a constructor method. Return a value of `property.type` for each property. public func construct(_ type: Any.Type, constructor: (Property.Description) throws -> Any) throws -> Any { return try extensions(of: type).construct(constructor: constructor) } private func constructValueType(_ constructor: (Property.Description) throws -> Any) throws -> T { guard Metadata(type: T.self)?.kind == .struct else { throw ReflectionError.notStruct(type: T.self) } let pointer = UnsafeMutablePointer.allocate(capacity: 1) defer { pointer.deallocate(capacity: 1) } var values: [Any] = [] try constructType(storage: UnsafeMutableRawPointer(pointer), values: &values, properties: properties(T.self), constructor: constructor) return pointer.move() } private func constructType(storage: UnsafeMutableRawPointer, values: inout [Any], properties: [Property.Description], constructor: (Property.Description) throws -> Any) throws { var errors = [Error]() for property in properties { do { let value = try constructor(property) values.append(value) try property.write(value, to: storage) } catch { errors.append(error) } } if errors.count > 0 { throw ConstructionErrors(errors: errors) } } /// Create a struct from a dictionary. public func construct(_ type: T.Type = T.self, dictionary: [String: Any]) throws -> T { return try construct(constructor: constructorForDictionary(dictionary)) } /// Create a struct from a dictionary. public func construct(_ type: Any.Type, dictionary: [String: Any]) throws -> Any { return try extensions(of: type).construct(dictionary: dictionary) } private func constructorForDictionary(_ dictionary: [String: Any]) -> (Property.Description) throws -> Any { return { property in if let value = dictionary[property.key] { return value } else if let expressibleByNilLiteral = property.type as? ExpressibleByNilLiteral.Type { return expressibleByNilLiteral.init(nilLiteral: ()) } else { throw ReflectionError.requiredValueMissing(key: property.key) } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Get.swift ================================================ /// Get value for key from instance public func get(_ key: String, from instance: Any) throws -> Any { guard let value = try properties(instance).first(where: { $0.key == key })?.value else { throw ReflectionError.instanceHasNoKey(type: type(of: instance), key: key) } return value } /// Get value for key from instance as type `T` public func get(_ key: String, from instance: Any) throws -> T { let any: Any = try get(key, from: instance) guard let value = any as? T else { throw ReflectionError.valueIsNotType(value: any, type: T.self) } return value } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Identity.swift ================================================ /// Tests if `value` is `type` or a subclass of `type` public func value(_ value: Any, is type: Any.Type) -> Bool { return extensions(of: type).isValueTypeOrSubtype(value) } /// Tests equality of any two existential types public func ==(lhs: Any.Type, rhs: Any.Type) -> Bool { return Metadata(type: lhs) == Metadata(type: rhs) } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/MemoryProperties.swift ================================================ public func alignof(_ x: Any.Type) -> Int { return Metadata(type: x).valueWitnessTable.align } public func sizeof(_ x: Any.Type) -> Int { return Metadata(type: x).valueWitnessTable.size } public func strideof(_ x: Any.Type) -> Int { return Metadata(type: x).valueWitnessTable.stride } public func alignofValue(_ x: Any) -> Int { return alignof(type(of: x)) } public func sizeofValue(_ x: Any) -> Int { return sizeof(type(of: x)) } public func strideofValue(_ x: Any) -> Int { return strideof(type(of: x)) } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Metadata+Class.swift ================================================ extension Metadata { struct Class : NominalType { static let kind: Kind? = .class var pointer: UnsafePointer<_Metadata._Class> var nominalTypeDescriptorOffsetLocation: Int { return is64BitPlatform ? 8 : 11 } var superclass: Class? { guard let superclass = pointer.pointee.superclass else { return nil } return Metadata.Class(type: superclass) } } } extension _Metadata { struct _Class { var kind: Int var superclass: Any.Type? } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Metadata+Kind.swift ================================================ // https://github.com/apple/swift/blob/swift-3.0-branch/include/swift/ABI/MetadataKind.def extension Metadata { static let kind: Kind? = nil enum Kind { case `struct` case `enum` case optional case opaque case tuple case function case existential case metatype case objCClassWrapper case existentialMetatype case foreignClass case heapLocalVariable case heapGenericLocalVariable case errorObject case `class` init(flag: Int) { switch flag { case 1: self = .struct case 2: self = .enum case 3: self = .optional case 8: self = .opaque case 9: self = .tuple case 10: self = .function case 12: self = .existential case 13: self = .metatype case 14: self = .objCClassWrapper case 15: self = .existentialMetatype case 16: self = .foreignClass case 64: self = .heapLocalVariable case 65: self = .heapGenericLocalVariable case 128: self = .errorObject default: self = .class } } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Metadata+Struct.swift ================================================ extension Metadata { struct Struct : NominalType { static let kind: Kind? = .struct var pointer: UnsafePointer<_Metadata._Struct> var nominalTypeDescriptorOffsetLocation: Int { return 1 } } } extension _Metadata { struct _Struct { var kind: Int var nominalTypeDescriptorOffset: Int var parent: Metadata? } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Metadata+Tuple.swift ================================================ extension Metadata { struct Tuple : MetadataType { static let kind: Kind? = .tuple var pointer: UnsafePointer var labels: [String?] { guard var pointer = UnsafePointer(bitPattern: pointer[2]) else { return [] } var labels = [String?]() var string = "" while pointer.pointee != 0 { guard pointer.pointee != 32 else { labels.append(string.isEmpty ? nil : string) string = "" pointer.advance() continue } string.append(String(UnicodeScalar(UInt8(bitPattern: pointer.pointee)))) pointer.advance() } return labels } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Metadata.swift ================================================ struct Metadata : MetadataType { var pointer: UnsafePointer init(type: Any.Type) { self.init(pointer: unsafeBitCast(type, to: UnsafePointer.self)) } } struct _Metadata {} var is64BitPlatform: Bool { return sizeof(Int.self) == sizeof(Int64.self) } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/MetadataType.swift ================================================ protocol MetadataType : PointerType { static var kind: Metadata.Kind? { get } } extension MetadataType { var valueWitnessTable: ValueWitnessTable { return ValueWitnessTable(pointer: UnsafePointer>(pointer).advanced(by: -1).pointee) } var kind: Metadata.Kind { return Metadata.Kind(flag: UnsafePointer(pointer).pointee) } init?(type: Any.Type) { self.init(pointer: unsafeBitCast(type, to: UnsafePointer.self)) if let kind = type(of: self).kind, kind != self.kind { return nil } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/NominalType.swift ================================================ protocol NominalType : MetadataType { var nominalTypeDescriptorOffsetLocation: Int { get } } extension NominalType { var nominalTypeDescriptor: NominalTypeDescriptor { let pointer = UnsafePointer(self.pointer) let base = pointer.advanced(by: nominalTypeDescriptorOffsetLocation) return NominalTypeDescriptor(pointer: relativePointer(base: base, offset: base.pointee)) } var fieldTypes: [Any.Type]? { guard let function = nominalTypeDescriptor.fieldTypesAccessor else { return nil } return (0..(pointer)).advanced(by: $0).pointee, to: Any.Type.self) } } var fieldOffsets: [Int]? { let vectorOffset = nominalTypeDescriptor.fieldOffsetVector guard vectorOffset != 0 else { return nil } return (0..(pointer)[vectorOffset + $0] } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/NominalTypeDescriptor.swift ================================================ struct NominalTypeDescriptor : PointerType { var pointer: UnsafePointer<_NominalTypeDescriptor> var mangledName: String { return String(cString: relativePointer(base: pointer, offset: pointer.pointee.mangledName) as UnsafePointer) } var numberOfFields: Int { return Int(pointer.pointee.numberOfFields) } var fieldOffsetVector: Int { return Int(pointer.pointee.fieldOffsetVector) } var fieldNames: [String] { let p = UnsafePointer(self.pointer) return Array(utf8Strings: relativePointer(base: p.advanced(by: 3), offset: self.pointer.pointee.fieldNames)) } typealias FieldsTypeAccessor = @convention(c) (UnsafePointer) -> UnsafePointer> var fieldTypesAccessor: FieldsTypeAccessor? { let offset = pointer.pointee.fieldTypesAccessor guard offset != 0 else { return nil } let p = UnsafePointer(self.pointer) let offsetPointer: UnsafePointer = relativePointer(base: p.advanced(by: 4), offset: offset) return unsafeBitCast(offsetPointer, to: FieldsTypeAccessor.self) } } struct _NominalTypeDescriptor { var mangledName: Int32 var numberOfFields: Int32 var fieldOffsetVector: Int32 var fieldNames: Int32 var fieldTypesAccessor: Int32 } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/PointerType.swift ================================================ protocol PointerType : Equatable { associatedtype Pointee var pointer: UnsafePointer { get set } } extension PointerType { init(pointer: UnsafePointer) { func cast(_ value: T) -> U { return unsafeBitCast(value, to: U.self) } self = cast(UnsafePointer(pointer)) } } func ==(lhs: T, rhs: T) -> Bool { return lhs.pointer == rhs.pointer } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Properties.swift ================================================ private struct HashedType : Hashable { let hashValue: Int init(_ type: Any.Type) { hashValue = unsafeBitCast(type, to: Int.self) } } private func == (lhs: HashedType, rhs: HashedType) -> Bool { return lhs.hashValue == rhs.hashValue } private var cachedProperties = [HashedType : Array]() /// An instance property public struct Property { public let key: String public let value: Any /// An instance property description public struct Description { public let key: String public let type: Any.Type let offset: Int func write(_ value: Any, to storage: UnsafeMutableRawPointer) throws { return try extensions(of: type).write(value, to: storage.advanced(by: offset)) } } } /// Retrieve properties for `instance` public func properties(_ instance: Any) throws -> [Property] { let props = try properties(type(of: instance)) var copy = extensions(of: instance) let storage = copy.storage() return props.map { nextProperty(description: $0, storage: storage) } } private func nextProperty(description: Property.Description, storage: UnsafeRawPointer) -> Property { return Property( key: description.key, value: extensions(of: description.type).value(from: storage.advanced(by: description.offset)) ) } /// Retrieve property descriptions for `type` public func properties(_ type: Any.Type) throws -> [Property.Description] { let hashedType = HashedType(type) if let properties = cachedProperties[hashedType] { return properties } else if let nominalType = Metadata.Struct(type: type) { return try fetchAndSaveProperties(nominalType: nominalType, hashedType: hashedType) } else if let nominalType = Metadata.Class(type: type) { return try fetchAndSaveProperties(nominalType: nominalType, hashedType: hashedType) } else { throw ReflectionError.notStruct(type: type) } } private func fetchAndSaveProperties(nominalType: T, hashedType: HashedType) throws -> [Property.Description] { let properties = try propertiesForNominalType(nominalType) cachedProperties[hashedType] = properties return properties } private func propertiesForNominalType(_ type: T) throws -> [Property.Description] { guard type.nominalTypeDescriptor.numberOfFields != 0 else { return [] } guard let fieldTypes = type.fieldTypes, let fieldOffsets = type.fieldOffsets else { throw ReflectionError.unexpected } let fieldNames = type.nominalTypeDescriptor.fieldNames return (0.. Bool { switch (lhs, rhs) { case (.notStruct(type: let lhs), .notStruct(type: let rhs)): return lhs == rhs case (.instanceHasNoKey(type: let lhsType, key: let lhsKey), .instanceHasNoKey(type: let rhsType, key: let rhsKey)): return lhsType == rhsType && lhsKey == rhsKey case (.requiredValueMissing(key: let lhs), .requiredValueMissing(key: let rhs)): return lhs == rhs case (.unexpected, .unexpected): return true default: return lhs.description == rhs.description } } public struct ConstructionErrors : Error, CustomStringConvertible { public let errors: [Error] public var description: String { return errors.reduce("Reflection Construction Errors:") { $0 + "\n\t\($1)" } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/RelativePointer.swift ================================================ func relativePointer(base: UnsafePointer, offset: U) -> UnsafePointer where U : Integer { return UnsafeRawPointer(base).advanced(by: Int(integer: offset)).assumingMemoryBound(to: V.self) } extension Int { fileprivate init(integer: T) { switch integer { case let value as Int: self = value case let value as Int32: self = Int(value) case let value as Int16: self = Int(value) case let value as Int8: self = Int(value) default: self = 0 } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Set.swift ================================================ /// Set value for key of an instance public func set(_ value: Any, key: String, for instance: inout Any) throws { try property(type: type(of: instance), key: key).write(value, to: mutableStorage(instance: &instance)) } /// Set value for key of an instance public func set(_ value: Any, key: String, for instance: AnyObject) throws { var copy: Any = instance try set(value, key: key, for: ©) } /// Set value for key of an instance public func set(_ value: Any, key: String, for instance: inout T) throws { try property(type: T.self, key: key).write(value, to: mutableStorage(instance: &instance)) } private func property(type: Any.Type, key: String) throws -> Property.Description { guard let property = try properties(type).first(where: { $0.key == key }) else { throw ReflectionError.instanceHasNoKey(type: type, key: key) } return property } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/Storage.swift ================================================ extension AnyExtensions { mutating func mutableStorage() -> UnsafeMutableRawPointer { return Reflection.mutableStorage(instance: &self) } mutating func storage() -> UnsafeRawPointer { return Reflection.storage(instance: &self) } } func mutableStorage(instance: inout T) -> UnsafeMutableRawPointer { return UnsafeMutableRawPointer(mutating: storage(instance: &instance)) } func storage(instance: inout T) -> UnsafeRawPointer { return withUnsafePointer(to: &instance) { pointer in if type(of: instance) is AnyClass { return UnsafeRawPointer(bitPattern: UnsafePointer(pointer).pointee)! } else { return UnsafeRawPointer(pointer) } } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/UnsafePointer+Extensions.swift ================================================ // // UnsafePointer+Extensions.swift // Reflection // // Created by Bradley Hilton on 10/29/16. // // extension UnsafePointer { init(_ pointer: UnsafePointer) { self = UnsafeRawPointer(pointer).assumingMemoryBound(to: Pointee.self) } } ================================================ FILE: Example/Pods/Reflection/Sources/Reflection/ValueWitnessTable.swift ================================================ // https://github.com/apple/swift/blob/master/lib/IRGen/ValueWitness.h struct ValueWitnessTable : PointerType { var pointer: UnsafePointer<_ValueWitnessTable> private var alignmentMask: Int { return 0x0FFFF } var size: Int { return pointer.pointee.size } var align: Int { return (pointer.pointee.align & alignmentMask) + 1 } var stride: Int { return pointer.pointee.stride } } struct _ValueWitnessTable { let destroyBuffer: Int let initializeBufferWithCopyOfBuffer: Int let projectBuffer: Int let deallocateBuffer: Int let destroy: Int let initializeBufferWithCopy: Int let initializeWithCopy: Int let assignWithCopy: Int let initializeBufferWithTake: Int let initializeWithTake: Int let assignWithTake: Int let allocateBuffer: Int let initializeBufferWithTakeOrBuffer: Int let destroyArray: Int let initializeArrayWithCopy: Int let initializeArrayWithTakeFrontToBack: Int let initializeArrayWithTakeBackToFront: Int let size: Int let align: Int let stride: Int } ================================================ FILE: Example/Pods/Target Support Files/Nimble/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 5.1.1 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/Nimble/Nimble-dummy.m ================================================ #import @interface PodsDummy_Nimble : NSObject @end @implementation PodsDummy_Nimble @end ================================================ FILE: Example/Pods/Target Support Files/Nimble/Nimble-prefix.pch ================================================ #ifdef __OBJC__ #import #endif ================================================ FILE: Example/Pods/Target Support Files/Nimble/Nimble-umbrella.h ================================================ #ifdef __OBJC__ #import #endif #import "CwlCatchException.h" #import "CwlCatchBadInstruction.h" #import "mach_excServer.h" #import "Nimble.h" #import "DSL.h" #import "NMBExceptionCapture.h" #import "NMBStringify.h" FOUNDATION_EXPORT double NimbleVersionNumber; FOUNDATION_EXPORT const unsigned char NimbleVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/Nimble/Nimble.modulemap ================================================ framework module Nimble { umbrella header "Nimble-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/Nimble/Nimble.xcconfig ================================================ CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/Nimble ENABLE_BITCODE = NO FRAMEWORK_SEARCH_PATHS = $(inherited) "$(PLATFORM_DIR)/Developer/Library/Frameworks" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" OTHER_LDFLAGS = -weak-lswiftXCTest -weak_framework "XCTest" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT} PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} SKIP_INSTALL = YES ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-OSX/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 1.1.0 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX-dummy.m ================================================ #import @interface PodsDummy_PersistentStorageSerializable_OSX : NSObject @end @implementation PodsDummy_PersistentStorageSerializable_OSX @end ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX-prefix.pch ================================================ #ifdef __OBJC__ #import #endif ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX-umbrella.h ================================================ #ifdef __OBJC__ #import #endif #import "SwiftTryCatch.h" FOUNDATION_EXPORT double PersistentStorageSerializableVersionNumber; FOUNDATION_EXPORT const unsigned char PersistentStorageSerializableVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX.modulemap ================================================ framework module PersistentStorageSerializable { umbrella header "PersistentStorageSerializable-OSX-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-OSX/PersistentStorageSerializable-OSX.xcconfig ================================================ CODE_SIGN_IDENTITY = CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-OSX FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/Reflection-OSX" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" OTHER_LDFLAGS = -framework "Foundation" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT} PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} SKIP_INSTALL = YES ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-iOS/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 1.1.0 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-dummy.m ================================================ #import @interface PodsDummy_PersistentStorageSerializable_iOS : NSObject @end @implementation PodsDummy_PersistentStorageSerializable_iOS @end ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-prefix.pch ================================================ #ifdef __OBJC__ #import #endif ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS-umbrella.h ================================================ #ifdef __OBJC__ #import #endif #import "SwiftTryCatch.h" FOUNDATION_EXPORT double PersistentStorageSerializableVersionNumber; FOUNDATION_EXPORT const unsigned char PersistentStorageSerializableVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS.modulemap ================================================ framework module PersistentStorageSerializable { umbrella header "PersistentStorageSerializable-iOS-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/PersistentStorageSerializable-iOS/PersistentStorageSerializable-iOS.xcconfig ================================================ CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" OTHER_LDFLAGS = -framework "Foundation" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT} PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} SKIP_INSTALL = YES ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 1.0.0 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-acknowledgements.markdown ================================================ # Acknowledgements This application makes use of the following third party libraries: ## PersistentStorageSerializable Copyright (c) 2017 IvanRublev Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ## Reflection The MIT License (MIT) Copyright (c) 2016 Brad Hilton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. Generated by CocoaPods - https://cocoapods.org ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-acknowledgements.plist ================================================ PreferenceSpecifiers FooterText This application makes use of the following third party libraries: Title Acknowledgements Type PSGroupSpecifier FooterText Copyright (c) 2017 IvanRublev <ivan@ivanrublev.me> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License MIT Title PersistentStorageSerializable Type PSGroupSpecifier FooterText The MIT License (MIT) Copyright (c) 2016 Brad Hilton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License MIT Title Reflection Type PSGroupSpecifier FooterText Generated by CocoaPods - https://cocoapods.org Title Type PSGroupSpecifier StringsTable Acknowledgements Title Acknowledgements ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-dummy.m ================================================ #import @interface PodsDummy_Pods_PersistentStorageSerializable_MacExample : NSObject @end @implementation PodsDummy_Pods_PersistentStorageSerializable_MacExample @end ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-frameworks.sh ================================================ #!/bin/sh set -e echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}" install_framework() { if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then local source="${BUILT_PRODUCTS_DIR}/$1" elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")" elif [ -r "$1" ]; then local source="$1" fi local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" if [ -L "${source}" ]; then echo "Symlinked..." source="$(readlink "${source}")" fi # use filter instead of exclude so missing patterns dont' throw errors echo "rsync -av --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\"" rsync -av --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}" local basename basename="$(basename -s .framework "$1")" binary="${destination}/${basename}.framework/${basename}" if ! [ -r "$binary" ]; then binary="${destination}/${basename}" fi # Strip invalid architectures so "fat" simulator / device frameworks work on device if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then strip_invalid_archs "$binary" fi # Resign the code if required by the build settings to avoid unstable apps code_sign_if_enabled "${destination}/$(basename "$1")" # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then local swift_runtime_libs swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) for lib in $swift_runtime_libs; do echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" code_sign_if_enabled "${destination}/${lib}" done fi } # Signs a framework with the provided identity code_sign_if_enabled() { if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then # Use the current code_sign_identitiy echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" echo "/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements \"$1\"" /usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements "$1" fi } # Strip invalid architectures strip_invalid_archs() { binary="$1" # Get architectures for current file archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | rev)" stripped="" for arch in $archs; do if ! [[ "${VALID_ARCHS}" == *"$arch"* ]]; then # Strip non-valid architectures in-place lipo -remove "$arch" -output "$binary" "$binary" || exit 1 stripped="$stripped $arch" fi done if [[ "$stripped" ]]; then echo "Stripped $binary of architectures:$stripped" fi } if [[ "$CONFIGURATION" == "Debug" ]]; then install_framework "$BUILT_PRODUCTS_DIR/PersistentStorageSerializable-OSX/PersistentStorageSerializable.framework" install_framework "$BUILT_PRODUCTS_DIR/Reflection-OSX/Reflection.framework" fi if [[ "$CONFIGURATION" == "Release" ]]; then install_framework "$BUILT_PRODUCTS_DIR/PersistentStorageSerializable-OSX/PersistentStorageSerializable.framework" install_framework "$BUILT_PRODUCTS_DIR/Reflection-OSX/Reflection.framework" fi ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-resources.sh ================================================ #!/bin/sh set -e mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt > "$RESOURCES_TO_COPY" XCASSET_FILES=() case "${TARGETED_DEVICE_FAMILY}" in 1,2) TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone" ;; 1) TARGET_DEVICE_ARGS="--target-device iphone" ;; 2) TARGET_DEVICE_ARGS="--target-device ipad" ;; *) TARGET_DEVICE_ARGS="--target-device mac" ;; esac install_resource() { if [[ "$1" = /* ]] ; then RESOURCE_PATH="$1" else RESOURCE_PATH="${PODS_ROOT}/$1" fi if [[ ! -e "$RESOURCE_PATH" ]] ; then cat << EOM error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script. EOM exit 1 fi case $RESOURCE_PATH in *.storyboard) echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} ;; *.xib) echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} ;; *.framework) echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" echo "rsync -av $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" rsync -av "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" ;; *.xcdatamodel) echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom" ;; *.xcdatamodeld) echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd" ;; *.xcmappingmodel) echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm" ;; *.xcassets) ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH" XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE") ;; *) echo "$RESOURCE_PATH" echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY" ;; esac } mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" fi rm -f "$RESOURCES_TO_COPY" if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ] then # Find all other xcassets (this unfortunately includes those of path pods and other targets). OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d) while read line; do if [[ $line != "${PODS_ROOT}*" ]]; then XCASSET_FILES+=("$line") fi done <<<"$OTHER_XCASSETS" printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" fi ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample-umbrella.h ================================================ #ifdef __OBJC__ #import #endif FOUNDATION_EXPORT double Pods_PersistentStorageSerializable_MacExampleVersionNumber; FOUNDATION_EXPORT const unsigned char Pods_PersistentStorageSerializable_MacExampleVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample.debug.xcconfig ================================================ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES CODE_SIGN_IDENTITY = EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-OSX" "$PODS_CONFIGURATION_BUILD_DIR/Reflection-OSX" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/../Frameworks' '@loader_path/Frameworks' OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-OSX/PersistentStorageSerializable.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Reflection-OSX/Reflection.framework/Headers" OTHER_LDFLAGS = $(inherited) -framework "PersistentStorageSerializable" -framework "Reflection" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT}/Pods ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample.modulemap ================================================ framework module Pods_PersistentStorageSerializable_MacExample { umbrella header "Pods-PersistentStorageSerializable_MacExample-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_MacExample/Pods-PersistentStorageSerializable_MacExample.release.xcconfig ================================================ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES CODE_SIGN_IDENTITY = EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-OSX" "$PODS_CONFIGURATION_BUILD_DIR/Reflection-OSX" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/../Frameworks' '@loader_path/Frameworks' OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-OSX/PersistentStorageSerializable.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Reflection-OSX/Reflection.framework/Headers" OTHER_LDFLAGS = $(inherited) -framework "PersistentStorageSerializable" -framework "Reflection" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT}/Pods ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 1.0.0 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-acknowledgements.markdown ================================================ # Acknowledgements This application makes use of the following third party libraries: ## PersistentStorageSerializable Copyright (c) 2017 IvanRublev Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ## Reflection The MIT License (MIT) Copyright (c) 2016 Brad Hilton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ## Nimble Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright 2014 Quick Team Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ## Quick Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright 2014, Quick Team Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. Generated by CocoaPods - https://cocoapods.org ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-acknowledgements.plist ================================================ PreferenceSpecifiers FooterText This application makes use of the following third party libraries: Title Acknowledgements Type PSGroupSpecifier FooterText Copyright (c) 2017 IvanRublev <ivan@ivanrublev.me> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License MIT Title PersistentStorageSerializable Type PSGroupSpecifier FooterText The MIT License (MIT) Copyright (c) 2016 Brad Hilton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License MIT Title Reflection Type PSGroupSpecifier FooterText Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright 2014 Quick Team Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. License Apache 2.0 Title Nimble Type PSGroupSpecifier FooterText Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright 2014, Quick Team Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. License Apache 2.0 Title Quick Type PSGroupSpecifier FooterText Generated by CocoaPods - https://cocoapods.org Title Type PSGroupSpecifier StringsTable Acknowledgements Title Acknowledgements ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-dummy.m ================================================ #import @interface PodsDummy_Pods_PersistentStorageSerializable_Tests : NSObject @end @implementation PodsDummy_Pods_PersistentStorageSerializable_Tests @end ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-frameworks.sh ================================================ #!/bin/sh set -e echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}" install_framework() { if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then local source="${BUILT_PRODUCTS_DIR}/$1" elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")" elif [ -r "$1" ]; then local source="$1" fi local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" if [ -L "${source}" ]; then echo "Symlinked..." source="$(readlink "${source}")" fi # use filter instead of exclude so missing patterns dont' throw errors echo "rsync -av --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\"" rsync -av --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}" local basename basename="$(basename -s .framework "$1")" binary="${destination}/${basename}.framework/${basename}" if ! [ -r "$binary" ]; then binary="${destination}/${basename}" fi # Strip invalid architectures so "fat" simulator / device frameworks work on device if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then strip_invalid_archs "$binary" fi # Resign the code if required by the build settings to avoid unstable apps code_sign_if_enabled "${destination}/$(basename "$1")" # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then local swift_runtime_libs swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) for lib in $swift_runtime_libs; do echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" code_sign_if_enabled "${destination}/${lib}" done fi } # Signs a framework with the provided identity code_sign_if_enabled() { if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then # Use the current code_sign_identitiy echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" echo "/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements \"$1\"" /usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements "$1" fi } # Strip invalid architectures strip_invalid_archs() { binary="$1" # Get architectures for current file archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | rev)" stripped="" for arch in $archs; do if ! [[ "${VALID_ARCHS}" == *"$arch"* ]]; then # Strip non-valid architectures in-place lipo -remove "$arch" -output "$binary" "$binary" || exit 1 stripped="$stripped $arch" fi done if [[ "$stripped" ]]; then echo "Stripped $binary of architectures:$stripped" fi } if [[ "$CONFIGURATION" == "Debug" ]]; then install_framework "$BUILT_PRODUCTS_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework" install_framework "$BUILT_PRODUCTS_DIR/Reflection-iOS/Reflection.framework" install_framework "$BUILT_PRODUCTS_DIR/Nimble/Nimble.framework" install_framework "$BUILT_PRODUCTS_DIR/Quick/Quick.framework" fi if [[ "$CONFIGURATION" == "Release" ]]; then install_framework "$BUILT_PRODUCTS_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework" install_framework "$BUILT_PRODUCTS_DIR/Reflection-iOS/Reflection.framework" install_framework "$BUILT_PRODUCTS_DIR/Nimble/Nimble.framework" install_framework "$BUILT_PRODUCTS_DIR/Quick/Quick.framework" fi ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-resources.sh ================================================ #!/bin/sh set -e mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt > "$RESOURCES_TO_COPY" XCASSET_FILES=() case "${TARGETED_DEVICE_FAMILY}" in 1,2) TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone" ;; 1) TARGET_DEVICE_ARGS="--target-device iphone" ;; 2) TARGET_DEVICE_ARGS="--target-device ipad" ;; *) TARGET_DEVICE_ARGS="--target-device mac" ;; esac install_resource() { if [[ "$1" = /* ]] ; then RESOURCE_PATH="$1" else RESOURCE_PATH="${PODS_ROOT}/$1" fi if [[ ! -e "$RESOURCE_PATH" ]] ; then cat << EOM error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script. EOM exit 1 fi case $RESOURCE_PATH in *.storyboard) echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} ;; *.xib) echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} ;; *.framework) echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" echo "rsync -av $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" rsync -av "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" ;; *.xcdatamodel) echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom" ;; *.xcdatamodeld) echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd" ;; *.xcmappingmodel) echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm" ;; *.xcassets) ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH" XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE") ;; *) echo "$RESOURCE_PATH" echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY" ;; esac } mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" fi rm -f "$RESOURCES_TO_COPY" if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ] then # Find all other xcassets (this unfortunately includes those of path pods and other targets). OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d) while read line; do if [[ $line != "${PODS_ROOT}*" ]]; then XCASSET_FILES+=("$line") fi done <<<"$OTHER_XCASSETS" printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" fi ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests-umbrella.h ================================================ #ifdef __OBJC__ #import #endif FOUNDATION_EXPORT double Pods_PersistentStorageSerializable_TestsVersionNumber; FOUNDATION_EXPORT const unsigned char Pods_PersistentStorageSerializable_TestsVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests.debug.xcconfig ================================================ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) $(PLATFORM_DIR)/Developer/Library/Frameworks "$PODS_CONFIGURATION_BUILD_DIR/Nimble" "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS" "$PODS_CONFIGURATION_BUILD_DIR/Quick" "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/Nimble/Nimble.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Quick/Quick.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS/Reflection.framework/Headers" OTHER_LDFLAGS = $(inherited) -framework "Nimble" -framework "PersistentStorageSerializable" -framework "Quick" -framework "Reflection" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT}/Pods ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests.modulemap ================================================ framework module Pods_PersistentStorageSerializable_Tests { umbrella header "Pods-PersistentStorageSerializable_Tests-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_Tests/Pods-PersistentStorageSerializable_Tests.release.xcconfig ================================================ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) $(PLATFORM_DIR)/Developer/Library/Frameworks "$PODS_CONFIGURATION_BUILD_DIR/Nimble" "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS" "$PODS_CONFIGURATION_BUILD_DIR/Quick" "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/Nimble/Nimble.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Quick/Quick.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS/Reflection.framework/Headers" OTHER_LDFLAGS = $(inherited) -framework "Nimble" -framework "PersistentStorageSerializable" -framework "Quick" -framework "Reflection" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT}/Pods ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 1.0.0 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-acknowledgements.markdown ================================================ # Acknowledgements This application makes use of the following third party libraries: ## PersistentStorageSerializable Copyright (c) 2017 IvanRublev Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ## Reflection The MIT License (MIT) Copyright (c) 2016 Brad Hilton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. Generated by CocoaPods - https://cocoapods.org ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-acknowledgements.plist ================================================ PreferenceSpecifiers FooterText This application makes use of the following third party libraries: Title Acknowledgements Type PSGroupSpecifier FooterText Copyright (c) 2017 IvanRublev <ivan@ivanrublev.me> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License MIT Title PersistentStorageSerializable Type PSGroupSpecifier FooterText The MIT License (MIT) Copyright (c) 2016 Brad Hilton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. License MIT Title Reflection Type PSGroupSpecifier FooterText Generated by CocoaPods - https://cocoapods.org Title Type PSGroupSpecifier StringsTable Acknowledgements Title Acknowledgements ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-dummy.m ================================================ #import @interface PodsDummy_Pods_PersistentStorageSerializable_iOSExample : NSObject @end @implementation PodsDummy_Pods_PersistentStorageSerializable_iOSExample @end ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-frameworks.sh ================================================ #!/bin/sh set -e echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}" install_framework() { if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then local source="${BUILT_PRODUCTS_DIR}/$1" elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")" elif [ -r "$1" ]; then local source="$1" fi local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" if [ -L "${source}" ]; then echo "Symlinked..." source="$(readlink "${source}")" fi # use filter instead of exclude so missing patterns dont' throw errors echo "rsync -av --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\"" rsync -av --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}" local basename basename="$(basename -s .framework "$1")" binary="${destination}/${basename}.framework/${basename}" if ! [ -r "$binary" ]; then binary="${destination}/${basename}" fi # Strip invalid architectures so "fat" simulator / device frameworks work on device if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then strip_invalid_archs "$binary" fi # Resign the code if required by the build settings to avoid unstable apps code_sign_if_enabled "${destination}/$(basename "$1")" # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then local swift_runtime_libs swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) for lib in $swift_runtime_libs; do echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" code_sign_if_enabled "${destination}/${lib}" done fi } # Signs a framework with the provided identity code_sign_if_enabled() { if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then # Use the current code_sign_identitiy echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" echo "/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements \"$1\"" /usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements "$1" fi } # Strip invalid architectures strip_invalid_archs() { binary="$1" # Get architectures for current file archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | rev)" stripped="" for arch in $archs; do if ! [[ "${VALID_ARCHS}" == *"$arch"* ]]; then # Strip non-valid architectures in-place lipo -remove "$arch" -output "$binary" "$binary" || exit 1 stripped="$stripped $arch" fi done if [[ "$stripped" ]]; then echo "Stripped $binary of architectures:$stripped" fi } if [[ "$CONFIGURATION" == "Debug" ]]; then install_framework "$BUILT_PRODUCTS_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework" install_framework "$BUILT_PRODUCTS_DIR/Reflection-iOS/Reflection.framework" fi if [[ "$CONFIGURATION" == "Release" ]]; then install_framework "$BUILT_PRODUCTS_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework" install_framework "$BUILT_PRODUCTS_DIR/Reflection-iOS/Reflection.framework" fi ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-resources.sh ================================================ #!/bin/sh set -e mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt > "$RESOURCES_TO_COPY" XCASSET_FILES=() case "${TARGETED_DEVICE_FAMILY}" in 1,2) TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone" ;; 1) TARGET_DEVICE_ARGS="--target-device iphone" ;; 2) TARGET_DEVICE_ARGS="--target-device ipad" ;; *) TARGET_DEVICE_ARGS="--target-device mac" ;; esac install_resource() { if [[ "$1" = /* ]] ; then RESOURCE_PATH="$1" else RESOURCE_PATH="${PODS_ROOT}/$1" fi if [[ ! -e "$RESOURCE_PATH" ]] ; then cat << EOM error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script. EOM exit 1 fi case $RESOURCE_PATH in *.storyboard) echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} ;; *.xib) echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} ;; *.framework) echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" echo "rsync -av $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" rsync -av "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" ;; *.xcdatamodel) echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom" ;; *.xcdatamodeld) echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd" ;; *.xcmappingmodel) echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm" ;; *.xcassets) ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH" XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE") ;; *) echo "$RESOURCE_PATH" echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY" ;; esac } mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" fi rm -f "$RESOURCES_TO_COPY" if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ] then # Find all other xcassets (this unfortunately includes those of path pods and other targets). OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d) while read line; do if [[ $line != "${PODS_ROOT}*" ]]; then XCASSET_FILES+=("$line") fi done <<<"$OTHER_XCASSETS" printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" fi ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample-umbrella.h ================================================ #ifdef __OBJC__ #import #endif FOUNDATION_EXPORT double Pods_PersistentStorageSerializable_iOSExampleVersionNumber; FOUNDATION_EXPORT const unsigned char Pods_PersistentStorageSerializable_iOSExampleVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample.debug.xcconfig ================================================ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS" "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS/Reflection.framework/Headers" OTHER_LDFLAGS = $(inherited) -framework "PersistentStorageSerializable" -framework "Reflection" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT}/Pods ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample.modulemap ================================================ framework module Pods_PersistentStorageSerializable_iOSExample { umbrella header "Pods-PersistentStorageSerializable_iOSExample-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/Pods-PersistentStorageSerializable_iOSExample/Pods-PersistentStorageSerializable_iOSExample.release.xcconfig ================================================ ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES EMBEDDED_CONTENT_CONTAINS_SWIFT = YES FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS" "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/PersistentStorageSerializable-iOS/PersistentStorageSerializable.framework/Headers" -iquote "$PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS/Reflection.framework/Headers" OTHER_LDFLAGS = $(inherited) -framework "PersistentStorageSerializable" -framework "Reflection" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT}/Pods ================================================ FILE: Example/Pods/Target Support Files/Quick/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 1.0.0 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/Quick/Quick-dummy.m ================================================ #import @interface PodsDummy_Quick : NSObject @end @implementation PodsDummy_Quick @end ================================================ FILE: Example/Pods/Target Support Files/Quick/Quick-prefix.pch ================================================ #ifdef __OBJC__ #import #endif ================================================ FILE: Example/Pods/Target Support Files/Quick/Quick-umbrella.h ================================================ #ifdef __OBJC__ #import #endif #import "QuickConfiguration.h" #import "QCKDSL.h" #import "Quick.h" #import "QuickSpec.h" FOUNDATION_EXPORT double QuickVersionNumber; FOUNDATION_EXPORT const unsigned char QuickVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/Quick/Quick.modulemap ================================================ framework module Quick { umbrella header "Quick-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/Quick/Quick.xcconfig ================================================ CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/Quick ENABLE_BITCODE = NO FRAMEWORK_SEARCH_PATHS = $(inherited) "$(PLATFORM_DIR)/Developer/Library/Frameworks" GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" OTHER_LDFLAGS = -framework "XCTest" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT} PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} SKIP_INSTALL = YES ================================================ FILE: Example/Pods/Target Support Files/Reflection-OSX/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 0.14.3 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/Reflection-OSX/Reflection-OSX-dummy.m ================================================ #import @interface PodsDummy_Reflection_OSX : NSObject @end @implementation PodsDummy_Reflection_OSX @end ================================================ FILE: Example/Pods/Target Support Files/Reflection-OSX/Reflection-OSX-prefix.pch ================================================ #ifdef __OBJC__ #import #endif ================================================ FILE: Example/Pods/Target Support Files/Reflection-OSX/Reflection-OSX-umbrella.h ================================================ #ifdef __OBJC__ #import #endif FOUNDATION_EXPORT double ReflectionVersionNumber; FOUNDATION_EXPORT const unsigned char ReflectionVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/Reflection-OSX/Reflection-OSX.modulemap ================================================ framework module Reflection { umbrella header "Reflection-OSX-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/Reflection-OSX/Reflection-OSX.xcconfig ================================================ CODE_SIGN_IDENTITY = CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/Reflection-OSX GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT} PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} SKIP_INSTALL = YES ================================================ FILE: Example/Pods/Target Support Files/Reflection-iOS/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable ${EXECUTABLE_NAME} CFBundleIdentifier ${PRODUCT_BUNDLE_IDENTIFIER} CFBundleInfoDictionaryVersion 6.0 CFBundleName ${PRODUCT_NAME} CFBundlePackageType FMWK CFBundleShortVersionString 0.14.3 CFBundleSignature ???? CFBundleVersion ${CURRENT_PROJECT_VERSION} NSPrincipalClass ================================================ FILE: Example/Pods/Target Support Files/Reflection-iOS/Reflection-iOS-dummy.m ================================================ #import @interface PodsDummy_Reflection_iOS : NSObject @end @implementation PodsDummy_Reflection_iOS @end ================================================ FILE: Example/Pods/Target Support Files/Reflection-iOS/Reflection-iOS-prefix.pch ================================================ #ifdef __OBJC__ #import #endif ================================================ FILE: Example/Pods/Target Support Files/Reflection-iOS/Reflection-iOS-umbrella.h ================================================ #ifdef __OBJC__ #import #endif FOUNDATION_EXPORT double ReflectionVersionNumber; FOUNDATION_EXPORT const unsigned char ReflectionVersionString[]; ================================================ FILE: Example/Pods/Target Support Files/Reflection-iOS/Reflection-iOS.modulemap ================================================ framework module Reflection { umbrella header "Reflection-iOS-umbrella.h" export * module * { export * } } ================================================ FILE: Example/Pods/Target Support Files/Reflection-iOS/Reflection-iOS.xcconfig ================================================ CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/Reflection-iOS GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" PODS_BUILD_DIR = $BUILD_DIR PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) PODS_ROOT = ${SRCROOT} PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} SKIP_INSTALL = YES ================================================ FILE: Example/Tests/Car.plist ================================================ Car.doors 7 ================================================ FILE: Example/Tests/Info.plist ================================================ CFBundleDevelopmentRegion en CFBundleExecutable $(EXECUTABLE_NAME) CFBundleIdentifier $(PRODUCT_BUNDLE_IDENTIFIER) CFBundleInfoDictionaryVersion 6.0 CFBundleName $(PRODUCT_NAME) CFBundlePackageType BNDL CFBundleShortVersionString 1.0 CFBundleSignature ???? CFBundleVersion 1 ================================================ FILE: Example/Tests/PersistentStorageMock.swift ================================================ // // PersistentStorageMock.swift // PersistentStorageSerializable // // Created by Ivan Rublev on 4/5/17. // Copyright © 2017 CocoaPods. All rights reserved. // import Foundation import PersistentStorageSerializable class PersistentStorageMock: PersistentStorage { var transactionWasBegan = false func beginTransaction() throws { transactionWasBegan = true } open static let shared: PersistentStorage = PersistentStorageMock() var registeredDefaultValues: [String : Any]? func register(defaultValues: [String : Any]) { registeredDefaultValues = defaultValues } typealias ValuesDictionary = Dictionary var tempValues = ValuesDictionary() var values = ValuesDictionary() public func get(valueOf key: String) -> Any? { if let value = tempValues[key] { return value } return values[key] } enum InternalError: Error { case Failure } var throwOnSet: InternalError? func set(value: Any?, for key: String) throws { if let errorToThrow = throwOnSet { throw errorToThrow } tempValues[key] = value } var synchronizeWasCalled = false func finishTransaction() throws { values = tempValues tempValues.removeAll() synchronizeWasCalled = true } } ================================================ FILE: Example/Tests/PersistentStorageSerializableTests.swift ================================================ // https://github.com/Quick/Quick import Quick import Nimble @testable import PersistentStorageSerializable let memoryStorage = PersistentStorageMock() // MARK: These are persistable types. struct Person: PersistentStorageSerializable { var name: String = "Dory" var birthday: Date = Date() var web: URL = URL(string: "https://dory.me")! var age: Int = 25 var addressDistance: Dictionary = ["Kensington rd. 75" : 125.8, "Portland ave. 15" : 245.6] var favoriteNumbers = [1, 7, 9] // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! = Person.defaultPersistentStorage var persistentStorageKeyPrefix: String! = Person.defaultPersistentStorageKeyPrefix } extension Person { static let defaultPersistentStorage = memoryStorage static let defaultPersistentStorageKeyPrefix = "Person" } extension Person: Equatable { static func == (lhs: Person, rhs: Person) -> Bool { return lhs.name == rhs.name && abs(rhs.birthday.timeIntervalSince(lhs.birthday)) < 0.2 && lhs.web == rhs.web && lhs.age == rhs.age && lhs.addressDistance == rhs.addressDistance && lhs.favoriteNumbers == rhs.favoriteNumbers } } final class Vehicle: PersistentStorageSerializable { var wheels: Int = 4 var doors: Int = 3 // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! = "Car" } final class Location: NSObject, PersistentStorageSerializable { dynamic var street: String = "" dynamic var houseNo: Int = 0 // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! = memoryStorage var persistentStorageKeyPrefix: String! = "Location" } class PersistableTypeTests: QuickSpec { override func spec() { let initialPerson = Person() describe("After first push of object to storage, initial values") { let aPerson = Person() beforeEach { memoryStorage.registeredDefaultValues = nil } it("registered with storage.") { expect { try aPerson.pushToPersistentStorage() }.toNot(throwError()) expect(memoryStorage.registeredDefaultValues).toNot(beNil()) } context("and on following push") { it("not registered with storage.") { expect { try aPerson.pushToPersistentStorage() }.toNot(throwError()) expect(memoryStorage.registeredDefaultValues).to(beNil()) } } } describe("Swift class object properties values are") { let persistedDoors = 5 beforeEach { memoryStorage.values["Car.doors"] = persistedDoors } context("initialized from storage") { var car: Vehicle! it("successfully initialized.") { expect { car = try Vehicle(from: memoryStorage) }.toNot(throwError()) expect(car.doors) == persistedDoors } context("modified and persisted to storage") { let newWheels = 3 it("successfully persisted.") { car.wheels = newWheels expect { try car.persist() }.toNot(throwError()) expect(memoryStorage.values["Car.wheels"] as! Int?) == newWheels } } } } describe("Swift class object properties values are") { context("initializable from plist") { var car: Vehicle! var documentsCarUrl: URL? beforeEach { let plistFileName = "Car.plist" let bundledCarUrl = URL(fileURLWithPath: Bundle(for: Vehicle.self).path(forResource: plistFileName, ofType: nil)!) let documentsUrl = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).last! documentsCarUrl = documentsUrl.appendingPathComponent(plistFileName) print(documentsCarUrl!) try? FileManager.default.removeItem(at: documentsCarUrl!) try! FileManager.default.copyItem(at: bundledCarUrl, to: documentsCarUrl!) expect { car = try Vehicle(from: PlistStorage(at: documentsCarUrl!), keyPrefix: "Car") }.toNot(throwError()) } afterSuite { if let documentsCarUrl = documentsCarUrl { try? FileManager.default.removeItem(at: documentsCarUrl) } } it("successfully initialized.") { expect(car.wheels) == 4 expect(car.doors) == 7 } context("modified and persisted") { beforeEach { car.wheels = 3 expect { try car.persist() }.toNot(throwError()) } it("successfully persisted.") { var car2: Vehicle! expect { car2 = try Vehicle(from: PlistStorage(at: documentsCarUrl!), keyPrefix: "Car") }.toNot(throwError()) expect(car2.wheels) == 3 expect(car2.doors) == 7 } } } } describe("NSObject descendant object properties values are") { var loc: Location! let newStreet = "Holmes" let newHouseNo = 128 beforeEach { loc = Location() } context("when pushed") { it("persisted.") { loc.street = newStreet loc.houseNo = newHouseNo expect { try loc.pushToPersistentStorage() }.toNot(throwError()) expect(memoryStorage.values[loc.persistentStorageKey(for: "street")] as! String?) == newStreet expect(memoryStorage.values[loc.persistentStorageKey(for: "houseNo")] as! Int?) == newHouseNo } } context("when pulled") { beforeEach { memoryStorage.values[loc.persistentStorageKey(for: "street")] = newStreet memoryStorage.values[loc.persistentStorageKey(for: "houseNo")] = newHouseNo } it("restored.") { expect { try loc.pullFromPersistentStorage() }.toNot(throwError()) expect(loc.street) == newStreet expect(loc.houseNo) == newHouseNo } } } describe("Swift struct value properties values are") { var aPerson: Person! beforeEach { aPerson = initialPerson } context("not persisted in storage") { beforeEach { memoryStorage.values.removeAll() } context("after pull") { it("same as initial.") { expect { try aPerson.pullFromPersistentStorage() }.toNot(throwError()) expect(aPerson) == initialPerson } } context("modified") { let newName = "Mary Wong" let newFavoriteNumbers = [2, 8, 5] beforeEach { aPerson.name = newName aPerson.favoriteNumbers = newFavoriteNumbers } context("then pushed and pulled from storage") { beforeEach { try! aPerson.pushToPersistentStorage() aPerson = initialPerson try! aPerson.pullFromPersistentStorage() } it("keept modified.") { expect(aPerson.name) == newName expect(aPerson.favoriteNumbers) == newFavoriteNumbers } } } } context("persistent in storage") { let persistedPerson = Person(name: "Ada", birthday: Date(timeIntervalSinceReferenceDate:0), web: URL(string: "https://ada.me")!, age: 23, addressDistance: ["Banhof st. 22" : 178.1, "Ludvig st. 55": 345.8], favoriteNumbers: [8, 3, 5], persistentStorage: Person.defaultPersistentStorage, persistentStorageKeyPrefix: Person.defaultPersistentStorageKeyPrefix) beforeEach { memoryStorage.values[persistedPerson.persistentStorageKey(for: "name")] = persistedPerson.name memoryStorage.values[persistedPerson.persistentStorageKey(for: "birthday")] = persistedPerson.birthday memoryStorage.values[persistedPerson.persistentStorageKey(for: "web")] = persistedPerson.web memoryStorage.values[persistedPerson.persistentStorageKey(for: "age")] = persistedPerson.age memoryStorage.values[persistedPerson.persistentStorageKey(for: "addressDistance")] = persistedPerson.addressDistance memoryStorage.values[persistedPerson.persistentStorageKey(for: "favoriteNumbers")] = persistedPerson.favoriteNumbers } context("after pool") { it("same as in storage.") { expect { try aPerson.pullFromPersistentStorage() }.toNot(throwError()) expect(aPerson) == persistedPerson } } describe("Persistent representation dictionary") { var dictionary: [String : Any]! var memoryStorageValuesCount = 0 beforeEach { memoryStorageValuesCount = memoryStorage.values.count dictionary = try! persistedPerson.persistedDictionaryRepresentation() } it("same count as in storage.") { expect(dictionary.count) == memoryStorageValuesCount } } context("after remove from storage") { beforeEach { try! persistedPerson.removeFromPersistentStorage() } describe("Storage") { it("empty.") { expect(memoryStorage.values.count) == 0 } } } } } describe("Swift struct properties values are") { context("persisted under custom keys in storage") { let name = "Bob" let age = 55 beforeEach { memoryStorage.values["person.name"] = name memoryStorage.values["person.age"] = age } context("keys are mapped and we pull from storage") { struct OtherPerson: PersistentStorageSerializable { var name: String = "Dory" var age: Int = 25 // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! func persistentStorageKey(for propertyName: String) -> String { let keyMap = ["name": "person.name", "age": "person.age"] return keyMap[propertyName]! } } it("pulled with success.") { var person = OtherPerson() expect { person = try OtherPerson(from: memoryStorage, keyPrefix: "") }.toNot(throwError()) expect(person.name) == name expect(person.age) == age } } } } } } // MARK: - This is Not persistable, will throw exception at runtime. struct Address: PersistentStorageSerializable { struct Street { var name: String var central: Bool } var street: Street = Street(name: "Kensington rd. 85", central: true) // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! = memoryStorage var persistentStorageKeyPrefix: String! = "Address" } class UnpersistableTypeTests: QuickSpec { override func spec() { describe("Address object's properties values") { context("when pushed to storage") { it("throws an exception with street property because Street type is not a serializable type") { let address = Address() expect { try address.pushToPersistentStorage() }.to(throwError(PersistentStorageSerializableError.UnsupportedValueTypeForKey("street", PersistentStorageSerializableTypeError.CollectionElement(.NonPlistType)))) } } } } } ================================================ FILE: Example/Tests/SupportedSerializableTypeTests.swift ================================================ // // PersistentStorageSerializableTypeTests.swift // PersistentStorageSerializable // // Created by Ivan Rublev on 4/7/17. // Copyright © 2017 CocoaPods. All rights reserved. // import Quick import Nimble @testable import PersistentStorageSerializable class PersistentStorageSerializableTypesTests: QuickSpec { override func spec() { describe("Properties value of") { context("supported types") { let someData: Data = "Hello".data(using: String.Encoding.utf8)! let someDate: Date = Date(timeIntervalSinceReferenceDate: 1) let arrayOfUrl = [URL(string: "https://some.web")!, URL(string: "https://otherweb.com")!] it("serializable.") { expect { try Person.serializable(value: someData as Any) }.toNot(throwError()) expect { try Person.serializable(value: someDate as Any) }.toNot(throwError()) expect { try Person.serializable(value: arrayOfUrl as Any) }.toNot(throwError()) } } context("unsupported type") { it("Not serializable") { struct A {} expect { try Person.serializable(value: A() as Any) }.to(throwError(PersistentStorageSerializableTypeError.NonPlistType)) } } context("Collection type") { context("of supported type values") { let array: [Any] = [1, 3.0, "Hello", URL(string:"https://some.web")!] let dictionary: [String : Any] = ["one" : 1, "two" : 3.0, "three" : "Hello", "four" : URL(string:"https://some.web")!] it("serializable.") { expect { try Person.serializable(value: array) }.toNot(throwError()) expect { try Person.serializable(value: dictionary) }.toNot(throwError()) } } context("with optionals") { let array: [Any] = [1, Optional(3.0) as Any] let dictionary: [String : Any] = ["one" : 1, "two" : Optional(3.0) as Any] it("Not serializable.") { expect { try Person.serializable(value: array) }.to(throwError(PersistentStorageSerializableTypeError.CollectionElement(.UnsupportedOptional))) expect { try Person.serializable(value: dictionary) }.to(throwError(PersistentStorageSerializableTypeError.CollectionElement(.UnsupportedOptional))) } } context("with unsupported type values") { let array: [Any] = [1, 3.0, Person()] let dictionary: [String : Any] = ["one" : 1, "two" : 3.0, "three" : Person()] it("Not serializable.") { expect { try Person.serializable(value: array) }.to(throwError(PersistentStorageSerializableTypeError.CollectionElement(.NonPlistType))) expect { try Person.serializable(value: dictionary) }.to(throwError(PersistentStorageSerializableTypeError.CollectionElement(.NonPlistType))) } } } context("Nested Collection type of supported type values") { let array: [Any] = [1, [3.0, ["Hello", [URL(string:"https://some.web")!]]]] let dictionary: [String : Any] = ["one" : 1, "nested" : ["two" : 3.0, "nested" : ["three" : "Hello", "nested" : ["four" : URL(string:"https://some.web")!]]]] it("serializable.") { expect { try Person.serializable(value: array) }.toNot(throwError()) expect { try Person.serializable(value: dictionary) }.toNot(throwError()) } } } } } ================================================ FILE: LICENSE ================================================ Copyright (c) 2017 IvanRublev Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: PersistentStorageSerializable/Assets/.gitkeep ================================================ ================================================ FILE: PersistentStorageSerializable/Classes/.gitkeep ================================================ ================================================ FILE: PersistentStorageSerializable/Classes/PersistentStorage.swift ================================================ // // PersistentStorage.swift // Pods // // Created by Ivan Rublev on 4/5/17. // // import Foundation /** Abstract protocol to read/write from persistent system storage. */ public protocol PersistentStorage: class { /// Begins sequence of operations with persistent storage. func beginTransaction() throws /// Registers default values with storage. Like register(defaults:) method of UserDefaults. /// /// - Parameter defaultValues: Dictionary with defaults value. func register(defaultValues: [String : Any]) /// Returns a value from persistent storage for specified key. /// /// - Parameter key: Key to read /// - Returns: Value from the persistent storage or nil if there is no value for the specified key. func get(valueOf key: String) -> Any? /// Sets a value for specified key into persistent storage. /// When value is nil then the key/value pair is removed from the storage. /// Call synchronize() after all key/value pairs are set to commit changes to the storage. /// /// - Parameters: /// - value: Value to store /// - key: Key /// - Throws: Storage write error. func set(value: Any?, for key: String) throws /// Commits operations to the persistent storage. func finishTransaction() throws } ================================================ FILE: PersistentStorageSerializable/Classes/PersistentStorageSerializable.swift ================================================ // // PersistentStorageSerializable.swift // Pods // // Created by Ivan Rublev on 4/5/17. // // import Foundation import Reflection public enum PersistentStorageSerializableError: Error { case UnsupportedValueTypeForKey(String, PersistentStorageSerializableTypeError) case FailedToGetIntancePropertyValueForName(String) } /** Protocol for serialization of type with persistent storage. */ public protocol PersistentStorageSerializable { /// Storage type to serialize with var persistentStorage: PersistentStorage! { get set } /// Prefix that will be used to make a key for every type's property value in persistant storage var persistentStorageKeyPrefix: String! { get set } /// Values set in default initializer are registered as defaults with persistent storage. init() init(from persistentStorage: PersistentStorage, keyPrefix: String?) throws // MARK: Optional /// Returns a key to be used in persistent storage to keep type instance property value. /// Default implementation constructs the key by using persistentStorageKeyPrefix. /// /// - Parameter propertyName: Name of instanse property. /// - Returns: Key for instance property value in persistance storage. func persistentStorageKey(for propertyName: String) -> String } public extension PersistentStorageSerializable { /// Initializer calls default initializer then pulls properties values from persistent storage. /// /// - Parameters: /// - persistentStorage: Persistent storage to serialize with. /// - keyPrefix: Prefix for properties values key in persistent storage. If is not specified, then default value must be set in adopter type definition, or the `persistentStorageKey(for:)` function must be overloaded. /// - Throws: Error of pulling from storage. init(from persistentStorage: PersistentStorage, keyPrefix: String? = nil) throws { self.init() self.persistentStorage = persistentStorage if let keyPrefix = keyPrefix { self.persistentStorageKeyPrefix = keyPrefix } try pullFromPersistentStorage() } /// Read all type instance properties (skipping declared in the protocol) values from the persistent storage. /// If there is no value for a property in the persistent storage then keeps the instance's current property value. /// /// - Throws: Type instance property value setting error. public mutating func pullFromPersistentStorage() throws { try self.persistentStorage.beginTransaction() try registerInstancePropertiesValueAsDefaultsWithStorageOnce() try setEachSelfProperty { (key) -> Any? in let storageKey = self.persistentStorageKey(for: key) return self.persistentStorage.get(valueOf: storageKey) } try self.persistentStorage.finishTransaction() } /// Implementation of persist() public func pushToPersistentStorage() throws { try self.persistentStorage.beginTransaction() try registerInstancePropertiesValueAsDefaultsWithStorageOnce() try eachSelfProperty { (key, value) in let storageKey = self.persistentStorageKey(for: key) do { try Self.serializable(value: value) } catch let error as PersistentStorageSerializableTypeError { throw PersistentStorageSerializableError.UnsupportedValueTypeForKey(key, error) } try self.persistentStorage.set(value: value, for: storageKey) } try self.persistentStorage.finishTransaction() } /// Writes all type instance properties (skipping declared in the protocol) values to the persistent storage. /// If instance's property value is nil then removes the value from the persistent storage. /// /// - Throws: Type instance property value reading error. Persistent storage write error. public func persist() throws { try pushToPersistentStorage() } /// Removes data from persistent storage if was previosly there. /// Uses current type properties names to search for values to remove. /// /// - Throws: Type properties description read error. public func removeFromPersistentStorage() throws { let allKeys = try persistedDictionaryRepresentation().keys try self.persistentStorage.beginTransaction() for key in allKeys { try self.persistentStorage.set(value: nil, for: key) } try self.persistentStorage.finishTransaction() } /// Returns dictionary representation of the persisted data for the type. /// Uses current type properties names to get persisted data from the storage. /// /// - Returns: Dictionary with data. /// - Throws: Type properties description read error. public func persistedDictionaryRepresentation() throws -> [String : Any] { var dictionary = [String : Any]() try self.persistentStorage.beginTransaction() let propertiesDescription = try properties(Self.self) for desc in propertiesDescription { let key = desc.key let storageKey = self.persistentStorageKey(for: key) if let value = self.persistentStorage.get(valueOf: storageKey) { dictionary[storageKey] = value } } try self.persistentStorage.finishTransaction() return dictionary } /// Default implementation public func persistentStorageKey(for propertyName: String) -> String { return String(format: "%@.%@", self.persistentStorageKeyPrefix, propertyName) } } // MARK: - Defaults registration with storage var persistentStorageDefaultsRegistrationTracker = [String]() extension PersistentStorageSerializable { /// Registers the current instance properties values as default values with storage once per app run. func registerInstancePropertiesValueAsDefaultsWithStorageOnce() throws { if persistentStorageDefaultsRegistrationTracker.contains(self.persistentStorageKeyPrefix) == false { persistentStorageDefaultsRegistrationTracker.append(self.persistentStorageKeyPrefix) var initialValueDictionary = [String : Any]() try eachSelfProperty { (key, value) in let storageKey = self.persistentStorageKey(for: key) initialValueDictionary[storageKey] = value } self.persistentStorage.register(defaultValues: initialValueDictionary) } } } ================================================ FILE: PersistentStorageSerializable/Classes/PlistStorage.swift ================================================ // // PlistStorage.swift // Pods // // Created by Ivan Rublev on 4/7/17. // // import Foundation /** Class to persist data in Plist file on disk. */ open class PlistStorage { let url: URL public init(at url: URL) { precondition(url.isFileURL) self.url = url } var dictionary: NSMutableDictionary? var newDictionary: NSMutableDictionary! var anyKeyWasSet = false var finished = true } // MARK: - Adopt PersistentStorage extension PlistStorage: PersistentStorage { public func beginTransaction() throws { precondition(finished, "Must call finishTransaction() before beginning a new one.") finished = false SwiftTryCatch.try({ self.dictionary = NSMutableDictionary(contentsOf: self.url) }, catch: nil, finallyBlock: nil) newDictionary = NSMutableDictionary() } public func register(defaultValues: [String : Any]) { // default values are not applicable } public func get(valueOf key: String) -> Any? { return dictionary?[key] } public func set(value: Any?, for key: String) throws { newDictionary[key] = value anyKeyWasSet = true } public func finishTransaction() throws { dictionary = nil if anyKeyWasSet { let data = try PropertyListSerialization.data(fromPropertyList: newDictionary, format: .xml, options: 0) try data.write(to: url, options: .atomic) } anyKeyWasSet = false newDictionary = nil finished = true } } ================================================ FILE: PersistentStorageSerializable/Classes/PropertiesIteration.swift ================================================ // // PropertiesIteration.swift // Pods // // Created by Ivan Rublev on 4/7/17. // // import Foundation import Reflection let persistentStorageSerializableProtocolVariableNames: Set = ["persistentStorage", "persistentStorageKeyPrefix"] extension PersistentStorageSerializable { func selfPropertiesNames() throws -> [String] { let skipNames = persistentStorageSerializableProtocolVariableNames let propertiesDescription = try properties(Self.self) let keys: [String] = propertiesDescription.flatMap { skipNames.contains($0.key) ? nil : $0.key } return keys } /// Performs a closure over each of type instance's properties. /// /// - Parameter names: Set of properties names to skip during enumeration. /// - Parameter perform: Closure to be called on each property key and value pair. /// - Throws: Error from perform closure. func eachSelfProperty(perform: (_ key: String, _ value: Any) throws -> ()) throws { let keys: [String] = try selfPropertiesNames() var keyedValues = [String : Any]() var kvcSuccseed = false if let objcObj = self as? NSObject { SwiftTryCatch.try({ keyedValues = objcObj.dictionaryWithValues(forKeys: keys) kvcSuccseed = true }, catch: nil, finallyBlock: nil) } if kvcSuccseed == false { // pure Swift object for aKey in keys { let propertyValue: Any? = try Reflection.get(aKey, from: self) guard let value = propertyValue else { throw PersistentStorageSerializableError.FailedToGetIntancePropertyValueForName(aKey) } keyedValues[aKey] = value } } for (key, value) in keyedValues { try perform(key, value) } } /// Sets a value for each property of type instance. /// /// - Parameter valueFor: Closure that returns value for specified property name. If returns nil then property is left untouched. /// - Throws: Error from valueFor closure. mutating func setEachSelfProperty(with valueFor: (_ propertyName: String) throws -> Any?) throws { let keys: [String] = try selfPropertiesNames() var keyedValues = [String : Any]() for aKey in keys { if let value = try valueFor(aKey) { keyedValues[aKey] = value } } var kvcSuccseed = false if let objcObj = self as? NSObject { SwiftTryCatch.try({ objcObj.setValuesForKeys(keyedValues) kvcSuccseed = true }, catch: nil, finallyBlock: nil) } if kvcSuccseed == false { // pure Swift object for (key, value) in keyedValues { try Reflection.set(value, key: key, for: &self) } } } } ================================================ FILE: PersistentStorageSerializable/Classes/SupportedSerializableType.swift ================================================ // // SupportedSerializableType.swift // Pods // // Created by Ivan Rublev on 4/10/17. // // import Foundation public indirect enum PersistentStorageSerializableTypeError: Error { case UnsupportedOptional case NonPlistType case CollectionElement(PersistentStorageSerializableTypeError) } protocol OptionalProtocol {} extension Optional: OptionalProtocol {} protocol ArrayProtocol {} extension Array: ArrayProtocol {} protocol DictionaryProtocol {} extension Dictionary: DictionaryProtocol {} extension PersistentStorageSerializable { static func isSerializableType(value: Any) -> Bool { return value is Data || value is String || value is UInt || value is Int || value is Float || value is Double || value is Bool || value is URL || value is Date } @discardableResult static func serializable(value: Any) throws -> Bool { if value is OptionalProtocol { // we do not support optionals throw PersistentStorageSerializableTypeError.UnsupportedOptional } if isSerializableType(value: value) { return true } // else not a simple type func areElementsOfSerializableType(for sequence: T) throws -> Bool { for element in sequence { do { try serializable(value: element) } catch let error as PersistentStorageSerializableTypeError { throw PersistentStorageSerializableTypeError.CollectionElement(error) } } return true } if value is ArrayProtocol, let abstractArray = value as? Array { return try areElementsOfSerializableType(for: abstractArray) } else if value is DictionaryProtocol, let abstractDictionary = value as? Dictionary { return try areElementsOfSerializableType(for: abstractDictionary.values) } // else is not of required collection type throw PersistentStorageSerializableTypeError.NonPlistType } } ================================================ FILE: PersistentStorageSerializable/Classes/SwiftTryCatch.h ================================================ // // SwiftTryCatch.h // // Created by William Falcon on 10/10/14. // Copyright (c) 2014 William Falcon. All rights reserved. // /* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ @import Foundation; @interface SwiftTryCatch : NSObject /** Provides try catch functionality for swift by wrapping around Objective-C */ + (void)tryBlock:(void(^)())tryBlock catchBlock:(void(^)(NSException*exception))catchBlock finallyBlock:(void(^)())finallyBlock; + (void)throwString:(NSString*)s; + (void)throwException:(NSException*)e; @end ================================================ FILE: PersistentStorageSerializable/Classes/SwiftTryCatch.m ================================================ // // SwiftTryCatch.h // // Created by William Falcon on 10/10/14. // Copyright (c) 2014 William Falcon. All rights reserved. // /* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ #import "SwiftTryCatch.h" @implementation SwiftTryCatch /** Provides try catch functionality for swift by wrapping around Objective-C */ + (void)tryBlock:(void(^)())tryBlock catchBlock:(void(^)(NSException*exception))catchBlock finallyBlock:(void(^)())finallyBlock { @try { tryBlock ? tryBlock() : nil; } @catch (NSException *exception) { catchBlock ? catchBlock(exception) : nil; } @finally { finallyBlock ? finallyBlock() : nil; } } + (void)throwString:(NSString*)s { @throw [NSException exceptionWithName:s reason:s userInfo:nil]; } + (void)throwException:(NSException*)e { @throw e; } @end ================================================ FILE: PersistentStorageSerializable/Classes/UserDefaultsStorage.swift ================================================ // // UserDefaultsStorage.swift // Pods // // Created by Ivan Rublev on 4/5/17. // // import Foundation /** Interface protocol to UserDefaults object */ public protocol UserDefaultsStorageSystemUserDefaults { static var standard: UserDefaults { get } func register(defaults registrationDictionary: [String : Any]) func object(forKey defaultName: String) -> Any? func set(_ value: Any?, forKey defaultName: String) func removeObject(forKey defaultName: String) func synchronize() -> Bool } extension UserDefaults: UserDefaultsStorageSystemUserDefaults {} /** Class to persist data in User Defaults storage. */ open class UserDefaultsStorage { /// Shared defaults storage open static let standard: PersistentStorage = UserDefaultsStorage() /// Bridge to defaults object var defaults: UserDefaultsStorageSystemUserDefaults { return UserDefaults.standard } } // MARK: - Adopt PersistentStorage extension UserDefaultsStorage: PersistentStorage { open func beginTransaction() throws { precondition(Thread.isMainThread) let _ = defaults.synchronize() } open func register(defaultValues: [String : Any]) { precondition(Thread.isMainThread) defaults.register(defaults: defaultValues) } open func get(valueOf key: String) -> Any? { precondition(Thread.isMainThread) return defaults.object(forKey: key) } open func set(value: Any?, for key: String) throws { precondition(Thread.isMainThread) if let value = value { defaults.set(value, forKey: key) } else { defaults.removeObject(forKey: key) } } open func finishTransaction() throws { precondition(Thread.isMainThread) let _ = defaults.synchronize() } } ================================================ FILE: PersistentStorageSerializable.podspec ================================================ # # Be sure to run `pod lib lint PersistentStorageSerializable.podspec' to ensure this is a # valid spec before submitting. # # Any lines starting with a # are optional, but their use is encouraged # To learn more about a Podspec see http://guides.cocoapods.org/syntax/podspec.html # Pod::Spec.new do |s| s.name = 'PersistentStorageSerializable' s.version = '1.1.2' s.summary = 'Swift library that makes easier to serialize the user\'s preferences class/struct with system User Defaults or Property List file on disk.' s.description = <<-DESC Number of protocols from this pod helps to serialize swift class or structure to persistent storage like User Defaults or Keychain. The class/structure must contain properties of simple data type only. These types are: Data, String, Int, Float, Double, Bool, URL, Date, Array, or Dictionary. Adopt the PersistentStorageSerializable protocol from your struct. Then call pullFromUserDefaults() or pushToUserDefaults() on instance of your struct. DESC s.homepage = 'https://github.com/IvanRublev/PersistentStorageSerializable' s.license = { :type => 'MIT', :file => 'LICENSE' } s.author = { 'IvanRublev' => 'ivan@ivanrublev.me' } s.source = { :git => 'https://github.com/IvanRublev/PersistentStorageSerializable.git', :tag => s.version.to_s } s.ios.deployment_target = '9.0' s.osx.deployment_target = '10.11' s.source_files = 'PersistentStorageSerializable/Classes/**/*' s.frameworks = 'Foundation' s.dependency 'Reflection', '~> 0.14' end ================================================ FILE: README.md ================================================ # PersistentStorageSerializable [![CI Status](http://img.shields.io/travis/IvanRublev/PersistentStorageSerializable.svg?style=flat)](https://travis-ci.org/IvanRublev/PersistentStorageSerializable) [![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage) [![Version](https://img.shields.io/cocoapods/v/PersistentStorageSerializable.svg?style=flat)](http://cocoapods.org/pods/PersistentStorageSerializable) [![Swift](https://img.shields.io/badge/Swift-3.1-orange.svg?style=flat)](https://img.shields.io/badge/Swift-3.1-orange.svg?style=flat) [![License](https://img.shields.io/cocoapods/l/PersistentStorageSerializable.svg?style=flat)](http://cocoapods.org/pods/PersistentStorageSerializable) `PersistentStorageSerializable` is a protocol for automatic serialization and deserialization of Swift class, struct or NSObject descendant object into and from User Defaults or Property List file. The adopting type properties must be of property list type (String, Data, Date, Int, UInt, Float, Double, Bool, Array or Dictionary of above). If you want to store any other type of object, you should typically archive it to create an instance of Data. The URL properties can be stored in User Defaults storage but not in Plist storage. In the last case, you have to archive it to/from Data. The `PersistentStorageSerializable` protocol provides default implementations of `init(from:)` initializer and `persist()` function. The library defines two classes of `PesistentStorage` protocol: `UserDefaultsStorage` and `PlistStorage`. Object of one of those types is passed as the argument when calling to `init(from:)` initializer to specify which storage to be used for serialization/deserialization. Functions of the `PersistentStorageSerializable` protocol traverses the adopting type object and gets/sets it's properties values via [Reflection](https://github.com/Zewo/Reflection) library. The NSObject class descendant properties values are get/set via KVC. ## How to use Serialize/Deserialize a struct with User Defaults by using `UserDefaultStorage` as shown below: ```swift struct Settings: PersistentStorageSerializable { var flag = false var title = "" var number = 1 var dictionary: [String : Any] = ["Number" : 1, "Distance" : 25.4, "Label" : "Hello"] // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! = "Settings" } // Init from User Defaults var mySettings = try! Settings(from: UserDefaultsStorage.standard) mySettings.flag = true // Persist into User Defaults try! mySettings.persist() ``` To serialize data with Plist file use `PlistStorage` class: ```swift // Init from plist let plistUrl = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).last!.appendingPathComponent("storage.plist") var settingsOnDisk = try! Settings(from: PlistStorage(at: plistUrl)) mySettings.flag = true // Persist on disk try! mySettings.persist() ``` ### Reading data stored by the previous version of the app When you have some data persisted in User Defaults by the previous version of the app and want to read that data into a structure you need to provide a mapping between properties names and User Defaults keys by overloading the `persistentStorageKey(for:)` function. Say we have following data persisted in User Defaults: ```swift UserDefaults.standard.set("Superhero", forKey: "oldGoogTitle") UserDefaults.standard.set(true, forKey: "well.persisted.option") ``` We want those to be serialized with the object of `ApplicationConfiguration` class. ```swift final class ApplicationConfiguration: PersistentStorageSerializable { var title = "" var showIntro = false // MARK: Adopt PersistentStorageSerializable var persistentStorage: PersistentStorage! var persistentStorageKeyPrefix: String! } // Provide key mapping by overloading `persistentStorageKey(for:)` function. extension ApplicationConfiguration { func persistentStorageKey(for propertyName: String) -> String { let keyMap = ["title" : "oldGoogTitle", "showIntro" : "well.persisted.option"] return keyMap[propertyName]! } } // Now we can load data persisted in the storage. let configuration = try! ApplicationConfiguration(from: UserDefaultsStorage.standard) print(configuration.title) // prints Superhero print(configuration.showIntro) // prints true ``` ## Example To run example projects for iOS/macOS, run `pod try PersistentStorageSerializable` in the terminal. ## Requirements - Xcode 8.3 - Swift 3.1 ## Installation ### CocoaPods PersistentStorageSerializable is available through [CocoaPods](http://cocoapods.org). To install it, simply add the following line to your Podfile: ```ruby pod "PersistentStorageSerializable" ``` and run `pods update` or `pods install`. > :sparkles: For Xcode 9, Swift 4 and cocoapods installation, please follow the [instruction here](https://github.com/IvanRublev/PersistentStorageSerializable/issues/2#issuecomment-332145439). ### Carthage If you use Carthage to manage your dependencies, simply add PersistentStorageSerializable to your Cartfile: ``` github "IvanRublev/PersistentStorageSerializable" ``` If you use Carthage to build your dependencies, make sure you have added `PersistentStorageSerializable.framework` and `Reflection.framework` to the "Linked Frameworks and Libraries" section of your target, and have included them in your Carthage framework copying build phase. ## Author Copyright (c) 2017, IvanRublev, ivan@ivanrublev.me ## License PersistentStorageSerializable is available under the MIT license. See the LICENSE file for more info.