├── Pod ├── Assets │ ├── .gitkeep │ ├── close.png │ ├── delete.png │ ├── share.png │ ├── close@2x.png │ ├── close@3x.png │ ├── delete@2x.png │ ├── delete@3x.png │ ├── share@2x.png │ └── share@3x.png └── Classes │ ├── .gitkeep │ ├── CVLogButton.h │ ├── CVLoggerCell.h │ ├── CVLogger.h │ ├── CVLogManager.h │ ├── CVLog.h │ ├── CVLoggerViewController.h │ ├── CVLogManager.m │ ├── CVLog.m │ ├── CVLoggerCell.m │ ├── CVLogger.m │ └── CVLogButton.m ├── _Pods.xcodeproj ├── Example ├── Pods │ ├── Headers │ │ └── Private │ │ │ ├── CVLogger │ │ │ ├── CVLog.h │ │ │ ├── CVLogger.h │ │ │ ├── CVLogButton.h │ │ │ ├── CVLogManager.h │ │ │ ├── CVLoggerCell.h │ │ │ └── CVLoggerViewController.h │ │ │ ├── Expecta │ │ │ ├── Expecta.h │ │ │ ├── EXPDefines.h │ │ │ ├── EXPExpect.h │ │ │ ├── EXPMatcher.h │ │ │ ├── EXPFloatTuple.h │ │ │ ├── ExpectaObject.h │ │ │ ├── EXPDoubleTuple.h │ │ │ ├── EXPMatchers.h │ │ │ ├── ExpectaSupport.h │ │ │ ├── NSObject+Expecta.h │ │ │ ├── NSValue+Expecta.h │ │ │ ├── EXPUnsupportedObject.h │ │ │ ├── EXPBlockDefinedMatcher.h │ │ │ ├── EXPMatcherHelpers.h │ │ │ ├── EXPMatchers+beFalsy.h │ │ │ ├── EXPMatchers+beNil.h │ │ │ ├── EXPMatchers+contain.h │ │ │ ├── EXPMatchers+endWith.h │ │ │ ├── EXPMatchers+equal.h │ │ │ ├── EXPMatchers+match.h │ │ │ ├── EXPMatchers+raise.h │ │ │ ├── EXPMatchers+beCloseTo.h │ │ │ ├── EXPMatchers+beKindOf.h │ │ │ ├── EXPMatchers+beTruthy.h │ │ │ ├── EXPMatchers+beginWith.h │ │ │ ├── EXPMatchers+conformTo.h │ │ │ ├── EXPMatchers+respondTo.h │ │ │ ├── EXPMatchers+beInstanceOf.h │ │ │ ├── EXPMatchers+beLessThan.h │ │ │ ├── EXPMatchers+beSubclassOf.h │ │ │ ├── EXPMatchers+beSupersetOf.h │ │ │ ├── EXPMatchers+haveCountOf.h │ │ │ ├── EXPMatchers+beGreaterThan.h │ │ │ ├── EXPMatchers+beIdenticalTo.h │ │ │ ├── EXPMatchers+beInTheRangeOf.h │ │ │ ├── EXPMatchers+postNotification.h │ │ │ ├── EXPMatchers+raiseWithReason.h │ │ │ ├── EXPMatchers+beLessThanOrEqualTo.h │ │ │ └── EXPMatchers+beGreaterThanOrEqualTo.h │ │ │ ├── Specta │ │ │ ├── Specta.h │ │ │ ├── SPTSpec.h │ │ │ ├── SpectaDSL.h │ │ │ ├── SPTCallSite.h │ │ │ ├── SPTExample.h │ │ │ ├── SpectaTypes.h │ │ │ ├── SPTTestSuite.h │ │ │ ├── SpectaUtility.h │ │ │ ├── XCTest+Private.h │ │ │ ├── SPTExampleGroup.h │ │ │ ├── SPTCompiledExample.h │ │ │ ├── XCTestCase+Specta.h │ │ │ ├── SPTGlobalBeforeAfterEach.h │ │ │ ├── SPTSharedExampleGroups.h │ │ │ └── SPTExcludeGlobalBeforeAfterEach.h │ │ │ ├── Expecta+Snapshots │ │ │ ├── EXPMatchers+FBSnapshotTest.h │ │ │ └── ExpectaObject+FBSnapshotTest.h │ │ │ └── FBSnapshotTestCase │ │ │ ├── FBSnapshotTestCase.h │ │ │ ├── UIImage+Diff.h │ │ │ ├── UIImage+Compare.h │ │ │ ├── UIImage+Snapshot.h │ │ │ ├── FBSnapshotTestController.h │ │ │ └── FBSnapshotTestCasePlatform.h │ ├── Target Support Files │ │ ├── Specta │ │ │ ├── Specta-prefix.pch │ │ │ ├── Specta.modulemap │ │ │ ├── Specta-dummy.m │ │ │ ├── Specta.xcconfig │ │ │ ├── Specta-umbrella.h │ │ │ └── Info.plist │ │ ├── CVLogger │ │ │ ├── CVLogger-prefix.pch │ │ │ ├── CVLogger.modulemap │ │ │ ├── CVLogger-dummy.m │ │ │ ├── CVLogger.xcconfig │ │ │ ├── CVLogger-umbrella.h │ │ │ └── Info.plist │ │ ├── Expecta │ │ │ ├── Expecta-prefix.pch │ │ │ ├── Expecta.modulemap │ │ │ ├── Expecta-dummy.m │ │ │ ├── Expecta.xcconfig │ │ │ ├── Info.plist │ │ │ └── Expecta-umbrella.h │ │ ├── Expecta+Snapshots │ │ │ ├── Expecta+Snapshots-prefix.pch │ │ │ ├── Expecta+Snapshots.modulemap │ │ │ ├── Expecta+Snapshots-dummy.m │ │ │ ├── Expecta+Snapshots-umbrella.h │ │ │ ├── Expecta+Snapshots.xcconfig │ │ │ └── Info.plist │ │ ├── FBSnapshotTestCase │ │ │ ├── FBSnapshotTestCase-prefix.pch │ │ │ ├── FBSnapshotTestCase-dummy.m │ │ │ ├── FBSnapshotTestCase.modulemap │ │ │ ├── FBSnapshotTestCase.xcconfig │ │ │ └── Info.plist │ │ ├── Pods-CVLogger_Tests │ │ │ ├── Pods-CVLogger_Tests.modulemap │ │ │ ├── Pods-CVLogger_Tests-dummy.m │ │ │ ├── Pods-CVLogger_Tests-umbrella.h │ │ │ ├── Pods-CVLogger_Tests.debug.xcconfig │ │ │ ├── Pods-CVLogger_Tests.release.xcconfig │ │ │ └── Info.plist │ │ └── Pods-CVLogger_Example │ │ │ ├── Pods-CVLogger_Example.modulemap │ │ │ ├── Pods-CVLogger_Example-dummy.m │ │ │ ├── Pods-CVLogger_Example-umbrella.h │ │ │ ├── Pods-CVLogger_Example.debug.xcconfig │ │ │ ├── Pods-CVLogger_Example.release.xcconfig │ │ │ ├── Info.plist │ │ │ ├── Pods-CVLogger_Example-acknowledgements.markdown │ │ │ ├── Pods-CVLogger_Example-acknowledgements.plist │ │ │ └── Pods-CVLogger_Example-frameworks.sh │ ├── Expecta │ │ ├── Expecta │ │ │ ├── Matchers │ │ │ │ ├── EXPMatchers+beFalsy.h │ │ │ │ ├── EXPMatchers+beTruthy.h │ │ │ │ ├── EXPMatchers+endWith.h │ │ │ │ ├── EXPMatchers+match.h │ │ │ │ ├── EXPMatchers+respondTo.h │ │ │ │ ├── EXPMatchers+conformTo.h │ │ │ │ ├── EXPMatchers+beSupersetOf.h │ │ │ │ ├── EXPMatchers+beNil.h │ │ │ │ ├── EXPMatchers+raise.h │ │ │ │ ├── EXPMatcherHelpers.h │ │ │ │ ├── EXPMatchers+beginWith.h │ │ │ │ ├── EXPMatchers+beKindOf.h │ │ │ │ ├── EXPMatchers+raiseWithReason.h │ │ │ │ ├── EXPMatchers+beSubclassOf.h │ │ │ │ ├── EXPMatchers+postNotification.h │ │ │ │ ├── EXPMatchers+equal.h │ │ │ │ ├── EXPMatchers+beLessThan.h │ │ │ │ ├── EXPMatchers+contain.h │ │ │ │ ├── EXPMatchers+beGreaterThan.h │ │ │ │ ├── EXPMatchers+beLessThanOrEqualTo.h │ │ │ │ ├── EXPMatcherHelpers.m │ │ │ │ ├── EXPMatchers+beGreaterThanOrEqualTo.h │ │ │ │ ├── EXPMatchers+beInstanceOf.h │ │ │ │ ├── EXPMatchers+beCloseTo.h │ │ │ │ ├── EXPMatchers+beInTheRangeOf.h │ │ │ │ ├── EXPMatchers+beIdenticalTo.h │ │ │ │ ├── EXPMatchers+haveCountOf.h │ │ │ │ ├── EXPMatchers+beNil.m │ │ │ │ ├── EXPMatchers+beLessThan.m │ │ │ │ ├── EXPMatchers+beIdenticalTo.m │ │ │ │ ├── EXPMatchers+beGreaterThan.m │ │ │ │ ├── EXPMatchers+beLessThanOrEqualTo.m │ │ │ │ ├── EXPMatchers+beGreaterThanOrEqualTo.m │ │ │ │ ├── EXPMatchers+beFalsy.m │ │ │ │ ├── EXPMatchers+beTruthy.m │ │ │ │ ├── EXPMatchers.h │ │ │ │ ├── EXPMatchers+respondTo.m │ │ │ │ ├── EXPMatchers+beSubclassOf.m │ │ │ │ ├── EXPMatchers+beKindOf.m │ │ │ │ ├── EXPMatchers+conformTo.m │ │ │ │ ├── EXPMatchers+raise.m │ │ │ │ ├── EXPMatchers+beInstanceOf.m │ │ │ │ ├── EXPMatchers+beInTheRangeOf.m │ │ │ │ ├── EXPMatchers+contain.m │ │ │ │ ├── EXPMatchers+match.m │ │ │ │ ├── EXPMatchers+raiseWithReason.m │ │ │ │ ├── EXPMatchers+equal.m │ │ │ │ ├── EXPMatchers+haveCountOf.m │ │ │ │ ├── EXPMatchers+beCloseTo.m │ │ │ │ ├── EXPMatchers+endWith.m │ │ │ │ ├── EXPMatchers+beginWith.m │ │ │ │ ├── EXPMatchers+beSupersetOf.m │ │ │ │ └── EXPMatchers+postNotification.m │ │ │ ├── NSValue+Expecta.h │ │ │ ├── EXPUnsupportedObject.h │ │ │ ├── NSObject+Expecta.h │ │ │ ├── ExpectaObject.m │ │ │ ├── EXPFloatTuple.h │ │ │ ├── EXPDoubleTuple.h │ │ │ ├── EXPDefines.h │ │ │ ├── EXPMatcher.h │ │ │ ├── Expecta.h │ │ │ ├── EXPUnsupportedObject.m │ │ │ ├── NSValue+Expecta.m │ │ │ ├── EXPBlockDefinedMatcher.h │ │ │ ├── ExpectaObject.h │ │ │ ├── EXPBlockDefinedMatcher.m │ │ │ ├── EXPDoubleTuple.m │ │ │ ├── EXPFloatTuple.m │ │ │ ├── EXPExpect.h │ │ │ └── ExpectaSupport.h │ │ └── LICENSE │ ├── Specta │ │ ├── Specta │ │ │ └── Specta │ │ │ │ ├── XCTestCase+Specta.h │ │ │ │ ├── SpectaTypes.h │ │ │ │ ├── SPTCallSite.h │ │ │ │ ├── SPTCallSite.m │ │ │ │ ├── SPTExample.m │ │ │ │ ├── SPTGlobalBeforeAfterEach.h │ │ │ │ ├── SPTCompiledExample.m │ │ │ │ ├── SPTExcludeGlobalBeforeAfterEach.h │ │ │ │ ├── Specta.h │ │ │ │ ├── SPTExample.h │ │ │ │ ├── SPTSharedExampleGroups.h │ │ │ │ ├── SPTCompiledExample.h │ │ │ │ ├── SPTTestSuite.h │ │ │ │ ├── SPTTestSuite.m │ │ │ │ ├── SPTSpec.h │ │ │ │ ├── SpectaUtility.h │ │ │ │ ├── XCTest+Private.h │ │ │ │ ├── SPTExampleGroup.h │ │ │ │ ├── XCTestCase+Specta.m │ │ │ │ ├── SPTSharedExampleGroups.m │ │ │ │ ├── SpectaUtility.m │ │ │ │ └── SpectaDSL.h │ │ └── LICENSE │ ├── FBSnapshotTestCase │ │ ├── FBSnapshotTestCase.modulemap │ │ ├── FBSnapshotTestCase │ │ │ ├── Categories │ │ │ │ ├── UIImage+Snapshot.h │ │ │ │ ├── UIImage+Diff.h │ │ │ │ ├── UIImage+Compare.h │ │ │ │ ├── UIImage+Snapshot.m │ │ │ │ └── UIImage+Diff.m │ │ │ ├── FBSnapshotTestCasePlatform.h │ │ │ ├── FBSnapshotTestCasePlatform.m │ │ │ └── SwiftSupport.swift │ │ ├── LICENSE │ │ └── README.md │ ├── Expecta+Snapshots │ │ ├── ExpectaObject+FBSnapshotTest.h │ │ ├── EXPMatchers+FBSnapshotTest.h │ │ ├── ExpectaObject+FBSnapshotTest.m │ │ ├── LICENSE.md │ │ └── README.md │ ├── Local Podspecs │ │ └── CVLogger.podspec.json │ ├── Manifest.lock │ └── Pods.xcodeproj │ │ └── xcshareddata │ │ └── xcschemes │ │ └── CVLogger.xcscheme ├── Tests │ ├── en.lproj │ │ └── InfoPlist.strings │ ├── Tests-Prefix.pch │ ├── Tests-Info.plist │ └── Tests.m ├── CVLogger │ ├── en.lproj │ │ └── InfoPlist.strings │ ├── CVViewController.h │ ├── CVLogger-Prefix.pch │ ├── main.m │ ├── CVAppDelegate.h │ ├── CVViewController.m │ ├── Images.xcassets │ │ ├── LaunchImage.launchimage │ │ │ └── Contents.json │ │ └── AppIcon.appiconset │ │ │ └── Contents.json │ ├── CVLogger-Info.plist │ └── CVAppDelegate.m ├── CVLogger.xcodeproj │ └── project.xcworkspace │ │ └── contents.xcworkspacedata ├── CVLogger.xcworkspace │ └── contents.xcworkspacedata ├── Podfile └── Podfile.lock ├── .travis.yml ├── .gitignore ├── CVLogger.podspec ├── LICENSE └── README.md /Pod/Assets/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /Pod/Classes/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /_Pods.xcodeproj: -------------------------------------------------------------------------------- 1 | Example/Pods/Pods.xcodeproj -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/CVLogger/CVLog.h: -------------------------------------------------------------------------------- 1 | ../../../../../Pod/Classes/CVLog.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/Expecta.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Expecta.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/Specta.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/Specta.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/CVLogger/CVLogger.h: -------------------------------------------------------------------------------- 1 | ../../../../../Pod/Classes/CVLogger.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPDefines.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/EXPDefines.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPExpect.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/EXPExpect.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatcher.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/EXPMatcher.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTSpec.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTSpec.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SpectaDSL.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SpectaDSL.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/CVLogger/CVLogButton.h: -------------------------------------------------------------------------------- 1 | ../../../../../Pod/Classes/CVLogButton.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/CVLogger/CVLogManager.h: -------------------------------------------------------------------------------- 1 | ../../../../../Pod/Classes/CVLogManager.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/CVLogger/CVLoggerCell.h: -------------------------------------------------------------------------------- 1 | ../../../../../Pod/Classes/CVLoggerCell.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPFloatTuple.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/EXPFloatTuple.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/ExpectaObject.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/ExpectaObject.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTCallSite.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTCallSite.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTExample.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTExample.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SpectaTypes.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SpectaTypes.h -------------------------------------------------------------------------------- /Example/Tests/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /Example/CVLogger/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPDoubleTuple.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/EXPDoubleTuple.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/ExpectaSupport.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/ExpectaSupport.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/NSObject+Expecta.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/NSObject+Expecta.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/NSValue+Expecta.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/NSValue+Expecta.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTTestSuite.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTTestSuite.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SpectaUtility.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SpectaUtility.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/XCTest+Private.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/XCTest+Private.h -------------------------------------------------------------------------------- /Pod/Assets/close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/close.png -------------------------------------------------------------------------------- /Pod/Assets/delete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/delete.png -------------------------------------------------------------------------------- /Pod/Assets/share.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/share.png -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTExampleGroup.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTExampleGroup.h -------------------------------------------------------------------------------- /Pod/Assets/close@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/close@2x.png -------------------------------------------------------------------------------- /Pod/Assets/close@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/close@3x.png -------------------------------------------------------------------------------- /Pod/Assets/delete@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/delete@2x.png -------------------------------------------------------------------------------- /Pod/Assets/delete@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/delete@3x.png -------------------------------------------------------------------------------- /Pod/Assets/share@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/share@2x.png -------------------------------------------------------------------------------- /Pod/Assets/share@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cvillaseca/CVLogger/HEAD/Pod/Assets/share@3x.png -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPUnsupportedObject.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/EXPUnsupportedObject.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTCompiledExample.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTCompiledExample.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/XCTestCase+Specta.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/XCTestCase+Specta.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/CVLogger/CVLoggerViewController.h: -------------------------------------------------------------------------------- 1 | ../../../../../Pod/Classes/CVLoggerViewController.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPBlockDefinedMatcher.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/EXPBlockDefinedMatcher.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatcherHelpers.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatcherHelpers.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beFalsy.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beFalsy.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beNil.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beNil.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+contain.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+contain.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+endWith.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+endWith.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+equal.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+equal.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+match.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+match.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+raise.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+raise.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beCloseTo.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beCloseTo.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beKindOf.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beKindOf.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beTruthy.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beTruthy.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beginWith.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beginWith.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+conformTo.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+conformTo.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+respondTo.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+respondTo.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTGlobalBeforeAfterEach.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTGlobalBeforeAfterEach.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTSharedExampleGroups.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTSharedExampleGroups.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beInstanceOf.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beInstanceOf.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beLessThan.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beLessThan.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beSubclassOf.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beSubclassOf.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beSupersetOf.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beSupersetOf.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+haveCountOf.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+haveCountOf.h -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Specta/Specta-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #endif 4 | 5 | -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beGreaterThan.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beGreaterThan.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beIdenticalTo.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beIdenticalTo.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beInTheRangeOf.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beInTheRangeOf.h -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/CVLogger/CVLogger-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #endif 4 | 5 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta/Expecta-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #endif 4 | 5 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beFalsy.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beFalsy, (void)); 4 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beTruthy.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beTruthy, (void)); 4 | -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta+Snapshots/EXPMatchers+FBSnapshotTest.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta+Snapshots/EXPMatchers+FBSnapshotTest.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+postNotification.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+postNotification.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+raiseWithReason.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+raiseWithReason.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Specta/SPTExcludeGlobalBeforeAfterEach.h: -------------------------------------------------------------------------------- 1 | ../../../Specta/Specta/Specta/SPTExcludeGlobalBeforeAfterEach.h -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+endWith.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(endWith, (id expected)); 4 | -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta+Snapshots/ExpectaObject+FBSnapshotTest.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta+Snapshots/ExpectaObject+FBSnapshotTest.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beLessThanOrEqualTo.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beLessThanOrEqualTo.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/FBSnapshotTestCase/FBSnapshotTestCase.h: -------------------------------------------------------------------------------- 1 | ../../../FBSnapshotTestCase/FBSnapshotTestCase/FBSnapshotTestCase.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/FBSnapshotTestCase/UIImage+Diff.h: -------------------------------------------------------------------------------- 1 | ../../../FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Diff.h -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+match.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(match, (NSString *expected)); 4 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+respondTo.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(respondTo, (SEL expected)); 4 | -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/Expecta/EXPMatchers+beGreaterThanOrEqualTo.h: -------------------------------------------------------------------------------- 1 | ../../../Expecta/Expecta/Matchers/EXPMatchers+beGreaterThanOrEqualTo.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/FBSnapshotTestCase/UIImage+Compare.h: -------------------------------------------------------------------------------- 1 | ../../../FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Compare.h -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/FBSnapshotTestCase/UIImage+Snapshot.h: -------------------------------------------------------------------------------- 1 | ../../../FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Snapshot.h -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+conformTo.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(conformTo, (Protocol *expected)); 4 | -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/FBSnapshotTestCase/FBSnapshotTestController.h: -------------------------------------------------------------------------------- 1 | ../../../FBSnapshotTestCase/FBSnapshotTestCase/FBSnapshotTestController.h -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta+Snapshots/Expecta+Snapshots-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #endif 4 | 5 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/FBSnapshotTestCase/FBSnapshotTestCase-prefix.pch: -------------------------------------------------------------------------------- 1 | #ifdef __OBJC__ 2 | #import 3 | #endif 4 | 5 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beSupersetOf.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beSupersetOf, (id subset)); 4 | 5 | -------------------------------------------------------------------------------- /Example/Pods/Headers/Private/FBSnapshotTestCase/FBSnapshotTestCasePlatform.h: -------------------------------------------------------------------------------- 1 | ../../../FBSnapshotTestCase/FBSnapshotTestCase/FBSnapshotTestCasePlatform.h -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beNil.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beNil, (void)); 4 | EXPMatcherInterface(beNull, (void)); 5 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Specta/Specta.modulemap: -------------------------------------------------------------------------------- 1 | framework module Specta { 2 | umbrella header "Specta-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+raise.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(raise, (NSString *expectedExceptionName)); 4 | #define raiseAny() raise(nil) 5 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta/Expecta.modulemap: -------------------------------------------------------------------------------- 1 | framework module Expecta { 2 | umbrella header "Expecta-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatcherHelpers.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | BOOL EXPIsValuePointer(NSValue *value); 4 | BOOL EXPIsNumberFloat(NSNumber *number); 5 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beginWith.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beginWith, (id expected)); 4 | EXPMatcherInterface(startWith, (id expected)); 5 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/CVLogger/CVLogger.modulemap: -------------------------------------------------------------------------------- 1 | framework module CVLogger { 2 | umbrella header "CVLogger-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Specta/Specta-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Specta : NSObject 3 | @end 4 | @implementation PodsDummy_Specta 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beKindOf.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beKindOf, (Class expected)); 4 | EXPMatcherInterface(beAKindOf, (Class expected)); 5 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/NSValue+Expecta.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface NSValue (Expecta) 4 | 5 | @property (nonatomic) const char *_EXP_objCType; 6 | 7 | @end 8 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta/Expecta-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Expecta : NSObject 3 | @end 4 | @implementation PodsDummy_Expecta 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+raiseWithReason.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(raiseWithReason, (NSString *expectedExceptionName, NSString *expectedReason)); 4 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/XCTestCase+Specta.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface XCTestCase (Specta) 4 | 5 | - (void)spt_handleException:(NSException *)exception; 6 | 7 | @end 8 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/CVLogger/CVLogger-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_CVLogger : NSObject 3 | @end 4 | @implementation PodsDummy_CVLogger 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beSubclassOf.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beSubclassOf, (Class expected)); 4 | EXPMatcherInterface(beASubclassOf, (Class expected)); 5 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SpectaTypes.h: -------------------------------------------------------------------------------- 1 | @class SPTSpec; 2 | 3 | typedef void (^SPTVoidBlock)(); 4 | typedef void (^SPTSpecBlock)(SPTSpec *spec); 5 | typedef void (^SPTDictionaryBlock)(NSDictionary *dictionary); 6 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+postNotification.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(postNotification, (id expectedNotification)); 4 | EXPMatcherInterface(notify, (id expectedNotification)); 5 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta+Snapshots/Expecta+Snapshots.modulemap: -------------------------------------------------------------------------------- 1 | framework module Expecta_Snapshots { 2 | umbrella header "Expecta+Snapshots-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta+Snapshots/Expecta+Snapshots-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Expecta_Snapshots : NSObject 3 | @end 4 | @implementation PodsDummy_Expecta_Snapshots 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Tests/Pods-CVLogger_Tests.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_CVLogger_Tests { 2 | umbrella header "Pods-CVLogger_Tests-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/FBSnapshotTestCase/FBSnapshotTestCase-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_FBSnapshotTestCase : NSObject 3 | @end 4 | @implementation PodsDummy_FBSnapshotTestCase 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_CVLogger_Example { 2 | umbrella header "Pods-CVLogger_Example-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Tests/Pods-CVLogger_Tests-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_CVLogger_Tests : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_CVLogger_Tests 5 | @end 6 | -------------------------------------------------------------------------------- /Pod/Classes/CVLogButton.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVLogButton.h 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import 10 | 11 | @interface CVLogButton : UIButton 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /Example/CVLogger.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_CVLogger_Example : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_CVLogger_Example 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+equal.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_equal, (id expected)); 4 | EXPMatcherInterface(equal, (id expected)); // to aid code completion 5 | #define equal(...) _equal(EXPObjectify((__VA_ARGS__))) 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Tests/Pods-CVLogger_Tests-umbrella.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | 4 | FOUNDATION_EXPORT double Pods_CVLogger_TestsVersionNumber; 5 | FOUNDATION_EXPORT const unsigned char Pods_CVLogger_TestsVersionString[]; 6 | 7 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beLessThan.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_beLessThan, (id expected)); 4 | EXPMatcherInterface(beLessThan, (id expected)); 5 | 6 | #define beLessThan(expected) _beLessThan(EXPObjectify((expected))) 7 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+contain.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_contain, (id expected)); 4 | EXPMatcherInterface(contain, (id expected)); // to aid code completion 5 | #define contain(expected) _contain(EXPObjectify((expected))) 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example-umbrella.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | 4 | FOUNDATION_EXPORT double Pods_CVLogger_ExampleVersionNumber; 5 | FOUNDATION_EXPORT const unsigned char Pods_CVLogger_ExampleVersionString[]; 6 | 7 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beGreaterThan.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_beGreaterThan, (id expected)); 4 | EXPMatcherInterface(beGreaterThan, (id expected)); 5 | 6 | #define beGreaterThan(expected) _beGreaterThan(EXPObjectify((expected))) 7 | -------------------------------------------------------------------------------- /Example/Tests/Tests-Prefix.pch: -------------------------------------------------------------------------------- 1 | // The contents of this file are implicitly included at the beginning of every test case source file. 2 | 3 | #ifdef __OBJC__ 4 | 5 | @import Specta; 6 | @import Expecta; 7 | @import FBSnapshotTestCase; 8 | @import Expecta_Snapshots; 9 | 10 | #endif 11 | -------------------------------------------------------------------------------- /Pod/Classes/CVLoggerCell.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVLoggerCell.h 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import 10 | 11 | @interface CVLoggerCell : UITableViewCell 12 | 13 | @property (nonatomic, strong) UILabel *logLabel; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beLessThanOrEqualTo.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_beLessThanOrEqualTo, (id expected)); 4 | EXPMatcherInterface(beLessThanOrEqualTo, (id expected)); 5 | 6 | #define beLessThanOrEqualTo(expected) _beLessThanOrEqualTo(EXPObjectify((expected))) 7 | -------------------------------------------------------------------------------- /Example/CVLogger.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /Example/CVLogger/CVViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVViewController.h 3 | // CVLogger 4 | // 5 | // Created by Cristian Villaseca on 03/12/2016. 6 | // Copyright (c) 2016 Cristian Villaseca. All rights reserved. 7 | // 8 | 9 | @import UIKit; 10 | 11 | @interface CVViewController : UIViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatcherHelpers.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatcherHelpers.h" 2 | 3 | BOOL EXPIsValuePointer(NSValue *value) { 4 | return [value objCType][0] == @encode(void *)[0]; 5 | } 6 | 7 | BOOL EXPIsNumberFloat(NSNumber *number) { 8 | return strcmp([number objCType], @encode(float)) == 0; 9 | } 10 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beGreaterThanOrEqualTo.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_beGreaterThanOrEqualTo, (id expected)); 4 | EXPMatcherInterface(beGreaterThanOrEqualTo, (id expected)); 5 | 6 | #define beGreaterThanOrEqualTo(expected) _beGreaterThanOrEqualTo(EXPObjectify((expected))) 7 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beInstanceOf.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(beInstanceOf, (Class expected)); 4 | EXPMatcherInterface(beAnInstanceOf, (Class expected)); 5 | EXPMatcherInterface(beMemberOf, (Class expected)); 6 | EXPMatcherInterface(beAMemberOf, (Class expected)); 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/CVLogger/CVLogger.xcconfig: -------------------------------------------------------------------------------- 1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 2 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/CVLogger" "${PODS_ROOT}/Headers/Public" 3 | OTHER_LDFLAGS = -framework "UIKit" 4 | PODS_ROOT = ${SRCROOT} 5 | SKIP_INSTALL = YES -------------------------------------------------------------------------------- /Pod/Classes/CVLogger.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVLogger.h 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import 10 | 11 | #import "CVLog.h" 12 | 13 | @interface CVLogger : NSObject 14 | 15 | @property (nonatomic) NSInteger collapseHeight; 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPUnsupportedObject.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface EXPUnsupportedObject : NSObject { 4 | NSString *_type; 5 | } 6 | 7 | @property (nonatomic, retain) NSString *type; 8 | 9 | - (instancetype)initWithType:(NSString *)type NS_DESIGNATED_INITIALIZER; 10 | 11 | @end 12 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta+Snapshots/Expecta+Snapshots-umbrella.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #import "ExpectaObject+FBSnapshotTest.h" 4 | #import "EXPMatchers+FBSnapshotTest.h" 5 | 6 | FOUNDATION_EXPORT double Expecta_SnapshotsVersionNumber; 7 | FOUNDATION_EXPORT const unsigned char Expecta_SnapshotsVersionString[]; 8 | 9 | -------------------------------------------------------------------------------- /Pod/Classes/CVLogManager.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVLogManager.h 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import 10 | 11 | @interface CVLogManager : NSObject 12 | 13 | + (id)sharedManager; 14 | 15 | -(void) addLog:(NSString *) log; 16 | 17 | -(NSArray *) getLogs; 18 | 19 | -(void) removeLogs; 20 | 21 | @end 22 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/NSObject+Expecta.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface NSObject (Expecta) 4 | 5 | - (void)recordFailureWithDescription:(NSString *)description 6 | inFile:(NSString *)filename 7 | atLine:(NSUInteger)lineNumber 8 | expected:(BOOL)expected; 9 | 10 | @end 11 | -------------------------------------------------------------------------------- /Example/Podfile: -------------------------------------------------------------------------------- 1 | source 'https://github.com/CocoaPods/Specs.git' 2 | use_frameworks! 3 | 4 | target 'CVLogger_Example', :exclusive => true do 5 | pod 'CVLogger', :path => '../' 6 | end 7 | 8 | target 'CVLogger_Tests', :exclusive => true do 9 | pod 'CVLogger', :path => '../' 10 | 11 | pod 'Specta' 12 | pod 'Expecta' 13 | pod 'FBSnapshotTestCase' 14 | pod 'Expecta+Snapshots' 15 | end 16 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/ExpectaObject.m: -------------------------------------------------------------------------------- 1 | #import "ExpectaObject.h" 2 | 3 | @implementation Expecta 4 | 5 | static NSTimeInterval _asynchronousTestTimeout = 1.0; 6 | 7 | + (NSTimeInterval)asynchronousTestTimeout { 8 | return _asynchronousTestTimeout; 9 | } 10 | 11 | + (void)setAsynchronousTestTimeout:(NSTimeInterval)timeout { 12 | _asynchronousTestTimeout = timeout; 13 | } 14 | 15 | @end -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/CVLogger/CVLogger-umbrella.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #import "CVLog.h" 4 | #import "CVLogButton.h" 5 | #import "CVLogger.h" 6 | #import "CVLoggerCell.h" 7 | #import "CVLoggerViewController.h" 8 | #import "CVLogManager.h" 9 | 10 | FOUNDATION_EXPORT double CVLoggerVersionNumber; 11 | FOUNDATION_EXPORT const unsigned char CVLoggerVersionString[]; 12 | 13 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPFloatTuple.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface EXPFloatTuple : NSObject { 4 | float *_values; 5 | size_t _size; 6 | } 7 | 8 | @property (nonatomic, assign) float *values; 9 | @property (nonatomic, assign) size_t size; 10 | 11 | - (instancetype)initWithFloatValues:(float *)values size:(size_t)size NS_DESIGNATED_INITIALIZER; 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPDoubleTuple.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface EXPDoubleTuple : NSObject { 4 | double *_values; 5 | size_t _size; 6 | } 7 | 8 | @property (nonatomic, assign) double *values; 9 | @property (nonatomic, assign) size_t size; 10 | 11 | - (instancetype)initWithDoubleValues:(double *)values size:(size_t)size NS_DESIGNATED_INITIALIZER; 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beCloseTo.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_beCloseToWithin, (id expected, id within)); 4 | EXPMatcherInterface(beCloseToWithin, (id expected, id within)); 5 | 6 | #define beCloseTo(expected) _beCloseToWithin(EXPObjectify((expected)), nil) 7 | #define beCloseToWithin(expected, range) _beCloseToWithin(EXPObjectify((expected)), EXPObjectify((range))) 8 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTCallSite.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface SPTCallSite : NSObject 4 | 5 | @property (nonatomic, copy, readonly) NSString *file; 6 | @property (nonatomic, readonly) NSUInteger line; 7 | 8 | + (instancetype)callSiteWithFile:(NSString *)file line:(NSUInteger)line; 9 | 10 | - (instancetype)initWithFile:(NSString *)file line:(NSUInteger)line; 11 | 12 | @end 13 | -------------------------------------------------------------------------------- /Pod/Classes/CVLog.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVLog.h 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import 10 | 11 | #ifdef DEBUG 12 | #define NSLog(args...) CVLog(__FILE__,__LINE__,__PRETTY_FUNCTION__,args); 13 | #else 14 | #define NSLog(x...) 15 | #endif 16 | 17 | void CVLog(const char *file, int lineNumber, const char *functionName, NSString *format, ...); -------------------------------------------------------------------------------- /Example/CVLogger/CVLogger-Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header 3 | // 4 | // The contents of this file are implicitly included at the beginning of every source file. 5 | // 6 | 7 | #import 8 | 9 | #ifndef __IPHONE_5_0 10 | #warning "This project uses features only available in iOS SDK 5.0 and later." 11 | #endif 12 | 13 | #ifdef __OBJC__ 14 | @import UIKit; 15 | @import Foundation; 16 | #endif 17 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beInTheRangeOf.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_beInTheRangeOf, (id expectedLowerBound, id expectedUpperBound)); 4 | EXPMatcherInterface(beInTheRangeOf, (id expectedLowerBound, id expectedUpperBound)); 5 | 6 | #define beInTheRangeOf(expectedLowerBound, expectedUpperBound) _beInTheRangeOf(EXPObjectify((expectedLowerBound)), EXPObjectify((expectedUpperBound))) 7 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beIdenticalTo.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(_beIdenticalTo, (void *expected)); 4 | EXPMatcherInterface(beIdenticalTo, (void *expected)); // to aid code completion 5 | 6 | #if __has_feature(objc_arc) 7 | #define beIdenticalTo(expected) _beIdenticalTo((__bridge void*)expected) 8 | #else 9 | #define beIdenticalTo(expected) _beIdenticalTo(expected) 10 | #endif 11 | -------------------------------------------------------------------------------- /Example/CVLogger/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // CVLogger 4 | // 5 | // Created by Cristian Villaseca on 03/12/2016. 6 | // Copyright (c) 2016 Cristian Villaseca. All rights reserved. 7 | // 8 | 9 | @import UIKit; 10 | #import "CVAppDelegate.h" 11 | 12 | int main(int argc, char * argv[]) 13 | { 14 | @autoreleasepool { 15 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([CVAppDelegate class])); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta/Expecta.xcconfig: -------------------------------------------------------------------------------- 1 | ENABLE_BITCODE = NO 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$(PLATFORM_DIR)/Developer/Library/Frameworks" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/Expecta" "${PODS_ROOT}/Headers/Public" 5 | OTHER_LDFLAGS = -framework "Foundation" -framework "XCTest" 6 | PODS_ROOT = ${SRCROOT} 7 | SKIP_INSTALL = YES -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Specta/Specta.xcconfig: -------------------------------------------------------------------------------- 1 | ENABLE_BITCODE = NO 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$(PLATFORM_DIR)/Developer/Library/Frameworks" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/Specta" "${PODS_ROOT}/Headers/Public" 5 | OTHER_LDFLAGS = -framework "Foundation" -framework "XCTest" 6 | PODS_ROOT = ${SRCROOT} 7 | SKIP_INSTALL = YES -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPDefines.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXPDefines.h 3 | // Expecta 4 | // 5 | // Created by Luke Redpath on 26/03/2012. 6 | // Copyright (c) 2012 Peter Jihoon Kim. All rights reserved. 7 | // 8 | 9 | #ifndef Expecta_EXPDefines_h 10 | #define Expecta_EXPDefines_h 11 | 12 | typedef void (^EXPBasicBlock)(); 13 | typedef id (^EXPIdBlock)(); 14 | typedef BOOL (^EXPBoolBlock)(); 15 | typedef NSString *(^EXPStringBlock)(); 16 | 17 | #endif 18 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta+Snapshots/Expecta+Snapshots.xcconfig: -------------------------------------------------------------------------------- 1 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$(PLATFORM_DIR)/Developer/Library/Frameworks" 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 3 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/Expecta+Snapshots" "${PODS_ROOT}/Headers/Public" 4 | OTHER_LDFLAGS = -framework "Foundation" -framework "XCTest" 5 | PODS_ROOT = ${SRCROOT} 6 | SKIP_INSTALL = YES -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase.modulemap: -------------------------------------------------------------------------------- 1 | framework module FBSnapshotTestCase { 2 | umbrella header "FBSnapshotTestCase.h" 3 | 4 | export * 5 | module * { export * } 6 | 7 | header "FBSnapshotTestCase.h" 8 | header "FBSnapshotTestCasePlatform.h" 9 | header "FBSnapshotTestController.h" 10 | 11 | private header "UIImage+Compare.h" 12 | private header "UIImage+Diff.h" 13 | private header "UIImage+Snapshot.h" 14 | } 15 | 16 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTCallSite.m: -------------------------------------------------------------------------------- 1 | #import "SPTCallSite.h" 2 | 3 | @implementation SPTCallSite 4 | 5 | + (instancetype)callSiteWithFile:(NSString *)file line:(NSUInteger)line { 6 | return [[self alloc] initWithFile:file line:line]; 7 | } 8 | 9 | - (instancetype)initWithFile:(NSString *)file line:(NSUInteger)line { 10 | self = [super init]; 11 | if (self) { 12 | _file = file; 13 | _line = line; 14 | } 15 | return self; 16 | } 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /Example/CVLogger/CVAppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVAppDelegate.h 3 | // CVLogger 4 | // 5 | // Created by Cristian Villaseca on 03/12/2016. 6 | // Copyright (c) 2016 Cristian Villaseca. All rights reserved. 7 | // 8 | #import 9 | 10 | @import UIKit; 11 | 12 | @interface CVAppDelegate : UIResponder 13 | 14 | @property (strong, nonatomic) UIWindow *window; 15 | 16 | @property (strong, nonatomic) CVLogger *cvlogger; 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/FBSnapshotTestCase/FBSnapshotTestCase.modulemap: -------------------------------------------------------------------------------- 1 | framework module FBSnapshotTestCase { 2 | umbrella header "FBSnapshotTestCase.h" 3 | 4 | export * 5 | module * { export * } 6 | 7 | header "FBSnapshotTestCase.h" 8 | header "FBSnapshotTestCasePlatform.h" 9 | header "FBSnapshotTestController.h" 10 | 11 | private header "UIImage+Compare.h" 12 | private header "UIImage+Diff.h" 13 | private header "UIImage+Snapshot.h" 14 | } 15 | 16 | -------------------------------------------------------------------------------- /Example/Pods/Expecta+Snapshots/ExpectaObject+FBSnapshotTest.h: -------------------------------------------------------------------------------- 1 | // 2 | // ExpectaObject+FBSnapshotTest.h 3 | // Expecta+Snapshots 4 | // 5 | // Created by John Boiles on 8/3/15. 6 | // Copyright (c) 2015 Expecta+Snapshots All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface Expecta (FBSnapshotTest) 12 | 13 | + (void)setUsesDrawViewHierarchyInRect:(BOOL)usesDrawViewHierarchyInRect; 14 | 15 | + (BOOL)usesDrawViewHierarchyInRect; 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTExample.m: -------------------------------------------------------------------------------- 1 | #import "SPTExample.h" 2 | 3 | @implementation SPTExample 4 | 5 | - (id)initWithName:(NSString *)name callSite:(SPTCallSite *)callSite focused:(BOOL)focused block:(SPTVoidBlock)block { 6 | self = [super init]; 7 | if (self) { 8 | self.name = name; 9 | self.callSite = callSite; 10 | self.block = block; 11 | self.focused = focused; 12 | self.pending = block == nil; 13 | } 14 | return self; 15 | } 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /Pod/Classes/CVLoggerViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // CVLoggerViewController.h 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import 10 | 11 | @protocol CVLoggerDelegate 12 | 13 | -(void) CVLoggerDidClosed; 14 | 15 | @end 16 | 17 | @interface CVLoggerViewController : UIViewController 18 | 19 | @property (nonatomic) NSInteger collapseHeight; 20 | 21 | @property (nonatomic, weak) id delegate; 22 | 23 | @end 24 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+haveCountOf.h: -------------------------------------------------------------------------------- 1 | #import "Expecta.h" 2 | 3 | EXPMatcherInterface(haveCountOf, (NSUInteger expected)); 4 | EXPMatcherInterface(haveCount, (NSUInteger expected)); 5 | EXPMatcherInterface(haveACountOf, (NSUInteger expected)); 6 | EXPMatcherInterface(haveLength, (NSUInteger expected)); 7 | EXPMatcherInterface(haveLengthOf, (NSUInteger expected)); 8 | EXPMatcherInterface(haveALengthOf, (NSUInteger expected)); 9 | 10 | #define beEmpty() haveCountOf(0) 11 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPMatcher.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXPMatcher.h 3 | // Expecta 4 | // 5 | // Created by Luke Redpath on 26/03/2012. 6 | // Copyright (c) 2012 Peter Jihoon Kim. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @protocol EXPMatcher 12 | 13 | - (BOOL)matches:(id)actual; 14 | 15 | @optional 16 | - (BOOL)meetsPrerequesiteFor:(id)actual; 17 | - (NSString *)failureMessageForTo:(id)actual; 18 | - (NSString *)failureMessageForNotTo:(id)actual; 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example.debug.xcconfig: -------------------------------------------------------------------------------- 1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 2 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 3 | OTHER_CFLAGS = $(inherited) -iquote "$CONFIGURATION_BUILD_DIR/CVLogger.framework/Headers" 4 | OTHER_LDFLAGS = $(inherited) -framework "CVLogger" 5 | PODS_FRAMEWORK_BUILD_PATH = $(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)/Pods-CVLogger_Example 6 | PODS_ROOT = ${SRCROOT}/Pods -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTGlobalBeforeAfterEach.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2015 Specta Team. All rights reserved. 3 | */ 4 | #import 5 | 6 | // This protocol is used for whitelisting classes for global beforeEach and afterEach blocks. 7 | // If you want a class to participate in those just add this protocol to a category and it will be 8 | // included. 9 | @protocol SPTGlobalBeforeAfterEach 10 | 11 | @optional 12 | + (void)beforeEach; 13 | + (void)afterEach; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example.release.xcconfig: -------------------------------------------------------------------------------- 1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 2 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 3 | OTHER_CFLAGS = $(inherited) -iquote "$CONFIGURATION_BUILD_DIR/CVLogger.framework/Headers" 4 | OTHER_LDFLAGS = $(inherited) -framework "CVLogger" 5 | PODS_FRAMEWORK_BUILD_PATH = $(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)/Pods-CVLogger_Example 6 | PODS_ROOT = ${SRCROOT}/Pods -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTCompiledExample.m: -------------------------------------------------------------------------------- 1 | #import "SPTCompiledExample.h" 2 | 3 | @implementation SPTCompiledExample 4 | 5 | - (id)initWithName:(NSString *)name testCaseName:(NSString *)testCaseName block:(SPTSpecBlock)block pending:(BOOL)pending focused:(BOOL)focused { 6 | self = [super init]; 7 | if (self) { 8 | self.name = name; 9 | self.testCaseName = testCaseName; 10 | self.block = block; 11 | self.pending = pending; 12 | self.focused = focused; 13 | } 14 | return self; 15 | } 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTExcludeGlobalBeforeAfterEach.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2015 Specta Team. All rights reserved. 3 | */ 4 | #import 5 | 6 | // This protocol was used for blacklisting classes for global beforeEach and afterEach blocks. 7 | // Now, instead, classes are whitelisted by implementing the SPTGlobalBeforeAfterEach protocol. 8 | __deprecated_msg("Please whitelist classes instead with the SPTGlobalBeforeAfterEach protocol") 9 | @protocol SPTExcludeGlobalBeforeAfterEach 10 | @end 11 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Expecta.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | //! Project version number for Expecta. 4 | FOUNDATION_EXPORT double ExpectaVersionNumber; 5 | 6 | //! Project version string for Expecta. 7 | FOUNDATION_EXPORT const unsigned char ExpectaVersionString[]; 8 | 9 | #import 10 | #import 11 | #import 12 | 13 | // Enable shorthand by default 14 | #define expect(...) EXP_expect((__VA_ARGS__)) 15 | #define failure(...) EXP_failure((__VA_ARGS__)) 16 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPUnsupportedObject.m: -------------------------------------------------------------------------------- 1 | #import "EXPUnsupportedObject.h" 2 | 3 | #pragma clang diagnostic push 4 | #pragma clang diagnostic ignored "-Wobjc-designated-initializers" 5 | @implementation EXPUnsupportedObject 6 | #pragma clang diagnostic pop 7 | 8 | @synthesize type=_type; 9 | 10 | - (instancetype)initWithType:(NSString *)type { 11 | self = [super init]; 12 | if(self) { 13 | self.type = type; 14 | } 15 | return self; 16 | } 17 | 18 | - (void)dealloc { 19 | self.type = nil; 20 | [super dealloc]; 21 | } 22 | 23 | @end 24 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/Specta.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | //! Project version number for Specta. 5 | FOUNDATION_EXPORT double SpectaVersionNumber; 6 | 7 | //! Project version string for Specta. 8 | FOUNDATION_EXPORT const unsigned char SpectaVersionString[]; 9 | 10 | // In this header, you should import all the public headers of your framework using statements like #import 11 | 12 | #import 13 | #import 14 | #import 15 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/FBSnapshotTestCase/FBSnapshotTestCase.xcconfig: -------------------------------------------------------------------------------- 1 | ENABLE_BITCODE = NO 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$(PLATFORM_DIR)/Developer/Library/Frameworks" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/FBSnapshotTestCase" "${PODS_ROOT}/Headers/Public" 5 | OTHER_LDFLAGS = -framework "Foundation" -framework "QuartzCore" -framework "UIKit" -framework "XCTest" 6 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 7 | PODS_ROOT = ${SRCROOT} 8 | SKIP_INSTALL = YES -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTExample.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "SpectaTypes.h" 3 | 4 | @class SPTCallSite; 5 | 6 | @interface SPTExample : NSObject 7 | 8 | @property (nonatomic, copy) NSString *name; 9 | @property (nonatomic, retain) SPTCallSite *callSite; 10 | @property (nonatomic, copy) SPTVoidBlock block; 11 | 12 | @property (nonatomic) BOOL pending; 13 | @property (nonatomic, getter=isFocused) BOOL focused; 14 | 15 | - (id)initWithName:(NSString *)name callSite:(SPTCallSite *)callSite focused:(BOOL)focused block:(SPTVoidBlock)block; 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTSharedExampleGroups.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | #import 4 | 5 | @class _XCTestCaseImplementation; 6 | 7 | @class SPTExampleGroup; 8 | 9 | @interface SPTSharedExampleGroups : XCTestCase 10 | 11 | + (void)addSharedExampleGroupWithName:(NSString *)name block:(SPTDictionaryBlock)block exampleGroup:(SPTExampleGroup *)exampleGroup; 12 | + (SPTDictionaryBlock)sharedExampleGroupWithName:(NSString *)name exampleGroup:(SPTExampleGroup *)exampleGroup; 13 | 14 | - (void)sharedExampleGroups; 15 | 16 | @end 17 | 18 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beNil.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beNil.h" 2 | 3 | EXPMatcherImplementationBegin(beNil, (void)) { 4 | match(^BOOL{ 5 | return actual == nil; 6 | }); 7 | 8 | failureMessageForTo(^NSString *{ 9 | return [NSString stringWithFormat:@"expected: nil/null, got: %@", EXPDescribeObject(actual)]; 10 | }); 11 | 12 | failureMessageForNotTo(^NSString *{ 13 | return [NSString stringWithFormat:@"expected: not nil/null, got: %@", EXPDescribeObject(actual)]; 14 | }); 15 | } 16 | EXPMatcherImplementationEnd 17 | 18 | EXPMatcherAliasImplementation(beNull, beNil, (void)); 19 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTCompiledExample.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import "SpectaTypes.h" 3 | 4 | @interface SPTCompiledExample : NSObject 5 | 6 | @property (nonatomic, copy) NSString *name; 7 | @property (nonatomic, copy) NSString *testCaseName; 8 | @property (nonatomic, copy) SPTSpecBlock block; 9 | 10 | @property (nonatomic) BOOL pending; 11 | @property (nonatomic, getter=isFocused) BOOL focused; 12 | 13 | @property (nonatomic) SEL testMethodSelector; 14 | 15 | - (id)initWithName:(NSString *)name testCaseName:(NSString *)testCaseName block:(SPTSpecBlock)block pending:(BOOL)pending focused:(BOOL)focused; 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/NSValue+Expecta.m: -------------------------------------------------------------------------------- 1 | #import "NSValue+Expecta.h" 2 | #import 3 | #import "Expecta.h" 4 | 5 | EXPFixCategoriesBug(NSValue_Expecta); 6 | 7 | @implementation NSValue (Expecta) 8 | 9 | static char _EXP_typeKey; 10 | 11 | - (const char *)_EXP_objCType { 12 | return [(NSString *)objc_getAssociatedObject(self, &_EXP_typeKey) cStringUsingEncoding:NSASCIIStringEncoding]; 13 | } 14 | 15 | - (void)set_EXP_objCType:(const char *)_EXP_objCType { 16 | objc_setAssociatedObject(self, &_EXP_typeKey, 17 | @(_EXP_objCType), 18 | OBJC_ASSOCIATION_COPY_NONATOMIC); 19 | } 20 | 21 | @end 22 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTTestSuite.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @class 4 | SPTExample 5 | , SPTExampleGroup 6 | ; 7 | 8 | @interface SPTTestSuite : NSObject 9 | 10 | @property (nonatomic, strong) SPTExampleGroup *rootGroup; 11 | @property (nonatomic, strong) NSMutableArray *groupStack; 12 | @property (nonatomic, strong) NSArray *compiledExamples; 13 | @property (nonatomic, copy) NSString *fileName; 14 | @property (nonatomic) NSUInteger lineNumber; 15 | @property (nonatomic, getter = isDisabled) BOOL disabled; 16 | @property (nonatomic) BOOL hasFocusedExamples; 17 | 18 | - (SPTExampleGroup *)currentGroup; 19 | - (void)compile; 20 | 21 | @end 22 | -------------------------------------------------------------------------------- /Example/CVLogger/CVViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVViewController.m 3 | // CVLogger 4 | // 5 | // Created by Cristian Villaseca on 03/12/2016. 6 | // Copyright (c) 2016 Cristian Villaseca. All rights reserved. 7 | // 8 | 9 | #import "CVViewController.h" 10 | 11 | @interface CVViewController () 12 | 13 | @end 14 | 15 | @implementation CVViewController 16 | 17 | - (void)viewDidLoad 18 | { 19 | [super viewDidLoad]; 20 | // Do any additional setup after loading the view, typically from a nib. 21 | } 22 | 23 | - (void)didReceiveMemoryWarning 24 | { 25 | [super didReceiveMemoryWarning]; 26 | // Dispose of any resources that can be recreated. 27 | } 28 | 29 | @end 30 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | # references: 2 | # * http://www.objc.io/issue-6/travis-ci.html 3 | # * https://github.com/supermarin/xcpretty#usage 4 | 5 | language: objective-c 6 | osx_image: xcode7.2 7 | xcode_xcworkspace: CVLogger.xcworkspace 8 | # xcode_scheme: CVLogger-Example 9 | xcode_sdk: iphonesimulator9.2 10 | # cache: cocoapods 11 | #podfile: Example/Podfile 12 | #before_install: 13 | #- gem install cocoapods # Since Travis is not always on latest version 14 | #- pod install --project-directory=Example 15 | #script: 16 | #- set -o pipefail && xcodebuild test -workspace Example/CVLogger.xcworkspace -scheme CVLogger-Example -sdk iphonesimulator ONLY_ACTIVE_ARCH=NO | xcpretty 17 | #- pod lib lint 18 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Specta/Specta-umbrella.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #import "Specta.h" 4 | #import "SpectaDSL.h" 5 | #import "SpectaTypes.h" 6 | #import "SpectaUtility.h" 7 | #import "SPTCallSite.h" 8 | #import "SPTCompiledExample.h" 9 | #import "SPTExample.h" 10 | #import "SPTExampleGroup.h" 11 | #import "SPTExcludeGlobalBeforeAfterEach.h" 12 | #import "SPTGlobalBeforeAfterEach.h" 13 | #import "SPTSharedExampleGroups.h" 14 | #import "SPTSpec.h" 15 | #import "SPTTestSuite.h" 16 | #import "XCTest+Private.h" 17 | #import "XCTestCase+Specta.h" 18 | 19 | FOUNDATION_EXPORT double SpectaVersionNumber; 20 | FOUNDATION_EXPORT const unsigned char SpectaVersionString[]; 21 | 22 | -------------------------------------------------------------------------------- /Example/Pods/Expecta+Snapshots/EXPMatchers+FBSnapshotTest.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXPMatchers+FBSnapshotTest.h 3 | // Artsy 4 | // 5 | // Created by Daniel Doubrovkine on 1/14/14. 6 | // Copyright (c) 2014 Artsy Inc. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "ExpectaObject+FBSnapshotTest.h" 11 | 12 | @interface EXPExpectFBSnapshotTest : NSObject 13 | @end 14 | 15 | /// Set the default folder for image tests to run in 16 | extern void setGlobalReferenceImageDir(char *reference); 17 | 18 | EXPMatcherInterface(haveValidSnapshot, (void)); 19 | EXPMatcherInterface(recordSnapshot, (void)); 20 | 21 | EXPMatcherInterface(haveValidSnapshotNamed, (NSString *snapshot)); 22 | EXPMatcherInterface(recordSnapshotNamed, (NSString *snapshot)); 23 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # OS X 2 | .DS_Store 3 | 4 | # Xcode 5 | build/ 6 | *.pbxuser 7 | !default.pbxuser 8 | *.mode1v3 9 | !default.mode1v3 10 | *.mode2v3 11 | !default.mode2v3 12 | *.perspectivev3 13 | !default.perspectivev3 14 | xcuserdata 15 | *.xccheckout 16 | profile 17 | *.moved-aside 18 | DerivedData 19 | *.hmap 20 | *.ipa 21 | 22 | # Bundler 23 | .bundle 24 | 25 | Carthage 26 | # We recommend against adding the Pods directory to your .gitignore. However 27 | # you should judge for yourself, the pros and cons are mentioned at: 28 | # http://guides.cocoapods.org/using/using-cocoapods.html#should-i-ignore-the-pods-directory-in-source-control 29 | # 30 | # Note: if you ignore the Pods directory, make sure to uncomment 31 | # `pod install` in .travis.yml 32 | # 33 | # Pods/ 34 | -------------------------------------------------------------------------------- /Example/Tests/Tests-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundlePackageType 14 | BNDL 15 | CFBundleShortVersionString 16 | 1.0 17 | CFBundleSignature 18 | ???? 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beLessThan.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beLessThan.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_beLessThan, (id expected)) { 5 | match(^BOOL{ 6 | if ([actual respondsToSelector:@selector(compare:)]) { 7 | return [actual compare:expected] == NSOrderedAscending; 8 | } 9 | return NO; 10 | }); 11 | 12 | failureMessageForTo(^NSString *{ 13 | return [NSString stringWithFormat:@"expected: %@ to be less than %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 14 | }); 15 | 16 | failureMessageForNotTo(^NSString *{ 17 | return [NSString stringWithFormat:@"expected: %@ not to be less than %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 18 | }); 19 | } 20 | EXPMatcherImplementationEnd -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beIdenticalTo.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+equal.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_beIdenticalTo, (void *expected)) { 5 | match(^BOOL{ 6 | if(actual == expected) { 7 | return YES; 8 | } else if([actual isKindOfClass:[NSValue class]] && EXPIsValuePointer((NSValue *)actual)) { 9 | if([(NSValue *)actual pointerValue] == expected) { 10 | return YES; 11 | } 12 | } 13 | return NO; 14 | }); 15 | 16 | failureMessageForTo(^NSString *{ 17 | return [NSString stringWithFormat:@"expected: <%p>, got: <%p>", expected, actual]; 18 | }); 19 | 20 | failureMessageForNotTo(^NSString *{ 21 | return [NSString stringWithFormat:@"expected: not <%p>, got: <%p>", expected, actual]; 22 | }); 23 | } 24 | EXPMatcherImplementationEnd 25 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPBlockDefinedMatcher.h: -------------------------------------------------------------------------------- 1 | // 2 | // EXPRuntimeMatcher.h 3 | // Expecta 4 | // 5 | // Created by Luke Redpath on 26/03/2012. 6 | // Copyright (c) 2012 Peter Jihoon Kim. All rights reserved. 7 | // 8 | 9 | #import 10 | #import "EXPMatcher.h" 11 | #import "EXPDefines.h" 12 | 13 | @interface EXPBlockDefinedMatcher : NSObject { 14 | EXPBoolBlock prerequisiteBlock; 15 | EXPBoolBlock matchBlock; 16 | EXPStringBlock failureMessageForToBlock; 17 | EXPStringBlock failureMessageForNotToBlock; 18 | } 19 | 20 | @property(nonatomic, copy) EXPBoolBlock prerequisiteBlock; 21 | @property(nonatomic, copy) EXPBoolBlock matchBlock; 22 | @property(nonatomic, copy) EXPStringBlock failureMessageForToBlock; 23 | @property(nonatomic, copy) EXPStringBlock failureMessageForNotToBlock; 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beGreaterThan.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beGreaterThan.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_beGreaterThan, (id expected)) { 5 | match(^BOOL{ 6 | if ([actual respondsToSelector:@selector(compare:)]) { 7 | return [actual compare:expected] == NSOrderedDescending; 8 | } 9 | return NO; 10 | }); 11 | 12 | failureMessageForTo(^NSString *{ 13 | return [NSString stringWithFormat:@"expected: %@ to be greater than %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 14 | }); 15 | 16 | failureMessageForNotTo(^NSString *{ 17 | return [NSString stringWithFormat:@"expected: %@ not to be greater than %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 18 | }); 19 | } 20 | EXPMatcherImplementationEnd -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTTestSuite.m: -------------------------------------------------------------------------------- 1 | #import "SPTTestSuite.h" 2 | #import "SPTExampleGroup.h" 3 | #import "SPTCompiledExample.h" 4 | 5 | @implementation SPTTestSuite 6 | 7 | - (id)init { 8 | self = [super init]; 9 | if (self) { 10 | self.rootGroup = [[SPTExampleGroup alloc] init]; 11 | self.rootGroup.root = self.rootGroup; 12 | self.groupStack = [NSMutableArray arrayWithObject:self.rootGroup]; 13 | } 14 | return self; 15 | } 16 | 17 | - (SPTExampleGroup *)currentGroup { 18 | return [self.groupStack lastObject]; 19 | } 20 | 21 | - (void)compile { 22 | self.compiledExamples = [self.rootGroup compileExamplesWithStack:@[]]; 23 | for (SPTCompiledExample *example in self.compiledExamples) { 24 | if (example.focused) { 25 | self.hasFocusedExamples = YES; 26 | break; 27 | } 28 | } 29 | } 30 | 31 | @end 32 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beLessThanOrEqualTo.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beLessThanOrEqualTo.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_beLessThanOrEqualTo, (id expected)) { 5 | match(^BOOL{ 6 | if ([actual respondsToSelector:@selector(compare:)]) { 7 | return [actual compare:expected] != NSOrderedDescending; 8 | } 9 | return NO; 10 | }); 11 | 12 | failureMessageForTo(^NSString *{ 13 | return [NSString stringWithFormat:@"expected: %@ to be less than or equal to %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 14 | }); 15 | 16 | failureMessageForNotTo(^NSString *{ 17 | return [NSString stringWithFormat:@"expected: %@ not to be less than or equal to %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 18 | }); 19 | } 20 | EXPMatcherImplementationEnd -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beGreaterThanOrEqualTo.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beGreaterThanOrEqualTo.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_beGreaterThanOrEqualTo, (id expected)) { 5 | match(^BOOL{ 6 | if ([actual respondsToSelector:@selector(compare:)]) { 7 | return [actual compare:expected] != NSOrderedAscending; 8 | } 9 | return NO; 10 | }); 11 | 12 | failureMessageForTo(^NSString *{ 13 | return [NSString stringWithFormat:@"expected: %@ to be greater than or equal to %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 14 | }); 15 | 16 | failureMessageForNotTo(^NSString *{ 17 | return [NSString stringWithFormat:@"expected: %@ not to be greater than or equal to %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 18 | }); 19 | } 20 | EXPMatcherImplementationEnd -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTSpec.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @class 5 | SPTTestSuite 6 | , SPTCompiledExample 7 | ; 8 | 9 | @interface SPTSpec : XCTestCase 10 | 11 | @property (strong) XCTestCaseRun *spt_run; 12 | @property (nonatomic) BOOL spt_pending; 13 | @property (nonatomic) BOOL spt_skipped; 14 | 15 | + (BOOL)spt_isDisabled; 16 | + (void)spt_setDisabled:(BOOL)disabled; 17 | + (BOOL)spt_focusedExamplesExist; 18 | + (SEL)spt_convertToTestMethod:(SPTCompiledExample *)example; 19 | + (SPTTestSuite *)spt_testSuite; 20 | + (void)spt_setCurrentTestSuite; 21 | + (void)spt_unsetCurrentTestSuite; 22 | + (void)spt_setCurrentTestSuiteFileName:(NSString *)fileName lineNumber:(NSUInteger)lineNumber; 23 | 24 | - (void)spec; 25 | - (BOOL)spt_shouldRunExample:(SPTCompiledExample *)example; 26 | - (void)spt_runExample:(SPTCompiledExample *)example; 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Snapshot.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2015, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | * 9 | */ 10 | 11 | #import 12 | 13 | @interface UIImage (Snapshot) 14 | 15 | /// Uses renderInContext: to get a snapshot of the layer. 16 | + (UIImage *)fb_imageForLayer:(CALayer *)layer; 17 | 18 | /// Uses renderInContext: to get a snapshot of the view layer. 19 | + (UIImage *)fb_imageForViewLayer:(UIView *)view; 20 | 21 | /// Uses drawViewHierarchyInRect: to get a snapshot of the view and adds the view into a window if needed. 22 | + (UIImage *)fb_imageForView:(UIView *)view; 23 | 24 | @end 25 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beFalsy.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beFalsy.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(beFalsy, (void)) { 5 | match(^BOOL{ 6 | if([actual isKindOfClass:[NSNumber class]]) { 7 | return ![(NSNumber *)actual boolValue]; 8 | } else if([actual isKindOfClass:[NSValue class]]) { 9 | if(EXPIsValuePointer((NSValue *)actual)) { 10 | return ![(NSValue *)actual pointerValue]; 11 | } 12 | } 13 | return !actual; 14 | }); 15 | 16 | failureMessageForTo(^NSString *{ 17 | return [NSString stringWithFormat:@"expected: a falsy value, got: %@, which is truthy", EXPDescribeObject(actual)]; 18 | }); 19 | 20 | failureMessageForNotTo(^NSString *{ 21 | return [NSString stringWithFormat:@"expected: a non-falsy value, got: %@, which is falsy", EXPDescribeObject(actual)]; 22 | }); 23 | } 24 | EXPMatcherImplementationEnd 25 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SpectaUtility.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | extern NSString * const spt_kCurrentTestSuiteKey; 4 | extern NSString * const spt_kCurrentSpecKey; 5 | 6 | #define SPTCurrentTestSuite [[NSThread mainThread] threadDictionary][spt_kCurrentTestSuiteKey] 7 | #define SPTCurrentSpec [[NSThread mainThread] threadDictionary][spt_kCurrentSpecKey] 8 | #define SPTCurrentGroup [SPTCurrentTestSuite currentGroup] 9 | #define SPTGroupStack [SPTCurrentTestSuite groupStack] 10 | 11 | #define SPTReturnUnlessBlockOrNil(block) if ((block) && !SPTIsBlock((block))) return; 12 | #define SPTIsBlock(obj) [(obj) isKindOfClass:NSClassFromString(@"NSBlock")] 13 | 14 | BOOL spt_isSpecClass(Class aClass); 15 | NSString *spt_underscorize(NSString *string); 16 | NSArray *spt_map(NSArray *array, id (^block)(id obj, NSUInteger idx)); 17 | NSArray *spt_shuffle(NSArray *array); 18 | unsigned int spt_seed(); 19 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beTruthy.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beTruthy.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(beTruthy, (void)) { 5 | match(^BOOL{ 6 | if([actual isKindOfClass:[NSNumber class]]) { 7 | return !![(NSNumber *)actual boolValue]; 8 | } else if([actual isKindOfClass:[NSValue class]]) { 9 | if(EXPIsValuePointer((NSValue *)actual)) { 10 | return !![(NSValue *)actual pointerValue]; 11 | } 12 | } 13 | return !!actual; 14 | }); 15 | 16 | failureMessageForTo(^NSString *{ 17 | return [NSString stringWithFormat:@"expected: a truthy value, got: %@, which is falsy", EXPDescribeObject(actual)]; 18 | }); 19 | 20 | failureMessageForNotTo(^NSString *{ 21 | return [NSString stringWithFormat:@"expected: a non-truthy value, got: %@, which is truthy", EXPDescribeObject(actual)]; 22 | }); 23 | } 24 | EXPMatcherImplementationEnd 25 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Tests/Pods-CVLogger_Tests.debug.xcconfig: -------------------------------------------------------------------------------- 1 | EMBEDDED_CONTENT_CONTAINS_SWIFT = YES 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 3 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 4 | OTHER_CFLAGS = $(inherited) -iquote "$CONFIGURATION_BUILD_DIR/CVLogger.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/Expecta.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/Expecta_Snapshots.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/FBSnapshotTestCase.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/Specta.framework/Headers" 5 | OTHER_LDFLAGS = $(inherited) -framework "CVLogger" -framework "Expecta" -framework "Expecta_Snapshots" -framework "FBSnapshotTestCase" -framework "Specta" 6 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 7 | PODS_FRAMEWORK_BUILD_PATH = $(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)/Pods-CVLogger_Tests 8 | PODS_ROOT = ${SRCROOT}/Pods -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Tests/Pods-CVLogger_Tests.release.xcconfig: -------------------------------------------------------------------------------- 1 | EMBEDDED_CONTENT_CONTAINS_SWIFT = YES 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 3 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 4 | OTHER_CFLAGS = $(inherited) -iquote "$CONFIGURATION_BUILD_DIR/CVLogger.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/Expecta.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/Expecta_Snapshots.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/FBSnapshotTestCase.framework/Headers" -iquote "$CONFIGURATION_BUILD_DIR/Specta.framework/Headers" 5 | OTHER_LDFLAGS = $(inherited) -framework "CVLogger" -framework "Expecta" -framework "Expecta_Snapshots" -framework "FBSnapshotTestCase" -framework "Specta" 6 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 7 | PODS_FRAMEWORK_BUILD_PATH = $(BUILD_DIR)/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)/Pods-CVLogger_Tests 8 | PODS_ROOT = ${SRCROOT}/Pods -------------------------------------------------------------------------------- /Example/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - CVLogger (0.4) 3 | - Expecta (1.0.5) 4 | - Expecta+Snapshots (2.0.0): 5 | - Expecta (~> 1.0) 6 | - FBSnapshotTestCase/Core (~> 2.0.3) 7 | - FBSnapshotTestCase (2.0.7): 8 | - FBSnapshotTestCase/SwiftSupport (= 2.0.7) 9 | - FBSnapshotTestCase/Core (2.0.7) 10 | - FBSnapshotTestCase/SwiftSupport (2.0.7): 11 | - FBSnapshotTestCase/Core 12 | - Specta (1.0.5) 13 | 14 | DEPENDENCIES: 15 | - CVLogger (from `../`) 16 | - Expecta 17 | - Expecta+Snapshots 18 | - FBSnapshotTestCase 19 | - Specta 20 | 21 | EXTERNAL SOURCES: 22 | CVLogger: 23 | :path: "../" 24 | 25 | SPEC CHECKSUMS: 26 | CVLogger: 28ed5e8c082a3b42b00987ae8ce1a93b3468e5ff 27 | Expecta: e1c022fcd33910b6be89c291d2775b3fe27a89fe 28 | Expecta+Snapshots: 29b38dd695bc72a0ed2bea833937d78df41943ba 29 | FBSnapshotTestCase: 7e85180d0d141a0cf472352edda7e80d7eaeb547 30 | Specta: ac94d110b865115fe60ff2c6d7281053c6f8e8a2 31 | 32 | COCOAPODS: 0.39.0 33 | -------------------------------------------------------------------------------- /Example/Pods/Local Podspecs/CVLogger.podspec.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "CVLogger", 3 | "version": "0.4", 4 | "summary": "A library to show easily a log viewer in your app.", 5 | "description": "This library provides a app log viewer for your debug mode app", 6 | "homepage": "https://github.com/ravenx88/CVLogger", 7 | "screenshots": "https://cloud.githubusercontent.com/assets/7700085/13728275/5c5f224e-e912-11e5-9d37-b02210ef8a26.gif", 8 | "license": "MIT", 9 | "authors": { 10 | "Cristian Villaseca": "cvillaseca_basco@hotmail.com" 11 | }, 12 | "source": { 13 | "git": "https://github.com/ravenx88/CVLogger.git", 14 | "tag": "0.4" 15 | }, 16 | "social_media_url": "https://twitter.com/cristianviba", 17 | "platforms": { 18 | "ios": "7.0" 19 | }, 20 | "requires_arc": true, 21 | "source_files": "Pod/Classes/**/*", 22 | "resource_bundles": { 23 | "CVLogger": [ 24 | "Pod/Assets/*.png" 25 | ] 26 | }, 27 | "frameworks": "UIKit" 28 | } 29 | -------------------------------------------------------------------------------- /Example/Pods/Manifest.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - CVLogger (0.4) 3 | - Expecta (1.0.5) 4 | - Expecta+Snapshots (2.0.0): 5 | - Expecta (~> 1.0) 6 | - FBSnapshotTestCase/Core (~> 2.0.3) 7 | - FBSnapshotTestCase (2.0.7): 8 | - FBSnapshotTestCase/SwiftSupport (= 2.0.7) 9 | - FBSnapshotTestCase/Core (2.0.7) 10 | - FBSnapshotTestCase/SwiftSupport (2.0.7): 11 | - FBSnapshotTestCase/Core 12 | - Specta (1.0.5) 13 | 14 | DEPENDENCIES: 15 | - CVLogger (from `../`) 16 | - Expecta 17 | - Expecta+Snapshots 18 | - FBSnapshotTestCase 19 | - Specta 20 | 21 | EXTERNAL SOURCES: 22 | CVLogger: 23 | :path: "../" 24 | 25 | SPEC CHECKSUMS: 26 | CVLogger: 28ed5e8c082a3b42b00987ae8ce1a93b3468e5ff 27 | Expecta: e1c022fcd33910b6be89c291d2775b3fe27a89fe 28 | Expecta+Snapshots: 29b38dd695bc72a0ed2bea833937d78df41943ba 29 | FBSnapshotTestCase: 7e85180d0d141a0cf472352edda7e80d7eaeb547 30 | Specta: ac94d110b865115fe60ff2c6d7281053c6f8e8a2 31 | 32 | COCOAPODS: 0.39.0 33 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/CVLogger/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 0.4 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.5 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Specta/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.5 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta+Snapshots/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 2.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/FBSnapshotTestCase/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 2.0.7 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Tests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | ${PRODUCT_NAME} 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /CVLogger.podspec: -------------------------------------------------------------------------------- 1 | 2 | 3 | Pod::Spec.new do |s| 4 | s.name = "CVLogger" 5 | s.version = "0.4" 6 | s.summary = "A library to show easily a log viewer in your app." 7 | 8 | s.description = 'This library provides a app log viewer for your debug mode app' 9 | 10 | s.homepage = "https://github.com/ravenx88/CVLogger" 11 | s.screenshots = "https://cloud.githubusercontent.com/assets/7700085/13728275/5c5f224e-e912-11e5-9d37-b02210ef8a26.gif" 12 | s.license = 'MIT' 13 | s.author = { "Cristian Villaseca" => "cvillaseca_basco@hotmail.com" } 14 | s.source = { :git => "https://github.com/ravenx88/CVLogger.git", :tag => s.version.to_s } 15 | s.social_media_url = 'https://twitter.com/cristianviba' 16 | 17 | s.platform = :ios, '7.0' 18 | s.requires_arc = true 19 | 20 | s.source_files = 'Pod/Classes/**/*' 21 | s.resource_bundles = { 22 | 'CVLogger' => ['Pod/Assets/*.png'] 23 | } 24 | 25 | s.frameworks = 'UIKit' 26 | end 27 | -------------------------------------------------------------------------------- /Example/Pods/Expecta+Snapshots/ExpectaObject+FBSnapshotTest.m: -------------------------------------------------------------------------------- 1 | // 2 | // ExpectaObject+FBSnapshotTest.m 3 | // Expecta+Snapshots 4 | // 5 | // Created by John Boiles on 8/3/15. 6 | // Copyright (c) 2015 Expecta+Snapshots All rights reserved. 7 | // 8 | 9 | #import "ExpectaObject+FBSnapshotTest.h" 10 | #import 11 | 12 | static NSString const *kUsesDrawViewHierarchyInRectKey = @"ExpectaObject+FBSnapshotTest.usesDrawViewHierarchyInRect"; 13 | 14 | @implementation Expecta (FBSnapshotTest) 15 | 16 | + (void)setUsesDrawViewHierarchyInRect:(BOOL)usesDrawViewHierarchyInRect { 17 | objc_setAssociatedObject(self, (__bridge const void *)(kUsesDrawViewHierarchyInRectKey), @(usesDrawViewHierarchyInRect), OBJC_ASSOCIATION_RETAIN_NONATOMIC); 18 | } 19 | 20 | + (BOOL)usesDrawViewHierarchyInRect { 21 | NSNumber *usesDrawViewHierarchyInRect = objc_getAssociatedObject(self, (__bridge const void *)(kUsesDrawViewHierarchyInRectKey)); 22 | return usesDrawViewHierarchyInRect.boolValue; 23 | } 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers.h: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beNil.h" 2 | #import "EXPMatchers+equal.h" 3 | #import "EXPMatchers+beInstanceOf.h" 4 | #import "EXPMatchers+beKindOf.h" 5 | #import "EXPMatchers+beSubclassOf.h" 6 | #import "EXPMatchers+conformTo.h" 7 | #import "EXPMatchers+beTruthy.h" 8 | #import "EXPMatchers+beFalsy.h" 9 | #import "EXPMatchers+contain.h" 10 | #import "EXPMatchers+beSupersetOf.h" 11 | #import "EXPMatchers+haveCountOf.h" 12 | #import "EXPMatchers+beIdenticalTo.h" 13 | #import "EXPMatchers+beGreaterThan.h" 14 | #import "EXPMatchers+beGreaterThanOrEqualTo.h" 15 | #import "EXPMatchers+beLessThan.h" 16 | #import "EXPMatchers+beLessThanOrEqualTo.h" 17 | #import "EXPMatchers+beInTheRangeOf.h" 18 | #import "EXPMatchers+beCloseTo.h" 19 | #import "EXPMatchers+raise.h" 20 | #import "EXPMatchers+raiseWithReason.h" 21 | #import "EXPMatchers+respondTo.h" 22 | #import "EXPMatchers+postNotification.h" 23 | #import "EXPMatchers+beginWith.h" 24 | #import "EXPMatchers+endWith.h" 25 | #import "EXPMatchers+match.h" 26 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/XCTest+Private.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #if __IPHONE_OS_VERSION_MAX_ALLOWED >= 90000 || __MAC_OS_X_VERSION_MAX_ALLOWED >= 101100 4 | 5 | @interface XCTestObservationCenter (SPTTestSuspention) 6 | 7 | - (void)_suspendObservationForBlock:(void (^)(void))block; 8 | 9 | @end 10 | 11 | #else 12 | 13 | @interface XCTestObservationCenter : NSObject 14 | 15 | + (id)sharedObservationCenter; 16 | - (void)_suspendObservationForBlock:(void (^)(void))block; 17 | 18 | @end 19 | 20 | @protocol XCTestObservation 21 | @end 22 | 23 | 24 | #endif 25 | 26 | @interface _XCTestDriverTestObserver : NSObject 27 | 28 | - (void)stopObserving; 29 | - (void)startObserving; 30 | 31 | @end 32 | 33 | @interface _XCTestCaseImplementation : NSObject 34 | @end 35 | 36 | @interface XCTestCase () 37 | 38 | - (_XCTestCaseImplementation *)internalImplementation; 39 | - (void)_recordUnexpectedFailureWithDescription:(NSString *)description exception:(NSException *)exception; 40 | 41 | @end 42 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/ExpectaObject.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #define EXPObjectify(value) _EXPObjectify(@encode(__typeof__((value))), (value)) 4 | #define EXP_expect(actual) _EXP_expect(self, __LINE__, __FILE__, ^id{ __typeof__((actual)) strongActual = (actual); return EXPObjectify(strongActual); }) 5 | #define EXPMatcherInterface(matcherName, matcherArguments) _EXPMatcherInterface(matcherName, matcherArguments) 6 | #define EXPMatcherImplementationBegin(matcherName, matcherArguments) _EXPMatcherImplementationBegin(matcherName, matcherArguments) 7 | #define EXPMatcherImplementationEnd _EXPMatcherImplementationEnd 8 | #define EXPMatcherAliasImplementation(newMatcherName, oldMatcherName, matcherArguments) _EXPMatcherAliasImplementation(newMatcherName, oldMatcherName, matcherArguments) 9 | 10 | #define EXP_failure(message) EXPFail(self, __LINE__, __FILE__, message) 11 | 12 | 13 | @interface Expecta : NSObject 14 | 15 | + (NSTimeInterval)asynchronousTestTimeout; 16 | + (void)setAsynchronousTestTimeout:(NSTimeInterval)timeout; 17 | 18 | @end 19 | -------------------------------------------------------------------------------- /Example/Tests/Tests.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVLoggerTests.m 3 | // CVLoggerTests 4 | // 5 | // Created by Cristian Villaseca on 03/12/2016. 6 | // Copyright (c) 2016 Cristian Villaseca. All rights reserved. 7 | // 8 | 9 | // https://github.com/Specta/Specta 10 | 11 | SpecBegin(InitialSpecs) 12 | 13 | describe(@"these will fail", ^{ 14 | 15 | it(@"can do maths", ^{ 16 | expect(1).to.equal(2); 17 | }); 18 | 19 | it(@"can read", ^{ 20 | expect(@"number").to.equal(@"string"); 21 | }); 22 | 23 | it(@"will wait for 10 seconds and fail", ^{ 24 | waitUntil(^(DoneCallback done) { 25 | 26 | }); 27 | }); 28 | }); 29 | 30 | describe(@"these will pass", ^{ 31 | 32 | it(@"can do maths", ^{ 33 | expect(1).beLessThan(23); 34 | }); 35 | 36 | it(@"can read", ^{ 37 | expect(@"team").toNot.contain(@"I"); 38 | }); 39 | 40 | it(@"will wait and succeed", ^{ 41 | waitUntil(^(DoneCallback done) { 42 | done(); 43 | }); 44 | }); 45 | }); 46 | 47 | SpecEnd 48 | 49 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+respondTo.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+respondTo.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(respondTo, (SEL expected)) { 5 | BOOL actualIsNil = (actual == nil); 6 | BOOL expectedIsNull = (expected == NULL); 7 | 8 | prerequisite (^BOOL { 9 | return !(actualIsNil || expectedIsNull); 10 | }); 11 | 12 | match(^BOOL { 13 | return [actual respondsToSelector:expected]; 14 | }); 15 | 16 | failureMessageForTo(^NSString *{ 17 | if (actualIsNil) return @"the object is nil/null"; 18 | if (expectedIsNull) return @"the selector is null"; 19 | return [NSString stringWithFormat:@"expected: %@ to respond to %@", EXPDescribeObject(actual), NSStringFromSelector(expected)]; 20 | }); 21 | 22 | failureMessageForNotTo(^NSString *{ 23 | if (actualIsNil) return @"the object is nil/null"; 24 | if (expectedIsNull) return @"the selector is null"; 25 | return [NSString stringWithFormat:@"expected: %@ not to respond to %@", EXPDescribeObject(actual), NSStringFromSelector(expected)]; 26 | }); 27 | } 28 | EXPMatcherImplementationEnd 29 | -------------------------------------------------------------------------------- /Example/Pods/Specta/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2012-2014 Specta Team. 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | 21 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2016 Cristian Villaseca 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2011-2015 Specta Team - https://github.com/specta 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | -------------------------------------------------------------------------------- /Example/Pods/Expecta+Snapshots/LICENSE.md: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2014 Daniel Doubrovkine, Artsy Inc. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining 6 | a copy of this software and associated documentation files (the 7 | "Software"), to deal in the Software without restriction, including 8 | without limitation the rights to use, copy, modify, merge, publish, 9 | distribute, sublicense, and/or sell copies of the Software, and to 10 | permit persons to whom the Software is furnished to do so, subject to 11 | the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be 14 | included in all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 17 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 18 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 19 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 20 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 21 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 22 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 23 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beSubclassOf.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beSubclassOf.h" 2 | #import "NSValue+Expecta.h" 3 | #import 4 | 5 | EXPMatcherImplementationBegin(beSubclassOf, (Class expected)) { 6 | __block BOOL actualIsClass = YES; 7 | 8 | prerequisite(^BOOL { 9 | actualIsClass = class_isMetaClass(object_getClass(actual)); 10 | return actualIsClass; 11 | }); 12 | 13 | match(^BOOL{ 14 | return [actual isSubclassOfClass:expected]; 15 | }); 16 | 17 | failureMessageForTo(^NSString *{ 18 | if(!actualIsClass) return @"the actual value is not a Class"; 19 | return [NSString stringWithFormat:@"expected: a subclass of %@, got: a class %@, which is not a subclass of %@", [expected class], actual, [expected class]]; 20 | }); 21 | 22 | failureMessageForNotTo(^NSString *{ 23 | if(!actualIsClass) return @"the actual value is not a Class"; 24 | return [NSString stringWithFormat:@"expected: not a subclass of %@, got: a class %@, which is a subclass of %@", [expected class], actual, [expected class]]; 25 | }); 26 | } 27 | EXPMatcherImplementationEnd 28 | 29 | EXPMatcherAliasImplementation(beASubclassOf, beSubclassOf, (Class expected)); 30 | -------------------------------------------------------------------------------- /Pod/Classes/CVLogManager.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVLogManager.m 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #define kLogs @"savedLogs" 10 | 11 | #import "CVLogManager.h" 12 | 13 | @implementation CVLogManager 14 | 15 | + (id)sharedManager { 16 | static dispatch_once_t once; 17 | static id instance; 18 | dispatch_once(&once, ^{ 19 | instance = [self new]; 20 | }); 21 | return instance; 22 | } 23 | 24 | -(void) addLog:(NSString *) log { 25 | NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; 26 | NSMutableArray *logs = [[userDefaults objectForKey:kLogs] mutableCopy]; 27 | if (!logs) { 28 | logs = [NSMutableArray array]; 29 | } 30 | 31 | [logs addObject:log]; 32 | 33 | [userDefaults setObject:logs forKey:kLogs]; 34 | [userDefaults synchronize]; 35 | } 36 | 37 | -(NSArray *) getLogs { 38 | NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; 39 | return [[userDefaults objectForKey:kLogs] copy]; 40 | } 41 | 42 | -(void) removeLogs { 43 | NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; 44 | [userDefaults removeObjectForKey:kLogs]; 45 | } 46 | 47 | @end 48 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beKindOf.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beKindOf.h" 2 | 3 | EXPMatcherImplementationBegin(beKindOf, (Class expected)) { 4 | BOOL actualIsNil = (actual == nil); 5 | BOOL expectedIsNil = (expected == nil); 6 | 7 | prerequisite(^BOOL{ 8 | return !(actualIsNil || expectedIsNil); 9 | }); 10 | 11 | match(^BOOL{ 12 | return [actual isKindOfClass:expected]; 13 | }); 14 | 15 | failureMessageForTo(^NSString *{ 16 | if(actualIsNil) return @"the actual value is nil/null"; 17 | if(expectedIsNil) return @"the expected value is nil/null"; 18 | return [NSString stringWithFormat:@"expected: a kind of %@, got: an instance of %@, which is not a kind of %@", [expected class], [actual class], [expected class]]; 19 | }); 20 | 21 | failureMessageForNotTo(^NSString *{ 22 | if(actualIsNil) return @"the actual value is nil/null"; 23 | if(expectedIsNil) return @"the expected value is nil/null"; 24 | return [NSString stringWithFormat:@"expected: not a kind of %@, got: an instance of %@, which is a kind of %@", [expected class], [actual class], [expected class]]; 25 | }); 26 | } 27 | EXPMatcherImplementationEnd 28 | 29 | EXPMatcherAliasImplementation(beAKindOf, beKindOf, (Class expected)); 30 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+conformTo.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+conformTo.h" 2 | #import "NSValue+Expecta.h" 3 | #import 4 | 5 | EXPMatcherImplementationBegin(conformTo, (Protocol *expected)) { 6 | BOOL actualIsNil = (actual == nil); 7 | BOOL expectedIsNil = (expected == nil); 8 | 9 | prerequisite(^BOOL{ 10 | return !(actualIsNil || expectedIsNil); 11 | }); 12 | 13 | match(^BOOL{ 14 | return [actual conformsToProtocol:expected]; 15 | }); 16 | 17 | failureMessageForTo(^NSString *{ 18 | if(actualIsNil) return @"the object is nil/null"; 19 | if(expectedIsNil) return @"the protocol is nil/null"; 20 | 21 | NSString *name = NSStringFromProtocol(expected); 22 | return [NSString stringWithFormat:@"expected: %@ to conform to %@", actual, name]; 23 | }); 24 | 25 | failureMessageForNotTo(^NSString *{ 26 | if(actualIsNil) return @"the object is nil/null"; 27 | if(expectedIsNil) return @"the protocol is nil/null"; 28 | 29 | NSString *name = NSStringFromProtocol(expected); 30 | return [NSString stringWithFormat:@"expected: %@ not to conform to %@", actual, name]; 31 | }); 32 | } 33 | EXPMatcherImplementationEnd 34 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+raise.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+raise.h" 2 | #import "EXPDefines.h" 3 | 4 | EXPMatcherImplementationBegin(raise, (NSString *expectedExceptionName)) { 5 | __block NSException *exceptionCaught = nil; 6 | 7 | match(^BOOL{ 8 | BOOL expectedExceptionCaught = NO; 9 | @try { 10 | ((EXPBasicBlock)actual)(); 11 | } @catch(NSException *e) { 12 | exceptionCaught = e; 13 | expectedExceptionCaught = (expectedExceptionName == nil) || [[exceptionCaught name] isEqualToString:expectedExceptionName]; 14 | } 15 | return expectedExceptionCaught; 16 | }); 17 | 18 | failureMessageForTo(^NSString *{ 19 | return [NSString stringWithFormat:@"expected: %@, got: %@", 20 | expectedExceptionName ? expectedExceptionName : @"any exception", 21 | exceptionCaught ? [exceptionCaught name] : @"no exception"]; 22 | }); 23 | 24 | failureMessageForNotTo(^NSString *{ 25 | return [NSString stringWithFormat:@"expected: %@, got: %@", 26 | expectedExceptionName ? [NSString stringWithFormat:@"not %@", expectedExceptionName] : @"no exception", 27 | exceptionCaught ? [exceptionCaught name] : @"no exception"]; 28 | }); 29 | } 30 | EXPMatcherImplementationEnd 31 | -------------------------------------------------------------------------------- /Pod/Classes/CVLog.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVLog.m 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import "CVLog.h" 10 | #import "CVLogManager.h" 11 | 12 | void CVLog(const char *file, int lineNumber, const char *functionName, NSString *format, ...) 13 | { 14 | va_list ap; 15 | 16 | va_start (ap, format); 17 | 18 | if (![format hasSuffix: @"\n"]) 19 | { 20 | format = [format stringByAppendingString: @"\n"]; 21 | } 22 | 23 | NSString *body = [[NSString alloc] initWithFormat:format arguments:ap]; 24 | 25 | va_end (ap); 26 | 27 | NSString *fileName = [[NSString stringWithUTF8String:file] lastPathComponent]; 28 | 29 | NSString *localDate = [NSDateFormatter localizedStringFromDate:[NSDate date] dateStyle:NSDateFormatterMediumStyle timeStyle:NSDateFormatterMediumStyle]; 30 | 31 | fprintf(stderr, "(%s) (%s:%d) %s", 32 | [localDate UTF8String], [fileName UTF8String], 33 | lineNumber, [body UTF8String]); 34 | 35 | NSString *message = [NSString stringWithFormat:@"(%@) (%s:%d) %s", localDate 36 | , [fileName UTF8String], 37 | lineNumber, [body UTF8String]]; 38 | 39 | [[CVLogManager sharedManager] addLog:message]; 40 | } 41 | 42 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beInstanceOf.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beInstanceOf.h" 2 | 3 | EXPMatcherImplementationBegin(beInstanceOf, (Class expected)) { 4 | BOOL actualIsNil = (actual == nil); 5 | BOOL expectedIsNil = (expected == nil); 6 | 7 | prerequisite(^BOOL{ 8 | return !(actualIsNil || expectedIsNil); 9 | }); 10 | 11 | match(^BOOL{ 12 | return [actual isMemberOfClass:expected]; 13 | }); 14 | 15 | failureMessageForTo(^NSString *{ 16 | if(actualIsNil) return @"the actual value is nil/null"; 17 | if(expectedIsNil) return @"the expected value is nil/null"; 18 | return [NSString stringWithFormat:@"expected: an instance of %@, got: an instance of %@", [expected class], [actual class]]; 19 | }); 20 | 21 | failureMessageForNotTo(^NSString *{ 22 | if(actualIsNil) return @"the actual value is nil/null"; 23 | if(expectedIsNil) return @"the expected value is nil/null"; 24 | return [NSString stringWithFormat:@"expected: not an instance of %@, got: an instance of %@", [expected class], [actual class]]; 25 | }); 26 | } 27 | EXPMatcherImplementationEnd 28 | 29 | EXPMatcherAliasImplementation(beAnInstanceOf, beInstanceOf, (Class expected)); 30 | EXPMatcherAliasImplementation(beMemberOf, beInstanceOf, (Class expected)); 31 | EXPMatcherAliasImplementation(beAMemberOf, beInstanceOf, (Class expected)); 32 | -------------------------------------------------------------------------------- /Example/CVLogger/Images.xcassets/LaunchImage.launchimage/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "orientation" : "portrait", 5 | "idiom" : "iphone", 6 | "extent" : "full-screen", 7 | "minimum-system-version" : "7.0", 8 | "scale" : "2x" 9 | }, 10 | { 11 | "orientation" : "portrait", 12 | "idiom" : "iphone", 13 | "subtype" : "retina4", 14 | "extent" : "full-screen", 15 | "minimum-system-version" : "7.0", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "orientation" : "portrait", 20 | "idiom" : "ipad", 21 | "extent" : "full-screen", 22 | "minimum-system-version" : "7.0", 23 | "scale" : "1x" 24 | }, 25 | { 26 | "orientation" : "landscape", 27 | "idiom" : "ipad", 28 | "extent" : "full-screen", 29 | "minimum-system-version" : "7.0", 30 | "scale" : "1x" 31 | }, 32 | { 33 | "orientation" : "portrait", 34 | "idiom" : "ipad", 35 | "extent" : "full-screen", 36 | "minimum-system-version" : "7.0", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "orientation" : "landscape", 41 | "idiom" : "ipad", 42 | "extent" : "full-screen", 43 | "minimum-system-version" : "7.0", 44 | "scale" : "2x" 45 | } 46 | ], 47 | "info" : { 48 | "version" : 1, 49 | "author" : "xcode" 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPBlockDefinedMatcher.m: -------------------------------------------------------------------------------- 1 | // 2 | // EXPRuntimeMatcher.m 3 | // Expecta 4 | // 5 | // Created by Luke Redpath on 26/03/2012. 6 | // Copyright (c) 2012 Peter Jihoon Kim. All rights reserved. 7 | // 8 | 9 | #import "EXPBlockDefinedMatcher.h" 10 | 11 | @implementation EXPBlockDefinedMatcher 12 | 13 | - (void)dealloc 14 | { 15 | self.prerequisiteBlock = nil; 16 | self.matchBlock = nil; 17 | self.failureMessageForToBlock = nil; 18 | self.failureMessageForNotToBlock = nil; 19 | 20 | [super dealloc]; 21 | } 22 | 23 | @synthesize prerequisiteBlock; 24 | @synthesize matchBlock; 25 | @synthesize failureMessageForToBlock; 26 | @synthesize failureMessageForNotToBlock; 27 | 28 | - (BOOL)meetsPrerequesiteFor:(id)actual 29 | { 30 | if (self.prerequisiteBlock) { 31 | return self.prerequisiteBlock(); 32 | } 33 | return YES; 34 | } 35 | 36 | - (BOOL)matches:(id)actual 37 | { 38 | if (self.matchBlock) { 39 | return self.matchBlock(); 40 | } 41 | return YES; 42 | } 43 | 44 | - (NSString *)failureMessageForTo:(id)actual 45 | { 46 | if (self.failureMessageForToBlock) { 47 | return self.failureMessageForToBlock(); 48 | } 49 | return nil; 50 | } 51 | 52 | - (NSString *)failureMessageForNotTo:(id)actual 53 | { 54 | if (self.failureMessageForNotToBlock) { 55 | return self.failureMessageForNotToBlock(); 56 | } 57 | return nil; 58 | } 59 | 60 | @end 61 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example-acknowledgements.markdown: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | This application makes use of the following third party libraries: 3 | 4 | ## CVLogger 5 | 6 | Copyright (c) 2016 Cristian Villaseca 7 | 8 | Permission is hereby granted, free of charge, to any person obtaining a copy 9 | of this software and associated documentation files (the "Software"), to deal 10 | in the Software without restriction, including without limitation the rights 11 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 12 | copies of the Software, and to permit persons to whom the Software is 13 | furnished to do so, subject to the following conditions: 14 | 15 | The above copyright notice and this permission notice shall be included in 16 | all copies or substantial portions of the Software. 17 | 18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 19 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 20 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 21 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 22 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 23 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 24 | THE SOFTWARE. 25 | 26 | Generated by CocoaPods - http://cocoapods.org 27 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beInTheRangeOf.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beInTheRangeOf.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_beInTheRangeOf, (id expectedLowerBound, id expectedUpperBound)) { 5 | match(^BOOL{ 6 | if ([actual respondsToSelector:@selector(compare:)]) { 7 | NSComparisonResult compareLowerBound = [expectedLowerBound compare: actual]; 8 | NSComparisonResult compareUpperBound = [expectedUpperBound compare: actual]; 9 | if (compareLowerBound == NSOrderedSame) { 10 | return YES; 11 | } 12 | if (compareUpperBound == NSOrderedSame) { 13 | return YES; 14 | } 15 | if ((compareLowerBound == NSOrderedAscending) && (compareUpperBound == NSOrderedDescending)) { 16 | return YES; 17 | } 18 | } 19 | return NO; 20 | }); 21 | 22 | failureMessageForTo(^NSString *{ 23 | return [NSString stringWithFormat:@"expected: %@ to be in the range [%@, %@] (inclusive)", EXPDescribeObject(actual), EXPDescribeObject(expectedLowerBound), EXPDescribeObject(expectedUpperBound)]; 24 | }); 25 | 26 | failureMessageForNotTo(^NSString *{ 27 | return [NSString stringWithFormat:@"expected: %@ not to be in the range [%@, %@] (inclusive)", EXPDescribeObject(actual), EXPDescribeObject(expectedLowerBound), EXPDescribeObject(expectedUpperBound)]; 28 | }); 29 | } 30 | EXPMatcherImplementationEnd -------------------------------------------------------------------------------- /Example/CVLogger/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "29x29", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "29x29", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "40x40", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "40x40", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "60x60", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "60x60", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "idiom" : "ipad", 35 | "size" : "29x29", 36 | "scale" : "1x" 37 | }, 38 | { 39 | "idiom" : "ipad", 40 | "size" : "29x29", 41 | "scale" : "2x" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "size" : "40x40", 46 | "scale" : "1x" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "size" : "40x40", 51 | "scale" : "2x" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "size" : "76x76", 56 | "scale" : "1x" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "size" : "76x76", 61 | "scale" : "2x" 62 | }, 63 | { 64 | "idiom" : "ipad", 65 | "size" : "83.5x83.5", 66 | "scale" : "2x" 67 | } 68 | ], 69 | "info" : { 70 | "version" : 1, 71 | "author" : "xcode" 72 | } 73 | } -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPDoubleTuple.m: -------------------------------------------------------------------------------- 1 | #import "EXPDoubleTuple.h" 2 | 3 | #pragma clang diagnostic push 4 | #pragma clang diagnostic ignored "-Wobjc-designated-initializers" 5 | @implementation EXPDoubleTuple 6 | #pragma clang diagnostic pop 7 | 8 | @synthesize values = _values, size = _size; 9 | 10 | - (instancetype)initWithDoubleValues:(double *)values size:(size_t)size { 11 | if ((self = [super init])) { 12 | self.values = malloc(sizeof(double) * size); 13 | memcpy(self.values, values, sizeof(double) * size); 14 | self.size = size; 15 | } 16 | return self; 17 | } 18 | 19 | - (void)dealloc { 20 | free(self.values); 21 | [super dealloc]; 22 | } 23 | 24 | - (BOOL)isEqual:(id)object { 25 | if (![object isKindOfClass:[EXPDoubleTuple class]]) return NO; 26 | EXPDoubleTuple *other = (EXPDoubleTuple *)object; 27 | if (self.size == other.size) { 28 | for (int i = 0; i < self.size; ++i) { 29 | if (self.values[i] != other.values[i]) return NO; 30 | } 31 | return YES; 32 | } 33 | return NO; 34 | } 35 | 36 | - (NSString *)description { 37 | if (self.size == 2) { 38 | return [NSString stringWithFormat:@"Double tuple: {%f, %f}", self.values[0], self.values[1]]; 39 | } else if (self.size == 4) { 40 | return [NSString stringWithFormat:@"Double tuple: {%f, %f, %f, %f}", self.values[0], self.values[1], self.values[2], self.values[3]]; 41 | } 42 | return [NSString stringWithFormat:@"Double tuple of unexpected size %zd, sadly", self.size]; 43 | } 44 | 45 | @end 46 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Expecta/Expecta-umbrella.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #import "EXPBlockDefinedMatcher.h" 4 | #import "EXPDefines.h" 5 | #import "EXPDoubleTuple.h" 6 | #import "Expecta.h" 7 | #import "ExpectaObject.h" 8 | #import "ExpectaSupport.h" 9 | #import "EXPExpect.h" 10 | #import "EXPFloatTuple.h" 11 | #import "EXPMatcher.h" 12 | #import "EXPUnsupportedObject.h" 13 | #import "EXPMatcherHelpers.h" 14 | #import "EXPMatchers+beCloseTo.h" 15 | #import "EXPMatchers+beFalsy.h" 16 | #import "EXPMatchers+beginWith.h" 17 | #import "EXPMatchers+beGreaterThan.h" 18 | #import "EXPMatchers+beGreaterThanOrEqualTo.h" 19 | #import "EXPMatchers+beIdenticalTo.h" 20 | #import "EXPMatchers+beInstanceOf.h" 21 | #import "EXPMatchers+beInTheRangeOf.h" 22 | #import "EXPMatchers+beKindOf.h" 23 | #import "EXPMatchers+beLessThan.h" 24 | #import "EXPMatchers+beLessThanOrEqualTo.h" 25 | #import "EXPMatchers+beNil.h" 26 | #import "EXPMatchers+beSubclassOf.h" 27 | #import "EXPMatchers+beSupersetOf.h" 28 | #import "EXPMatchers+beTruthy.h" 29 | #import "EXPMatchers+conformTo.h" 30 | #import "EXPMatchers+contain.h" 31 | #import "EXPMatchers+endWith.h" 32 | #import "EXPMatchers+equal.h" 33 | #import "EXPMatchers+haveCountOf.h" 34 | #import "EXPMatchers+match.h" 35 | #import "EXPMatchers+postNotification.h" 36 | #import "EXPMatchers+raise.h" 37 | #import "EXPMatchers+raiseWithReason.h" 38 | #import "EXPMatchers+respondTo.h" 39 | #import "EXPMatchers.h" 40 | #import "NSObject+Expecta.h" 41 | #import "NSValue+Expecta.h" 42 | 43 | FOUNDATION_EXPORT double ExpectaVersionNumber; 44 | FOUNDATION_EXPORT const unsigned char ExpectaVersionString[]; 45 | 46 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTExampleGroup.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | #import "SpectaTypes.h" 4 | 5 | @class SPTExample; 6 | @class SPTCallSite; 7 | 8 | @interface SPTExampleGroup : NSObject 9 | 10 | @property (nonatomic, copy) NSString *name; 11 | @property (nonatomic, weak) SPTExampleGroup *root; 12 | @property (nonatomic, weak) SPTExampleGroup *parent; 13 | @property (nonatomic, strong) NSMutableArray *children; 14 | @property (nonatomic, strong) NSMutableArray *beforeAllArray; 15 | @property (nonatomic, strong) NSMutableArray *afterAllArray; 16 | @property (nonatomic, strong) NSMutableArray *beforeEachArray; 17 | @property (nonatomic, strong) NSMutableArray *afterEachArray; 18 | @property (nonatomic, strong) NSMutableDictionary *sharedExamples; 19 | @property (nonatomic) unsigned int exampleCount; 20 | @property (nonatomic) unsigned int ranExampleCount; 21 | @property (nonatomic) unsigned int pendingExampleCount; 22 | @property (nonatomic, getter=isFocused) BOOL focused; 23 | 24 | - (id)initWithName:(NSString *)name parent:(SPTExampleGroup *)parent root:(SPTExampleGroup *)root; 25 | 26 | - (SPTExampleGroup *)addExampleGroupWithName:(NSString *)name focused:(BOOL)focused; 27 | - (SPTExample *)addExampleWithName:(NSString *)name callSite:(SPTCallSite *)callSite focused:(BOOL)focused block:(SPTVoidBlock)block; 28 | 29 | - (void)addBeforeAllBlock:(SPTVoidBlock)block; 30 | - (void)addAfterAllBlock:(SPTVoidBlock)block; 31 | - (void)addBeforeEachBlock:(SPTVoidBlock)block; 32 | - (void)addAfterEachBlock:(SPTVoidBlock)block; 33 | 34 | - (NSArray *)compileExamplesWithStack:(NSArray *)stack; 35 | 36 | @end 37 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/LICENSE: -------------------------------------------------------------------------------- 1 | BSD License 2 | 3 | For the FBSnapshotTestCase software 4 | 5 | Copyright (c) 2013, Facebook, Inc. 6 | All rights reserved. 7 | 8 | Redistribution and use in source and binary forms, with or without 9 | modification, are permitted provided that the following conditions are met: 10 | 11 | * Redistributions of source code must retain the above copyright notice, 12 | this list of conditions and the following disclaimer. 13 | * Redistributions in binary form must reproduce the above copyright notice, 14 | this list of conditions and the following disclaimer in the documentation 15 | and/or other materials provided with the distribution. 16 | * Neither the name Facebook nor the names of its contributors may be used to 17 | endorse or promote products derived from this software without specific 18 | prior written permission. 19 | 20 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 21 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 22 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 23 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 24 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 25 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 26 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 27 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Diff.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by Gabriel Handford on 3/1/09. 3 | // Copyright 2009-2013. All rights reserved. 4 | // Created by John Boiles on 10/20/11. 5 | // Copyright (c) 2011. All rights reserved 6 | // Modified by Felix Schulze on 2/11/13. 7 | // Copyright 2013. All rights reserved. 8 | // 9 | // Permission is hereby granted, free of charge, to any person 10 | // obtaining a copy of this software and associated documentation 11 | // files (the "Software"), to deal in the Software without 12 | // restriction, including without limitation the rights to use, 13 | // copy, modify, merge, publish, distribute, sublicense, and/or sell 14 | // copies of the Software, and to permit persons to whom the 15 | // Software is furnished to do so, subject to the following 16 | // conditions: 17 | // 18 | // The above copyright notice and this permission notice shall be 19 | // included in all copies or substantial portions of the Software. 20 | // 21 | // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 22 | // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 23 | // OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 24 | // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 25 | // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 26 | // WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 27 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 28 | // OTHER DEALINGS IN THE SOFTWARE. 29 | // 30 | 31 | #import 32 | 33 | @interface UIImage (Diff) 34 | 35 | - (UIImage *)fb_diffWithImage:(UIImage *)image; 36 | 37 | @end 38 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+contain.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+contain.h" 2 | 3 | EXPMatcherImplementationBegin(_contain, (id expected)) { 4 | BOOL actualIsCompatible = [actual isKindOfClass:[NSString class]] || [actual conformsToProtocol:@protocol(NSFastEnumeration)]; 5 | BOOL expectedIsNil = (expected == nil); 6 | 7 | prerequisite(^BOOL{ 8 | return actualIsCompatible && !expectedIsNil; 9 | }); 10 | 11 | match(^BOOL{ 12 | if(actualIsCompatible) { 13 | if([actual isKindOfClass:[NSString class]]) { 14 | return [(NSString *)actual rangeOfString:[expected description]].location != NSNotFound; 15 | } else { 16 | for (id object in actual) { 17 | if ([object isEqual:expected]) { 18 | return YES; 19 | } 20 | } 21 | } 22 | } 23 | return NO; 24 | }); 25 | 26 | failureMessageForTo(^NSString *{ 27 | if(!actualIsCompatible) return [NSString stringWithFormat:@"%@ is not an instance of NSString or NSFastEnumeration", EXPDescribeObject(actual)]; 28 | if(expectedIsNil) return @"the expected value is nil/null"; 29 | return [NSString stringWithFormat:@"expected %@ to contain %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 30 | }); 31 | 32 | failureMessageForNotTo(^NSString *{ 33 | if(!actualIsCompatible) return [NSString stringWithFormat:@"%@ is not an instance of NSString or NSFastEnumeration", EXPDescribeObject(actual)]; 34 | if(expectedIsNil) return @"the expected value is nil/null"; 35 | return [NSString stringWithFormat:@"expected %@ not to contain %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 36 | }); 37 | } 38 | EXPMatcherImplementationEnd 39 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Compare.h: -------------------------------------------------------------------------------- 1 | // 2 | // Created by Gabriel Handford on 3/1/09. 3 | // Copyright 2009-2013. All rights reserved. 4 | // Created by John Boiles on 10/20/11. 5 | // Copyright (c) 2011. All rights reserved 6 | // Modified by Felix Schulze on 2/11/13. 7 | // Copyright 2013. All rights reserved. 8 | // 9 | // Permission is hereby granted, free of charge, to any person 10 | // obtaining a copy of this software and associated documentation 11 | // files (the "Software"), to deal in the Software without 12 | // restriction, including without limitation the rights to use, 13 | // copy, modify, merge, publish, distribute, sublicense, and/or sell 14 | // copies of the Software, and to permit persons to whom the 15 | // Software is furnished to do so, subject to the following 16 | // conditions: 17 | // 18 | // The above copyright notice and this permission notice shall be 19 | // included in all copies or substantial portions of the Software. 20 | // 21 | // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 22 | // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 23 | // OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 24 | // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 25 | // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 26 | // WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 27 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 28 | // OTHER DEALINGS IN THE SOFTWARE. 29 | // 30 | 31 | #import 32 | 33 | @interface UIImage (Compare) 34 | 35 | - (BOOL)fb_compareWithImage:(UIImage *)image tolerance:(CGFloat)tolerance; 36 | 37 | @end 38 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/FBSnapshotTestCasePlatform.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2015, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | * 9 | */ 10 | 11 | #import 12 | 13 | #ifdef __cplusplus 14 | extern "C" { 15 | #endif 16 | 17 | /** 18 | Returns a Boolean value that indicates whether the snapshot test is running in 64Bit. 19 | This method is a convenience for creating the suffixes set based on the architecture 20 | that the test is running. 21 | 22 | @returns @c YES if the test is running in 64bit, otherwise @c NO. 23 | */ 24 | BOOL FBSnapshotTestCaseIs64Bit(void); 25 | 26 | /** 27 | Returns a default set of strings that is used to append a suffix based on the architectures. 28 | @warning Do not modify this function, you can create your own and use it with @c FBSnapshotVerifyViewWithOptions() 29 | 30 | @returns An @c NSOrderedSet object containing strings that are appended to the reference images directory. 31 | */ 32 | NSOrderedSet *FBSnapshotTestCaseDefaultSuffixes(void); 33 | 34 | /** 35 | Returns a fully «normalized» file name. 36 | Strips punctuation and spaces and replaces them with @c _. Also appends the device model, running OS and screen size to the file name. 37 | 38 | @returns An @c NSString object containing the passed @c fileName with the device model, OS and screen size appended at the end. 39 | */ 40 | NSString *FBDeviceAgnosticNormalizedFileName(NSString *fileName); 41 | 42 | #ifdef __cplusplus 43 | } 44 | #endif 45 | -------------------------------------------------------------------------------- /Pod/Classes/CVLoggerCell.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVLoggerCell.m 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import "CVLoggerCell.h" 10 | 11 | @implementation CVLoggerCell 12 | 13 | - (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier { 14 | self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]; 15 | if (self) { 16 | 17 | self.logLabel = [[UILabel alloc] init]; 18 | self.logLabel.textColor = [UIColor blackColor]; 19 | self.logLabel.numberOfLines = 0; 20 | 21 | self.logLabel.font = [UIFont fontWithName:@"HelveticaNeue" size:14.0f]; 22 | self.logLabel.translatesAutoresizingMaskIntoConstraints = NO; 23 | [self.contentView addSubview:self.logLabel]; 24 | 25 | NSDictionary *views = @{@"logLabel":self.logLabel}; 26 | NSArray *constraints = [NSLayoutConstraint constraintsWithVisualFormat:@"H:|-8-[logLabel]-8-|" 27 | options: 0 28 | metrics:nil 29 | views:views]; 30 | [self.contentView addConstraints:constraints]; 31 | constraints = [NSLayoutConstraint constraintsWithVisualFormat:@"V:|-4-[logLabel]-4-|" 32 | options: 0 33 | metrics:nil 34 | views:views]; 35 | [self.contentView addConstraints:constraints]; 36 | } 37 | 38 | return self; 39 | } 40 | 41 | 42 | @end 43 | -------------------------------------------------------------------------------- /Example/CVLogger/CVLogger-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | ${PRODUCT_NAME} 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1.0 25 | LSRequiresIPhoneOS 26 | 27 | UILaunchStoryboardName 28 | Launch Screen 29 | UIMainStoryboardFile 30 | Main 31 | UIRequiredDeviceCapabilities 32 | 33 | armv7 34 | 35 | UISupportedInterfaceOrientations 36 | 37 | UIInterfaceOrientationPortrait 38 | UIInterfaceOrientationLandscapeLeft 39 | UIInterfaceOrientationLandscapeRight 40 | 41 | UISupportedInterfaceOrientations~ipad 42 | 43 | UIInterfaceOrientationPortrait 44 | UIInterfaceOrientationPortraitUpsideDown 45 | UIInterfaceOrientationLandscapeLeft 46 | UIInterfaceOrientationLandscapeRight 47 | 48 | 49 | 50 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/EXPFloatTuple.m: -------------------------------------------------------------------------------- 1 | #import "EXPFloatTuple.h" 2 | 3 | #pragma clang diagnostic push 4 | #pragma clang diagnostic ignored "-Wobjc-designated-initializers" 5 | @implementation EXPFloatTuple 6 | #pragma clang diagnostic pop 7 | 8 | @synthesize values = _values, size = _size; 9 | 10 | - (instancetype)initWithFloatValues:(float *)values size:(size_t)size { 11 | if ((self = [super init])) { 12 | self.values = malloc(sizeof(float) * size); 13 | memcpy(self.values, values, sizeof(float) * size); 14 | self.size = size; 15 | } 16 | return self; 17 | } 18 | 19 | - (void)dealloc { 20 | free(self.values); 21 | [super dealloc]; 22 | } 23 | 24 | - (BOOL)isEqual:(id)object { 25 | if (![object isKindOfClass:[EXPFloatTuple class]]) return NO; 26 | EXPFloatTuple *other = (EXPFloatTuple *)object; 27 | if (self.size == other.size) { 28 | for (int i = 0; i < self.size; ++i) { 29 | if (self.values[i] != other.values[i]) return NO; 30 | } 31 | return YES; 32 | } 33 | return NO; 34 | } 35 | 36 | - (NSUInteger)hash 37 | { 38 | NSUInteger prime = 31; 39 | NSUInteger hash = 0; 40 | for (int i=0; i 2 | #import "EXPMatcher.h" 3 | #import "EXPDefines.h" 4 | 5 | @interface EXPExpect : NSObject { 6 | EXPIdBlock _actualBlock; 7 | id _testCase; 8 | int _lineNumber; 9 | char *_fileName; 10 | BOOL _negative; 11 | BOOL _asynchronous; 12 | NSTimeInterval _timeout; 13 | } 14 | 15 | @property(nonatomic, copy) EXPIdBlock actualBlock; 16 | @property(nonatomic, readonly) id actual; 17 | @property(nonatomic, assign) id testCase; 18 | @property(nonatomic) int lineNumber; 19 | @property(nonatomic) const char *fileName; 20 | @property(nonatomic) BOOL negative; 21 | @property(nonatomic) BOOL asynchronous; 22 | @property(nonatomic) NSTimeInterval timeout; 23 | 24 | @property(nonatomic, readonly) EXPExpect *to; 25 | @property(nonatomic, readonly) EXPExpect *toNot; 26 | @property(nonatomic, readonly) EXPExpect *notTo; 27 | @property(nonatomic, readonly) EXPExpect *will; 28 | @property(nonatomic, readonly) EXPExpect *willNot; 29 | @property(nonatomic, readonly) EXPExpect *(^after)(NSTimeInterval timeInterval); 30 | 31 | - (instancetype)initWithActualBlock:(id)actualBlock testCase:(id)testCase lineNumber:(int)lineNumber fileName:(const char *)fileName NS_DESIGNATED_INITIALIZER; 32 | + (EXPExpect *)expectWithActualBlock:(id)actualBlock testCase:(id)testCase lineNumber:(int)lineNumber fileName:(const char *)fileName; 33 | 34 | - (void)applyMatcher:(id)matcher; 35 | - (void)applyMatcher:(id)matcher to:(NSObject **)actual; 36 | 37 | @end 38 | 39 | @interface EXPDynamicPredicateMatcher : NSObject { 40 | EXPExpect *_expectation; 41 | SEL _selector; 42 | } 43 | - (instancetype)initWithExpectation:(EXPExpect *)expectation selector:(SEL)selector NS_DESIGNATED_INITIALIZER; 44 | @property (nonatomic, readonly, copy) void (^dispatch)(void); 45 | @end 46 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/FBSnapshotTestCasePlatform.m: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2015, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | * 9 | */ 10 | 11 | #import 12 | #import 13 | 14 | BOOL FBSnapshotTestCaseIs64Bit(void) 15 | { 16 | #if __LP64__ 17 | return YES; 18 | #else 19 | return NO; 20 | #endif 21 | } 22 | 23 | NSOrderedSet *FBSnapshotTestCaseDefaultSuffixes(void) 24 | { 25 | NSMutableOrderedSet *suffixesSet = [[NSMutableOrderedSet alloc] init]; 26 | [suffixesSet addObject:@"_32"]; 27 | [suffixesSet addObject:@"_64"]; 28 | if (FBSnapshotTestCaseIs64Bit()) { 29 | return [suffixesSet reversedOrderedSet]; 30 | } 31 | return [suffixesSet copy]; 32 | } 33 | 34 | NSString *FBDeviceAgnosticNormalizedFileName(NSString *fileName) 35 | { 36 | UIDevice *device = [UIDevice currentDevice]; 37 | CGSize screenSize = [[UIApplication sharedApplication] keyWindow].bounds.size; 38 | NSString *os = device.systemVersion; 39 | 40 | fileName = [NSString stringWithFormat:@"%@_%@%@_%.0fx%.0f", fileName, device.model, os, screenSize.width, screenSize.height]; 41 | 42 | NSMutableCharacterSet *invalidCharacters = [NSMutableCharacterSet new]; 43 | [invalidCharacters formUnionWithCharacterSet:[NSCharacterSet whitespaceCharacterSet]]; 44 | [invalidCharacters formUnionWithCharacterSet:[NSCharacterSet punctuationCharacterSet]]; 45 | NSArray *validComponents = [fileName componentsSeparatedByCharactersInSet:invalidCharacters]; 46 | fileName = [validComponents componentsJoinedByString:@"_"]; 47 | 48 | return fileName; 49 | } -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+equal.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+equal.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_equal, (id expected)) { 5 | match(^BOOL{ 6 | if((actual == expected) || [actual isEqual:expected]) { 7 | return YES; 8 | } else if([actual isKindOfClass:[NSNumber class]] && [expected isKindOfClass:[NSNumber class]]) { 9 | if([actual isKindOfClass:[NSDecimalNumber class]] || [expected isKindOfClass:[NSDecimalNumber class]]) { 10 | NSDecimalNumber *actualDecimalNumber = [NSDecimalNumber decimalNumberWithDecimal:[(NSNumber *) actual decimalValue]]; 11 | NSDecimalNumber *expectedDecimalNumber = [NSDecimalNumber decimalNumberWithDecimal:[(NSNumber *) expected decimalValue]]; 12 | return [actualDecimalNumber isEqualToNumber:expectedDecimalNumber]; 13 | } 14 | else { 15 | if(EXPIsNumberFloat((NSNumber *)actual) || EXPIsNumberFloat((NSNumber *)expected)) { 16 | return [(NSNumber *)actual floatValue] == [(NSNumber *)expected floatValue]; 17 | } 18 | } 19 | } 20 | return NO; 21 | }); 22 | 23 | failureMessageForTo(^NSString *{ 24 | NSString *expectedDescription = EXPDescribeObject(expected); 25 | NSString *actualDescription = EXPDescribeObject(actual); 26 | 27 | if (![expectedDescription isEqualToString:actualDescription]) { 28 | return [NSString stringWithFormat:@"expected: %@, got: %@", EXPDescribeObject(expected), EXPDescribeObject(actual)]; 29 | } else { 30 | return [NSString stringWithFormat:@"expected (%@): %@, got (%@): %@", NSStringFromClass([expected class]), EXPDescribeObject(expected), NSStringFromClass([actual class]), EXPDescribeObject(actual)]; 31 | } 32 | }); 33 | 34 | failureMessageForNotTo(^NSString *{ 35 | return [NSString stringWithFormat:@"expected: not %@, got: %@", EXPDescribeObject(expected), EXPDescribeObject(actual)]; 36 | }); 37 | } 38 | EXPMatcherImplementationEnd 39 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+haveCountOf.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+haveCountOf.h" 2 | 3 | EXPMatcherImplementationBegin(haveCountOf, (NSUInteger expected)) { 4 | BOOL actualIsStringy = [actual isKindOfClass:[NSString class]] || [actual isKindOfClass:[NSAttributedString class]]; 5 | BOOL actualIsCompatible = actualIsStringy || [actual respondsToSelector:@selector(count)]; 6 | 7 | prerequisite(^BOOL{ 8 | return actualIsCompatible; 9 | }); 10 | 11 | NSUInteger (^count)(id) = ^(id actual) { 12 | if(actualIsStringy) { 13 | return [actual length]; 14 | } else { 15 | return [actual count]; 16 | } 17 | }; 18 | 19 | match(^BOOL{ 20 | if(actualIsCompatible) { 21 | return count(actual) == expected; 22 | } 23 | return NO; 24 | }); 25 | 26 | failureMessageForTo(^NSString *{ 27 | if(!actualIsCompatible) return [NSString stringWithFormat:@"%@ is not an instance of NSString, NSAttributedString, NSArray, NSSet, NSOrderedSet, or NSDictionary", EXPDescribeObject(actual)]; 28 | return [NSString stringWithFormat:@"expected %@ to have a count of %zi but got %zi", EXPDescribeObject(actual), expected, count(actual)]; 29 | }); 30 | 31 | failureMessageForNotTo(^NSString *{ 32 | if(!actualIsCompatible) return [NSString stringWithFormat:@"%@ is not an instance of NSString, NSAttributedString, NSArray, NSSet, NSOrderedSet, or NSDictionary", EXPDescribeObject(actual)]; 33 | return [NSString stringWithFormat:@"expected %@ not to have a count of %zi", EXPDescribeObject(actual), expected]; 34 | }); 35 | } 36 | EXPMatcherImplementationEnd 37 | 38 | EXPMatcherAliasImplementation(haveCount, haveCountOf, (NSUInteger expected)); 39 | EXPMatcherAliasImplementation(haveACountOf, haveCountOf, (NSUInteger expected)); 40 | EXPMatcherAliasImplementation(haveLength, haveCountOf, (NSUInteger expected)); 41 | EXPMatcherAliasImplementation(haveLengthOf, haveCountOf, (NSUInteger expected)); 42 | EXPMatcherAliasImplementation(haveALengthOf, haveCountOf, (NSUInteger expected)); 43 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beCloseTo.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beCloseTo.h" 2 | #import "EXPMatcherHelpers.h" 3 | 4 | EXPMatcherImplementationBegin(_beCloseToWithin, (id expected, id within)) { 5 | prerequisite(^BOOL{ 6 | return [actual isKindOfClass:[NSNumber class]] && 7 | [expected isKindOfClass:[NSNumber class]] && 8 | ([within isKindOfClass:[NSNumber class]] || (within == nil)); 9 | }); 10 | 11 | match(^BOOL{ 12 | double actualValue = [actual doubleValue]; 13 | double expectedValue = [expected doubleValue]; 14 | 15 | if (within != nil) { 16 | double withinValue = [within doubleValue]; 17 | double lowerBound = expectedValue - withinValue; 18 | double upperBound = expectedValue + withinValue; 19 | return (actualValue >= lowerBound) && (actualValue <= upperBound); 20 | } else { 21 | double diff = fabs(actualValue - expectedValue); 22 | actualValue = fabs(actualValue); 23 | expectedValue = fabs(expectedValue); 24 | double largest = (expectedValue > actualValue) ? expectedValue : actualValue; 25 | return (diff <= largest * FLT_EPSILON); 26 | } 27 | }); 28 | 29 | failureMessageForTo(^NSString *{ 30 | if (within) { 31 | return [NSString stringWithFormat:@"expected %@ to be close to %@ within %@", 32 | EXPDescribeObject(actual), EXPDescribeObject(expected), EXPDescribeObject(within)]; 33 | } else { 34 | return [NSString stringWithFormat:@"expected %@ to be close to %@", 35 | EXPDescribeObject(actual), EXPDescribeObject(expected)]; 36 | } 37 | }); 38 | 39 | failureMessageForNotTo(^NSString *{ 40 | if (within) { 41 | return [NSString stringWithFormat:@"expected %@ not to be close to %@ within %@", 42 | EXPDescribeObject(actual), EXPDescribeObject(expected), EXPDescribeObject(within)]; 43 | } else { 44 | return [NSString stringWithFormat:@"expected %@ not to be close to %@", 45 | EXPDescribeObject(actual), EXPDescribeObject(expected)]; 46 | } 47 | }); 48 | } 49 | EXPMatcherImplementationEnd -------------------------------------------------------------------------------- /Pod/Classes/CVLogger.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVLogger.m 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import "CVLogger.h" 10 | 11 | #import "CVLogButton.h" 12 | #import "CVLoggerViewController.h" 13 | 14 | #define kCollapseHeight 150 15 | 16 | @interface CVLogger () 17 | 18 | @property (nonatomic, strong) CVLogButton *btLogger; 19 | 20 | @end 21 | 22 | @implementation CVLogger 23 | 24 | 25 | -(instancetype)init { 26 | if (!(self = [super init])) 27 | return nil; 28 | 29 | self.collapseHeight = kCollapseHeight; 30 | self.btLogger = [CVLogButton buttonWithType:UIButtonTypeCustom]; 31 | 32 | [self.btLogger addTarget:self action:@selector(touched:) forControlEvents:UIControlEventTouchUpInside]; 33 | UIWindow* currentWindow = [UIApplication sharedApplication].keyWindow; 34 | [currentWindow addSubview:self.btLogger]; 35 | 36 | return self; 37 | } 38 | 39 | #pragma mark - Action senders 40 | 41 | -(void) touched:(id) sender { 42 | 43 | CVLoggerViewController *loggerVC = [[CVLoggerViewController alloc] initWithNibName:nil bundle:nil]; 44 | loggerVC.collapseHeight = self.collapseHeight; 45 | loggerVC.delegate = self; 46 | UINavigationController *navigationController = 47 | [[UINavigationController alloc] initWithRootViewController:loggerVC]; 48 | 49 | [[self topMostController] presentViewController:navigationController animated:YES completion:^{ 50 | self.btLogger.hidden = YES; 51 | }]; 52 | } 53 | 54 | #pragma mark - Private methods 55 | 56 | - (UIViewController*) topMostController { 57 | 58 | UIViewController *topController = [UIApplication sharedApplication].keyWindow.rootViewController; 59 | 60 | while (topController.presentedViewController) { 61 | topController = topController.presentedViewController; 62 | } 63 | 64 | return topController; 65 | } 66 | 67 | #pragma mark - CVLoggerDelegate 68 | 69 | -(void)CVLoggerDidClosed { 70 | self.btLogger.hidden = NO; 71 | } 72 | 73 | 74 | @end 75 | 76 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Snapshot.m: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2015, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | * 9 | */ 10 | 11 | #import 12 | 13 | @implementation UIImage (Snapshot) 14 | 15 | + (UIImage *)fb_imageForLayer:(CALayer *)layer 16 | { 17 | CGRect bounds = layer.bounds; 18 | NSAssert1(CGRectGetWidth(bounds), @"Zero width for layer %@", layer); 19 | NSAssert1(CGRectGetHeight(bounds), @"Zero height for layer %@", layer); 20 | 21 | UIGraphicsBeginImageContextWithOptions(bounds.size, NO, 0); 22 | CGContextRef context = UIGraphicsGetCurrentContext(); 23 | NSAssert1(context, @"Could not generate context for layer %@", layer); 24 | CGContextSaveGState(context); 25 | [layer layoutIfNeeded]; 26 | [layer renderInContext:context]; 27 | CGContextRestoreGState(context); 28 | 29 | UIImage *snapshot = UIGraphicsGetImageFromCurrentImageContext(); 30 | UIGraphicsEndImageContext(); 31 | return snapshot; 32 | } 33 | 34 | + (UIImage *)fb_imageForViewLayer:(UIView *)view 35 | { 36 | [view layoutIfNeeded]; 37 | return [self fb_imageForLayer:view.layer]; 38 | } 39 | 40 | + (UIImage *)fb_imageForView:(UIView *)view 41 | { 42 | CGRect bounds = view.bounds; 43 | NSAssert1(CGRectGetWidth(bounds), @"Zero width for view %@", view); 44 | NSAssert1(CGRectGetHeight(bounds), @"Zero height for view %@", view); 45 | 46 | UIWindow *window = view.window; 47 | if (window == nil) { 48 | window = [[UIWindow alloc] initWithFrame:bounds]; 49 | [window addSubview:view]; 50 | [window makeKeyAndVisible]; 51 | } 52 | 53 | UIGraphicsBeginImageContextWithOptions(bounds.size, NO, 0); 54 | [view layoutIfNeeded]; 55 | [view drawViewHierarchyInRect:view.bounds afterScreenUpdates:YES]; 56 | 57 | UIImage *snapshot = UIGraphicsGetImageFromCurrentImageContext(); 58 | UIGraphicsEndImageContext(); 59 | return snapshot; 60 | } 61 | 62 | @end 63 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # CVLogger 2 | 3 | [![CI Status](http://img.shields.io/travis/cvillaseca/CVLogger.svg?style=flat)](https://travis-ci.org/cvillaseca/CVLogger) 4 | [![Version](https://img.shields.io/cocoapods/v/CVLogger.svg?style=flat)](http://cocoapods.org/pods/CVLogger) 5 | [![License](https://img.shields.io/cocoapods/l/CVLogger.svg?style=flat)](http://cocoapods.org/pods/CVLogger) 6 | [![Platform](https://img.shields.io/cocoapods/p/CVLogger.svg?style=flat)](http://cocoapods.org/pods/CVLogger) 7 | 8 | `CVLogger` is a tool that shows a button over UIWindow (only DEBUG build). When it pushed will show any log printed by NSLog. 9 | 10 | ![screenshot](https://cloud.githubusercontent.com/assets/7700085/13968554/b0c61910-f07d-11e5-9ced-33dadfe06c4a.gif) 11 | 12 | [Show Appetize.io DEMO](https://appetize.io/app/kuz81bjqm91ucwzmtgeqpk55kc?device=iphone5s&scale=75&orientation=portrait&osVersion=9.2) 13 | 14 | ## Usage 15 | 16 | To run the example project, clone the repo, and run `pod install` from the Example directory first. 17 | 18 | In your AppDelegate.h: 19 | ```objective-c 20 | #import 21 | 22 | @property (strong, nonatomic) CVLogger *cvlogger; 23 | ``` 24 | 25 | In your AppDelegate.m: 26 | ```objective-c 27 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 28 | { 29 | //UIWindow must not be nil before init CVLogger 30 | #ifdef DEBUG 31 | self.cvlogger =[[CVLogger alloc] init]; 32 | #endif 33 | } 34 | ``` 35 | 36 | ## Requirements 37 | 38 | `CVLogger` works on iOS 7+ and requires ARC to build. It depends on the following Apple frameworks, which should already be included with most Xcode templates: 39 | 40 | * Foundation.framework 41 | * UIKit.framework 42 | 43 | You will need the latest developer tools in order to build `CVLogger`. Old Xcode versions might work, but compatibility will not be explicitly maintained. 44 | 45 | ## Installation 46 | 47 | CVLogger is available through [CocoaPods](http://cocoapods.org). To install 48 | it, simply add the following line to your Podfile: 49 | 50 | ```ruby 51 | pod "CVLogger" 52 | ``` 53 | 54 | ## Author 55 | 56 | Cristian Villaseca, cvillaseca_basco@hotmail.com 57 | 58 | ## License 59 | 60 | CVLogger is available under the MIT license. See the LICENSE file for more info. 61 | -------------------------------------------------------------------------------- /Example/Pods/Pods.xcodeproj/xcshareddata/xcschemes/CVLogger.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example-acknowledgements.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreferenceSpecifiers 6 | 7 | 8 | FooterText 9 | This application makes use of the following third party libraries: 10 | Title 11 | Acknowledgements 12 | Type 13 | PSGroupSpecifier 14 | 15 | 16 | FooterText 17 | Copyright (c) 2016 Cristian Villaseca <cvillaseca_basco@hotmail.com> 18 | 19 | Permission is hereby granted, free of charge, to any person obtaining a copy 20 | of this software and associated documentation files (the "Software"), to deal 21 | in the Software without restriction, including without limitation the rights 22 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 23 | copies of the Software, and to permit persons to whom the Software is 24 | furnished to do so, subject to the following conditions: 25 | 26 | The above copyright notice and this permission notice shall be included in 27 | all copies or substantial portions of the Software. 28 | 29 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 30 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 31 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 32 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 33 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 34 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 35 | THE SOFTWARE. 36 | 37 | Title 38 | CVLogger 39 | Type 40 | PSGroupSpecifier 41 | 42 | 43 | FooterText 44 | Generated by CocoaPods - http://cocoapods.org 45 | Title 46 | 47 | Type 48 | PSGroupSpecifier 49 | 50 | 51 | StringsTable 52 | Acknowledgements 53 | Title 54 | Acknowledgements 55 | 56 | 57 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/XCTestCase+Specta.m: -------------------------------------------------------------------------------- 1 | #import 2 | #import "XCTestCase+Specta.h" 3 | #import "SPTSpec.h" 4 | #import "SPTExample.h" 5 | #import "SPTSharedExampleGroups.h" 6 | #import "SpectaUtility.h" 7 | #import "XCTest+Private.h" 8 | 9 | @interface XCTestCase (xct_allSubclasses) 10 | 11 | - (NSArray *)allSubclasses; 12 | - (void)_dequeueFailures; 13 | 14 | @end 15 | 16 | @implementation XCTestCase (Specta) 17 | 18 | + (void)load { 19 | Method allSubclasses = class_getClassMethod(self, @selector(allSubclasses)); 20 | Method allSubclasses_swizzle = class_getClassMethod(self , @selector(spt_allSubclasses_swizzle)); 21 | method_exchangeImplementations(allSubclasses, allSubclasses_swizzle); 22 | 23 | Method dequeueFailures = class_getInstanceMethod(self, @selector(_dequeueFailures)); 24 | Method dequeueFailures_swizzle = class_getInstanceMethod(self, @selector(spt_dequeueFailures)); 25 | method_exchangeImplementations(dequeueFailures, dequeueFailures_swizzle); 26 | } 27 | 28 | + (NSArray *)spt_allSubclasses_swizzle { 29 | NSArray *subclasses = [self spt_allSubclasses_swizzle]; // call original 30 | NSMutableArray *filtered = [NSMutableArray arrayWithCapacity:[subclasses count]]; 31 | // exclude SPTSpec base class and all subclasses of SPTSharedExampleGroups 32 | for (id subclass in subclasses) { 33 | if (subclass != [SPTSpec class] && ![subclass isKindOfClass:[SPTSharedExampleGroups class]]) { 34 | [filtered addObject:subclass]; 35 | } 36 | } 37 | return spt_shuffle(filtered); 38 | } 39 | 40 | - (void)spt_dequeueFailures { 41 | void(^dequeueFailures)() = ^() { 42 | [self spt_dequeueFailures]; 43 | }; 44 | 45 | if ([NSThread isMainThread]) { 46 | dequeueFailures(); 47 | } else { 48 | dispatch_sync(dispatch_get_main_queue(), dequeueFailures); 49 | } 50 | } 51 | 52 | - (void)spt_handleException:(NSException *)exception { 53 | NSString *description = [exception reason]; 54 | if ([exception userInfo]) { 55 | id line = [exception userInfo][@"line"]; 56 | id file = [exception userInfo][@"file"]; 57 | if ([line isKindOfClass:[NSNumber class]] && [file isKindOfClass:[NSString class]]) { 58 | [self recordFailureWithDescription:description inFile:file atLine:[line unsignedIntegerValue] expected:YES]; 59 | return; 60 | } 61 | } 62 | [self _recordUnexpectedFailureWithDescription:description exception:exception]; 63 | } 64 | 65 | @end 66 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/Categories/UIImage+Diff.m: -------------------------------------------------------------------------------- 1 | // 2 | // Created by Gabriel Handford on 3/1/09. 3 | // Copyright 2009-2013. All rights reserved. 4 | // Created by John Boiles on 10/20/11. 5 | // Copyright (c) 2011. All rights reserved 6 | // Modified by Felix Schulze on 2/11/13. 7 | // Copyright 2013. All rights reserved. 8 | // 9 | // Permission is hereby granted, free of charge, to any person 10 | // obtaining a copy of this software and associated documentation 11 | // files (the "Software"), to deal in the Software without 12 | // restriction, including without limitation the rights to use, 13 | // copy, modify, merge, publish, distribute, sublicense, and/or sell 14 | // copies of the Software, and to permit persons to whom the 15 | // Software is furnished to do so, subject to the following 16 | // conditions: 17 | // 18 | // The above copyright notice and this permission notice shall be 19 | // included in all copies or substantial portions of the Software. 20 | // 21 | // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 22 | // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 23 | // OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 24 | // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 25 | // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 26 | // WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 27 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 28 | // OTHER DEALINGS IN THE SOFTWARE. 29 | // 30 | 31 | #import 32 | 33 | @implementation UIImage (Diff) 34 | 35 | - (UIImage *)fb_diffWithImage:(UIImage *)image 36 | { 37 | if (!image) { 38 | return nil; 39 | } 40 | CGSize imageSize = CGSizeMake(MAX(self.size.width, image.size.width), MAX(self.size.height, image.size.height)); 41 | UIGraphicsBeginImageContextWithOptions(imageSize, YES, 0); 42 | CGContextRef context = UIGraphicsGetCurrentContext(); 43 | [self drawInRect:CGRectMake(0, 0, self.size.width, self.size.height)]; 44 | CGContextSetAlpha(context, 0.5); 45 | CGContextBeginTransparencyLayer(context, NULL); 46 | [image drawInRect:CGRectMake(0, 0, image.size.width, image.size.height)]; 47 | CGContextSetBlendMode(context, kCGBlendModeDifference); 48 | CGContextSetFillColorWithColor(context,[UIColor whiteColor].CGColor); 49 | CGContextFillRect(context, CGRectMake(0, 0, self.size.width, self.size.height)); 50 | CGContextEndTransparencyLayer(context); 51 | UIImage *returnImage = UIGraphicsGetImageFromCurrentImageContext(); 52 | UIGraphicsEndImageContext(); 53 | return returnImage; 54 | } 55 | 56 | @end 57 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SPTSharedExampleGroups.m: -------------------------------------------------------------------------------- 1 | #import "SPTSharedExampleGroups.h" 2 | #import "SPTExampleGroup.h" 3 | #import "SPTSpec.h" 4 | #import "SpectaUtility.h" 5 | #import 6 | 7 | NSMutableDictionary *globalSharedExampleGroups = nil; 8 | BOOL initialized = NO; 9 | 10 | @implementation SPTSharedExampleGroups 11 | 12 | + (void)initialize { 13 | Class SPTSharedExampleGroupsClass = [SPTSharedExampleGroups class]; 14 | if ([self class] == SPTSharedExampleGroupsClass) { 15 | if (!initialized) { 16 | initialized = YES; 17 | globalSharedExampleGroups = [[NSMutableDictionary alloc] init]; 18 | 19 | Class *classes = NULL; 20 | int numClasses = objc_getClassList(NULL, 0); 21 | 22 | if (numClasses > 0) { 23 | classes = (Class *)malloc(sizeof(Class) * numClasses); 24 | numClasses = objc_getClassList(classes, numClasses); 25 | 26 | Class klass, superClass; 27 | for(uint i = 0; i < numClasses; i++) { 28 | klass = classes[i]; 29 | superClass = class_getSuperclass(klass); 30 | if (superClass == SPTSharedExampleGroupsClass) { 31 | [[[klass alloc] init] sharedExampleGroups]; 32 | } 33 | } 34 | 35 | free(classes); 36 | } 37 | } 38 | } 39 | } 40 | 41 | + (void)addSharedExampleGroupWithName:(NSString *)name block:(SPTDictionaryBlock)block exampleGroup:(SPTExampleGroup *)exampleGroup { 42 | (exampleGroup == nil ? globalSharedExampleGroups : exampleGroup.sharedExamples)[name] = [block copy]; 43 | } 44 | 45 | + (SPTDictionaryBlock)sharedExampleGroupWithName:(NSString *)name exampleGroup:(SPTExampleGroup *)exampleGroup { 46 | SPTDictionaryBlock sharedExampleGroup = nil; 47 | while (exampleGroup != nil) { 48 | if ((sharedExampleGroup = exampleGroup.sharedExamples[name])) { 49 | return sharedExampleGroup; 50 | } 51 | exampleGroup = exampleGroup.parent; 52 | } 53 | return globalSharedExampleGroups[name]; 54 | } 55 | 56 | - (void)sharedExampleGroups {} 57 | 58 | - (void)spt_handleException:(NSException *)exception { 59 | [SPTCurrentSpec spt_handleException:exception]; 60 | } 61 | 62 | - (void)recordFailureWithDescription:(NSString *)description inFile:(NSString *)filename atLine:(NSUInteger)lineNumber expected:(BOOL)expected { 63 | [SPTCurrentSpec recordFailureWithDescription:description inFile:filename atLine:lineNumber expected:expected]; 64 | } 65 | 66 | - (void)_recordUnexpectedFailureWithDescription:(NSString *)description exception:(NSException *)exception { 67 | [SPTCurrentSpec _recordUnexpectedFailureWithDescription:description exception:exception]; 68 | } 69 | 70 | - (_XCTestCaseImplementation *)internalImplementation { 71 | return [SPTCurrentSpec internalImplementation]; 72 | } 73 | 74 | @end 75 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+endWith.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+endWith.h" 2 | 3 | EXPMatcherImplementationBegin(endWith, (id expected)) { 4 | BOOL actualIsNil = (actual == nil); 5 | BOOL expectedIsNil = (expected == nil); 6 | //This condition allows the comparison of an immutable string or ordered collection to the mutable type of the same 7 | BOOL actualAndExpectedAreCompatible = (([actual isKindOfClass:[NSString class]] && [expected isKindOfClass:[NSString class]]) 8 | || ([actual isKindOfClass:[NSArray class]] && [expected isKindOfClass:[NSArray class]]) 9 | || ([actual isKindOfClass:[NSOrderedSet class]] && [expected isKindOfClass:[NSOrderedSet class]])); 10 | 11 | prerequisite(^BOOL { 12 | return actualAndExpectedAreCompatible; 13 | }); 14 | 15 | match(^BOOL { 16 | if ([actual isKindOfClass:[NSString class]]) { 17 | return [actual hasSuffix:expected]; 18 | } else if ([actual isKindOfClass:[NSArray class]]) { 19 | if ([expected count] > [actual count] || [expected count] == 0) { 20 | return NO; 21 | } 22 | NSArray *subArray = [actual subarrayWithRange:NSMakeRange([actual count] - [expected count], [expected count])]; 23 | return [subArray isEqualToArray:expected]; 24 | } else { 25 | if ([expected count] > [actual count] || [expected count] == 0) { 26 | return NO; 27 | } 28 | 29 | NSOrderedSet *subset = [NSOrderedSet orderedSetWithOrderedSet:actual range:NSMakeRange([actual count] - [expected count], [expected count]) copyItems:NO]; 30 | return [subset isEqualToOrderedSet:expected]; 31 | } 32 | }); 33 | 34 | failureMessageForTo(^NSString *{ 35 | if (actualIsNil) return @"the object is nil/null"; 36 | if (expectedIsNil) return @"the expected value is nil/null"; 37 | if (!actualAndExpectedAreCompatible) return [NSString stringWithFormat:@"%@ and %@ are not instances of one of %@, %@, or %@", EXPDescribeObject(actual), EXPDescribeObject(expected), [NSString class], [NSArray class], [NSOrderedSet class]]; 38 | return [NSString stringWithFormat:@"expected: %@ to end with %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 39 | }); 40 | 41 | failureMessageForNotTo(^NSString *{ 42 | if (actualIsNil) return @"the object is nil/null"; 43 | if (expectedIsNil) return @"the expected value is nil/null"; 44 | if (!actualAndExpectedAreCompatible) return [NSString stringWithFormat:@"%@ and %@ are not instances of one of %@, %@, or %@", EXPDescribeObject(actual), EXPDescribeObject(expected), [NSString class], [NSArray class], [NSOrderedSet class]]; 45 | 46 | return [NSString stringWithFormat:@"expected: %@ not to end with %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 47 | }); 48 | } 49 | EXPMatcherImplementationEnd 50 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beginWith.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+beginWith.h" 2 | 3 | EXPMatcherImplementationBegin(beginWith, (id expected)) { 4 | BOOL actualIsNil = (actual == nil); 5 | BOOL expectedIsNil = (expected == nil); 6 | //This condition allows the comparison of an immutable string or ordered collection to the mutable type of the same 7 | BOOL actualAndExpectedAreCompatible = (([actual isKindOfClass:[NSString class]] && [expected isKindOfClass:[NSString class]]) 8 | || ([actual isKindOfClass:[NSArray class]] && [expected isKindOfClass:[NSArray class]]) 9 | || ([actual isKindOfClass:[NSOrderedSet class]] && [expected isKindOfClass:[NSOrderedSet class]])); 10 | 11 | prerequisite(^BOOL { 12 | return actualAndExpectedAreCompatible; 13 | }); 14 | 15 | match(^BOOL { 16 | if ([actual isKindOfClass:[NSString class]]) { 17 | return [actual hasPrefix:expected]; 18 | } else if ([actual isKindOfClass:[NSArray class]]) { 19 | if ([expected count] > [actual count] || [expected count] == 0) { 20 | return NO; 21 | } 22 | NSArray *subArray = [actual subarrayWithRange:NSMakeRange(0, [expected count])]; 23 | return [subArray isEqualToArray:expected]; 24 | } else { 25 | if ([expected count] > [actual count] || [expected count] == 0) { 26 | return NO; 27 | } 28 | 29 | NSOrderedSet *subset = [NSOrderedSet orderedSetWithOrderedSet:actual range:NSMakeRange(0, [expected count]) copyItems:NO]; 30 | return [subset isEqualToOrderedSet:expected]; 31 | } 32 | }); 33 | 34 | failureMessageForTo(^NSString *{ 35 | if (actualIsNil) return @"the object is nil/null"; 36 | if (expectedIsNil) return @"the expected value is nil/null"; 37 | if (!actualAndExpectedAreCompatible) return [NSString stringWithFormat:@"%@ and %@ are not instances of one of %@, %@, or %@", EXPDescribeObject(actual), EXPDescribeObject(expected), [NSString class], [NSArray class], [NSOrderedSet class]]; 38 | return [NSString stringWithFormat:@"expected: %@ to begin with %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 39 | }); 40 | 41 | failureMessageForNotTo(^NSString *{ 42 | if (actualIsNil) return @"the object is nil/null"; 43 | if (expectedIsNil) return @"the expected value is nil/null"; 44 | if (!actualAndExpectedAreCompatible) return [NSString stringWithFormat:@"%@ and %@ are not instances of one of %@, %@, or %@", EXPDescribeObject(actual), EXPDescribeObject(expected), [NSString class], [NSArray class], [NSOrderedSet class]]; 45 | 46 | return [NSString stringWithFormat:@"expected: %@ not to begin with %@", EXPDescribeObject(actual), EXPDescribeObject(expected)]; 47 | }); 48 | } 49 | EXPMatcherImplementationEnd 50 | 51 | EXPMatcherAliasImplementation(startWith, beginWith, (id expected)); 52 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+beSupersetOf.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+contain.h" 2 | 3 | EXPMatcherImplementationBegin(beSupersetOf, (id subset)) { 4 | BOOL actualIsCompatible = [actual isKindOfClass:[NSDictionary class]] || [actual respondsToSelector:@selector(containsObject:)]; 5 | BOOL subsetIsNil = (subset == nil); 6 | 7 | // For some instances the isKindOfClass: method returns false, even though 8 | // they are both actually dictionaries. e.g. Comparing a NSCFDictionary and a 9 | // NSDictionary. 10 | // Or in cases when you compare NSMutableArray (which implementation is __NSArrayM:NSMutableArray:NSArray) 11 | // and NSArray (which implementation is __NSArrayI:NSArray) 12 | BOOL bothAreIdenticalCollectionClasses = ([actual isKindOfClass:[NSDictionary class]] && [subset isKindOfClass:[NSDictionary class]]) || 13 | ([actual isKindOfClass:[NSArray class]] && [subset isKindOfClass:[NSArray class]]) || 14 | ([actual isKindOfClass:[NSSet class]] && [subset isKindOfClass:[NSSet class]]) || 15 | ([actual isKindOfClass:[NSOrderedSet class]] && [subset isKindOfClass:[NSOrderedSet class]]); 16 | 17 | BOOL classMatches = bothAreIdenticalCollectionClasses || [subset isKindOfClass:[actual class]]; 18 | 19 | prerequisite(^BOOL{ 20 | return actualIsCompatible && !subsetIsNil && classMatches; 21 | }); 22 | 23 | match(^BOOL{ 24 | if(!actualIsCompatible) return NO; 25 | 26 | if([actual isKindOfClass:[NSDictionary class]]) { 27 | for (id key in subset) { 28 | id actualValue = [actual valueForKey:key]; 29 | id subsetValue = [subset valueForKey:key]; 30 | 31 | if (![subsetValue isEqual:actualValue]) return NO; 32 | } 33 | } else { 34 | for (id object in subset) { 35 | if (![actual containsObject:object]) return NO; 36 | } 37 | } 38 | 39 | return YES; 40 | }); 41 | 42 | failureMessageForTo(^NSString *{ 43 | if(!actualIsCompatible) return [NSString stringWithFormat:@"%@ is not an instance of NSDictionary and does not implement -containsObject:", EXPDescribeObject(actual)]; 44 | 45 | if(subsetIsNil) return @"the expected value is nil/null"; 46 | 47 | if(!classMatches) return [NSString stringWithFormat:@"%@ does not match the class of %@", EXPDescribeObject(subset), EXPDescribeObject(actual)]; 48 | 49 | return [NSString stringWithFormat:@"expected %@ to be a superset of %@", EXPDescribeObject(actual), EXPDescribeObject(subset)]; 50 | }); 51 | 52 | failureMessageForNotTo(^NSString *{ 53 | if(!actualIsCompatible) return [NSString stringWithFormat:@"%@ is not an instance of NSDictionary and does not implement -containsObject:", EXPDescribeObject(actual)]; 54 | 55 | if(subsetIsNil) return @"the expected value is nil/null"; 56 | 57 | if(!classMatches) return [NSString stringWithFormat:@"%@ does not match the class of %@", EXPDescribeObject(subset), EXPDescribeObject(actual)]; 58 | 59 | return [NSString stringWithFormat:@"expected %@ not to be a superset of %@", EXPDescribeObject(actual), EXPDescribeObject(subset)]; 60 | }); 61 | } 62 | EXPMatcherImplementationEnd 63 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/ExpectaSupport.h: -------------------------------------------------------------------------------- 1 | #import "EXPExpect.h" 2 | #import "EXPBlockDefinedMatcher.h" 3 | 4 | #ifdef __cplusplus 5 | extern "C" { 6 | #endif 7 | 8 | id _EXPObjectify(const char *type, ...); 9 | EXPExpect *_EXP_expect(id testCase, int lineNumber, const char *fileName, EXPIdBlock actualBlock); 10 | 11 | void EXPFail(id testCase, int lineNumber, const char *fileName, NSString *message); 12 | NSString *EXPDescribeObject(id obj); 13 | 14 | void EXP_prerequisite(EXPBoolBlock block); 15 | void EXP_match(EXPBoolBlock block); 16 | void EXP_failureMessageForTo(EXPStringBlock block); 17 | void EXP_failureMessageForNotTo(EXPStringBlock block); 18 | 19 | #if __has_feature(objc_arc) 20 | #define _EXP_release(x) 21 | #define _EXP_autorelease(x) (x) 22 | 23 | #else 24 | #define _EXP_release(x) [x release] 25 | #define _EXP_autorelease(x) [x autorelease] 26 | #endif 27 | 28 | // workaround for the categories bug: http://developer.apple.com/library/mac/#qa/qa1490/_index.html 29 | #define EXPFixCategoriesBug(name) \ 30 | __attribute__((constructor)) static void EXPFixCategoriesBug##name() {} 31 | 32 | #define _EXPMatcherInterface(matcherName, matcherArguments) \ 33 | @interface EXPExpect (matcherName##Matcher) \ 34 | @property (nonatomic, readonly) void(^ matcherName) matcherArguments; \ 35 | @end 36 | 37 | #define _EXPMatcherImplementationBegin(matcherName, matcherArguments) \ 38 | EXPFixCategoriesBug(EXPMatcher##matcherName##Matcher); \ 39 | @implementation EXPExpect (matcherName##Matcher) \ 40 | @dynamic matcherName;\ 41 | - (void(^) matcherArguments) matcherName { \ 42 | EXPBlockDefinedMatcher *matcher = [[EXPBlockDefinedMatcher alloc] init]; \ 43 | [[[NSThread currentThread] threadDictionary] setObject:matcher forKey:@"EXP_currentMatcher"]; \ 44 | __block id actual = self.actual; \ 45 | __block void (^prerequisite)(EXPBoolBlock block) = ^(EXPBoolBlock block) { EXP_prerequisite(block); }; \ 46 | __block void (^match)(EXPBoolBlock block) = ^(EXPBoolBlock block) { EXP_match(block); }; \ 47 | __block void (^failureMessageForTo)(EXPStringBlock block) = ^(EXPStringBlock block) { EXP_failureMessageForTo(block); }; \ 48 | __block void (^failureMessageForNotTo)(EXPStringBlock block) = ^(EXPStringBlock block) { EXP_failureMessageForNotTo(block); }; \ 49 | prerequisite(nil); match(nil); failureMessageForTo(nil); failureMessageForNotTo(nil); \ 50 | void (^matcherBlock) matcherArguments = [^ matcherArguments { \ 51 | { 52 | 53 | #define _EXPMatcherImplementationEnd \ 54 | } \ 55 | [self applyMatcher:matcher to:&actual]; \ 56 | [[[NSThread currentThread] threadDictionary] removeObjectForKey:@"EXP_currentMatcher"]; \ 57 | } copy]; \ 58 | _EXP_release(matcher); \ 59 | return _EXP_autorelease(matcherBlock); \ 60 | } \ 61 | @end 62 | 63 | #define _EXPMatcherAliasImplementation(newMatcherName, oldMatcherName, matcherArguments) \ 64 | EXPFixCategoriesBug(EXPMatcher##newMatcherName##Matcher); \ 65 | @implementation EXPExpect (newMatcherName##Matcher) \ 66 | @dynamic newMatcherName;\ 67 | - (void(^) matcherArguments) newMatcherName { \ 68 | return [self oldMatcherName]; \ 69 | }\ 70 | @end 71 | 72 | #ifdef __cplusplus 73 | } 74 | #endif 75 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SpectaUtility.m: -------------------------------------------------------------------------------- 1 | #import "SpectaUtility.h" 2 | #import "SPTSpec.h" 3 | #import 4 | 5 | NSString * const spt_kCurrentTestSuiteKey = @"SPTCurrentTestSuite"; 6 | NSString * const spt_kCurrentSpecKey = @"SPTCurrentSpec"; 7 | 8 | static unsigned int seed = 0; 9 | 10 | BOOL spt_isSpecClass(Class aClass) { 11 | Class superclass = class_getSuperclass(aClass); 12 | while (superclass != Nil) { 13 | if (superclass == [SPTSpec class]) { 14 | return YES; 15 | } else { 16 | superclass = class_getSuperclass(superclass); 17 | } 18 | } 19 | return NO; 20 | } 21 | 22 | NSString *spt_underscorize(NSString *string) { 23 | static NSMutableCharacterSet *invalidCharSet; 24 | static dispatch_once_t onceToken; 25 | dispatch_once(&onceToken, ^{ 26 | invalidCharSet = [[NSMutableCharacterSet alloc] init]; 27 | [invalidCharSet formUnionWithCharacterSet:[NSCharacterSet controlCharacterSet]]; 28 | [invalidCharSet formUnionWithCharacterSet:[NSCharacterSet illegalCharacterSet]]; 29 | [invalidCharSet formUnionWithCharacterSet:[NSCharacterSet newlineCharacterSet]]; 30 | [invalidCharSet formUnionWithCharacterSet:[NSCharacterSet nonBaseCharacterSet]]; 31 | [invalidCharSet formUnionWithCharacterSet:[NSCharacterSet punctuationCharacterSet]]; 32 | [invalidCharSet formUnionWithCharacterSet:[NSCharacterSet symbolCharacterSet]]; 33 | }); 34 | NSString *stripped = [string stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]]; 35 | stripped = [[stripped componentsSeparatedByCharactersInSet:invalidCharSet] componentsJoinedByString:@""]; 36 | 37 | NSArray *components = [stripped componentsSeparatedByCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; 38 | stripped = [[components objectsAtIndexes:[components indexesOfObjectsPassingTest:^BOOL(id obj, NSUInteger idx, BOOL *stop) { 39 | return ![obj isEqualToString:@""]; 40 | }]] componentsJoinedByString:@"_"]; 41 | return stripped; 42 | } 43 | 44 | NSArray *spt_map(NSArray *array, id (^block)(id obj, NSUInteger idx)) { 45 | NSMutableArray *mapped = [NSMutableArray arrayWithCapacity:[array count]]; 46 | [array enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) { 47 | [mapped addObject:block(obj, idx)]; 48 | }]; 49 | return mapped; 50 | } 51 | 52 | NSArray *spt_shuffle(NSArray *array) { 53 | if (![[[[NSProcessInfo processInfo] environment] objectForKey:@"SPECTA_SHUFFLE"] isEqualToString:@"1"]) { 54 | return array; 55 | } 56 | spt_seed(); 57 | NSMutableArray *shuffled = [array mutableCopy]; 58 | NSUInteger count = [shuffled count]; 59 | for (NSUInteger i = 0; i < count; i++) { 60 | NSUInteger r = random() % count; 61 | [shuffled exchangeObjectAtIndex:i withObjectAtIndex:r]; 62 | } 63 | return shuffled; 64 | } 65 | 66 | unsigned int spt_seed() { 67 | static dispatch_once_t onceToken; 68 | dispatch_once(&onceToken, ^{ 69 | NSString *envSeed = [[[NSProcessInfo processInfo] environment] objectForKey:@"SPECTA_SEED"]; 70 | if (envSeed) { 71 | sscanf([envSeed UTF8String], "%u", &seed); 72 | } else { 73 | seed = arc4random(); 74 | } 75 | srandom(seed); 76 | printf("Test Seed: %u\n", seed); 77 | }); 78 | return seed; 79 | } 80 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/FBSnapshotTestCase/SwiftSupport.swift: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2015, Facebook, Inc. 3 | * All rights reserved. 4 | * 5 | * This source code is licensed under the BSD-style license found in the 6 | * LICENSE file in the root directory of this source tree. An additional grant 7 | * of patent rights can be found in the PATENTS file in the same directory. 8 | * 9 | */ 10 | 11 | public extension FBSnapshotTestCase { 12 | public func FBSnapshotVerifyView(view: UIView, identifier: String = "", suffixes: NSOrderedSet = FBSnapshotTestCaseDefaultSuffixes(), file: String = __FILE__, line: UInt = __LINE__) { 13 | FBSnapshotVerifyViewOrLayer(view, identifier: identifier, suffixes: suffixes) 14 | } 15 | 16 | public func FBSnapshotVerifyLayer(layer: CALayer, identifier: String = "", suffixes: NSOrderedSet = FBSnapshotTestCaseDefaultSuffixes(), file: String = __FILE__, line: UInt = __LINE__) { 17 | FBSnapshotVerifyViewOrLayer(layer, identifier: identifier, suffixes: suffixes) 18 | } 19 | 20 | private func FBSnapshotVerifyViewOrLayer(viewOrLayer: AnyObject, identifier: String = "", suffixes: NSOrderedSet = FBSnapshotTestCaseDefaultSuffixes(), file: String = __FILE__, line: UInt = __LINE__) { 21 | let envReferenceImageDirectory = self.getReferenceImageDirectoryWithDefault(FB_REFERENCE_IMAGE_DIR) 22 | var error: NSError? 23 | var comparisonSuccess = false 24 | 25 | if let envReferenceImageDirectory = envReferenceImageDirectory { 26 | for suffix in suffixes { 27 | let referenceImagesDirectory = "\(envReferenceImageDirectory)\(suffix)" 28 | if viewOrLayer.isKindOfClass(UIView) { 29 | do { 30 | try compareSnapshotOfView(viewOrLayer as! UIView, referenceImagesDirectory: referenceImagesDirectory, identifier: identifier, tolerance: 0) 31 | comparisonSuccess = true 32 | } catch let error1 as NSError { 33 | error = error1 34 | comparisonSuccess = false 35 | } 36 | } else if viewOrLayer.isKindOfClass(CALayer) { 37 | do { 38 | try compareSnapshotOfLayer(viewOrLayer as! CALayer, referenceImagesDirectory: referenceImagesDirectory, identifier: identifier, tolerance: 0) 39 | comparisonSuccess = true 40 | } catch let error1 as NSError { 41 | error = error1 42 | comparisonSuccess = false 43 | } 44 | } else { 45 | assertionFailure("Only UIView and CALayer classes can be snapshotted") 46 | } 47 | 48 | assert(recordMode == false, message: "Test ran in record mode. Reference image is now saved. Disable record mode to perform an actual snapshot comparison!", file: file, line: line) 49 | 50 | if comparisonSuccess || recordMode { 51 | break 52 | } 53 | 54 | assert(comparisonSuccess, message: "Snapshot comparison failed: \(error)", file: file, line: line) 55 | } 56 | } else { 57 | XCTFail("Missing value for referenceImagesDirectory - Set FB_REFERENCE_IMAGE_DIR as Environment variable in your scheme.") 58 | } 59 | } 60 | 61 | func assert(assertion: Bool, message: String, file: String, line: UInt) { 62 | if !assertion { 63 | XCTFail(message, file: file, line: line) 64 | } 65 | } 66 | } 67 | -------------------------------------------------------------------------------- /Example/Pods/Expecta/Expecta/Matchers/EXPMatchers+postNotification.m: -------------------------------------------------------------------------------- 1 | #import "EXPMatchers+postNotification.h" 2 | 3 | @implementation NSNotification (EXPEquality) 4 | 5 | - (BOOL)exp_isFunctionallyEqualTo:(NSNotification *)otherNotification 6 | { 7 | if (![otherNotification isKindOfClass:[NSNotification class]]) return NO; 8 | 9 | BOOL namesMatch = [otherNotification.name isEqualToString:self.name]; 10 | 11 | BOOL objectsMatch = YES; 12 | if (otherNotification.object || self.object) { 13 | objectsMatch = [otherNotification.object isEqual:self.object]; 14 | } 15 | 16 | BOOL userInfoMatches = YES; 17 | if (otherNotification.userInfo || self.userInfo) { 18 | userInfoMatches = [otherNotification.userInfo isEqual:self.userInfo]; 19 | } 20 | 21 | return (namesMatch && objectsMatch && userInfoMatches); 22 | } 23 | 24 | @end 25 | 26 | EXPMatcherImplementationBegin(postNotification, (id expected)){ 27 | BOOL actualIsNil = (actual == nil); 28 | BOOL expectedIsNil = (expected == nil); 29 | BOOL isNotification = [expected isKindOfClass:[NSNotification class]]; 30 | BOOL isName = [expected isKindOfClass:[NSString class]]; 31 | 32 | __block NSString *expectedName; 33 | __block BOOL expectedNotificationOccurred = NO; 34 | __block id observer; 35 | 36 | prerequisite(^BOOL{ 37 | expectedNotificationOccurred = NO; 38 | if (actualIsNil || expectedIsNil) return NO; 39 | if (isNotification) { 40 | expectedName = [expected name]; 41 | }else if(isName) { 42 | expectedName = expected; 43 | }else{ 44 | return NO; 45 | } 46 | 47 | observer = [[NSNotificationCenter defaultCenter] addObserverForName:expectedName object:nil queue:nil usingBlock:^(NSNotification *note){ 48 | if (isNotification) { 49 | expectedNotificationOccurred |= [expected exp_isFunctionallyEqualTo:note]; 50 | }else{ 51 | expectedNotificationOccurred = YES; 52 | } 53 | }]; 54 | ((EXPBasicBlock)actual)(); 55 | return YES; 56 | }); 57 | 58 | match(^BOOL{ 59 | if(expectedNotificationOccurred) { 60 | [[NSNotificationCenter defaultCenter] removeObserver:observer]; 61 | } 62 | return expectedNotificationOccurred; 63 | }); 64 | 65 | failureMessageForTo(^NSString *{ 66 | if (observer) { 67 | [[NSNotificationCenter defaultCenter] removeObserver:observer]; 68 | } 69 | if(actualIsNil) return @"the actual value is nil/null"; 70 | if(expectedIsNil) return @"the expected value is nil/null"; 71 | if(!(isNotification || isName)) return @"the actual value is not a notification or string"; 72 | return [NSString stringWithFormat:@"expected: %@, got: none",expectedName]; 73 | }); 74 | 75 | failureMessageForNotTo(^NSString *{ 76 | if (observer) { 77 | [[NSNotificationCenter defaultCenter] removeObserver:observer]; 78 | } 79 | if(actualIsNil) return @"the actual value is nil/null"; 80 | if(expectedIsNil) return @"the expected value is nil/null"; 81 | if(!(isNotification || isName)) return @"the actual value is not a notification or string"; 82 | return [NSString stringWithFormat:@"expected: none, got: %@", expectedName]; 83 | }); 84 | } 85 | 86 | EXPMatcherImplementationEnd 87 | 88 | EXPMatcherAliasImplementation(notify, postNotification, (id expectedNotification)) 89 | -------------------------------------------------------------------------------- /Pod/Classes/CVLogButton.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVLogButton.m 3 | // Pods 4 | // 5 | // Created by Cristian Villaseca on 12/3/16. 6 | // 7 | // 8 | 9 | #import "CVLogButton.h" 10 | 11 | #define kButtonMargin 5.0f 12 | 13 | @implementation CVLogButton 14 | 15 | -(instancetype)init { 16 | if (!(self = [super init])) { 17 | return nil; 18 | } 19 | [self commonInit]; 20 | return self; 21 | } 22 | 23 | -(instancetype)initWithCoder:(NSCoder *)aDecoder{ 24 | if (!(self = [super initWithCoder:aDecoder])) { 25 | return nil; 26 | } 27 | [self commonInit]; 28 | return self; 29 | } 30 | 31 | -(instancetype)initWithFrame:(CGRect)frame { 32 | if (!(self = [super initWithFrame:frame])) { 33 | return nil; 34 | } 35 | [self commonInit]; 36 | return self; 37 | } 38 | 39 | -(void) commonInit { 40 | self.frame = CGRectMake(50, 70, 40, 40); 41 | self.backgroundColor = [UIColor colorWithWhite:.6f alpha:.7f]; 42 | [self setShowsTouchWhenHighlighted:YES]; 43 | [self setTransparentWithAnimation]; 44 | } 45 | 46 | - (void)drawRect:(CGRect)rect { 47 | self.layer.cornerRadius = self.frame.size.width / 2; 48 | self.layer.masksToBounds = YES; 49 | } 50 | 51 | -(void) touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event { 52 | [super touchesBegan:touches withEvent:event]; 53 | self.backgroundColor = [UIColor colorWithWhite:.6f alpha:.7f]; 54 | } 55 | 56 | - (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event { 57 | 58 | UITouch *touch = [[event allTouches] anyObject]; 59 | UIWindow* currentWindow = [UIApplication sharedApplication].keyWindow; 60 | CGPoint touchLocation = [touch locationInView:currentWindow]; 61 | self.center = touchLocation; 62 | 63 | [self touchesCancelled:touches withEvent:event]; 64 | } 65 | 66 | -(void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event { 67 | [super touchesEnded:touches withEvent:event]; 68 | 69 | CGRect frame = self.frame; 70 | CGRect screenLimit = [[UIScreen mainScreen] bounds]; 71 | BOOL change = NO; 72 | 73 | if (self.frame.origin.x < kButtonMargin) { 74 | change = YES; 75 | frame.origin.x = kButtonMargin; 76 | } 77 | 78 | if (self.frame.origin.y < kButtonMargin) { 79 | change = YES; 80 | frame.origin.y = kButtonMargin; 81 | } 82 | 83 | if (self.frame.origin.x + self.frame.size.width > screenLimit.size.width - kButtonMargin ) { 84 | change = YES; 85 | frame.origin.x = screenLimit.size.width - kButtonMargin - frame.size.width ; 86 | 87 | } 88 | 89 | if (self.frame.origin.y + self.frame.size.height > screenLimit.size.height - kButtonMargin ) { 90 | change = YES; 91 | frame.origin.y = screenLimit.size.height - kButtonMargin - frame.size.height ; 92 | } 93 | 94 | if (change) { 95 | [UIView animateWithDuration:0.6 animations:^{ 96 | self.frame = frame; 97 | }]; 98 | } 99 | 100 | [self setTransparentWithAnimation]; 101 | 102 | } 103 | 104 | -(void) setTransparentWithAnimation { 105 | dispatch_after(dispatch_time(DISPATCH_TIME_NOW, 4 * NSEC_PER_SEC), dispatch_get_main_queue(), ^{ 106 | [UIView animateWithDuration:0.3 animations:^{ 107 | self.backgroundColor = [UIColor colorWithWhite:.8f alpha:.4f]; 108 | }]; 109 | 110 | }); 111 | } 112 | 113 | @end 114 | -------------------------------------------------------------------------------- /Example/CVLogger/CVAppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // CVAppDelegate.m 3 | // CVLogger 4 | // 5 | // Created by Cristian Villaseca on 03/12/2016. 6 | // Copyright (c) 2016 Cristian Villaseca. All rights reserved. 7 | // 8 | 9 | #import "CVAppDelegate.h" 10 | 11 | 12 | @implementation CVAppDelegate 13 | 14 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 15 | { 16 | [[UINavigationBar appearance] setBarTintColor:[UIColor colorWithRed:45.0f/255.0f green:149.0f/206.0f blue:206.0f/255.0f alpha:1]]; 17 | [[UINavigationBar appearance] setTranslucent:NO]; 18 | 19 | UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"Main" bundle:nil]; 20 | 21 | UIViewController *mainViewController = [storyboard instantiateInitialViewController]; 22 | 23 | self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; 24 | self.window.rootViewController = mainViewController; 25 | [self.window makeKeyAndVisible]; 26 | 27 | #ifdef DEBUG 28 | self.cvlogger =[[CVLogger alloc] init]; 29 | #endif 30 | 31 | for (int i = 0; i < 10; i++) { 32 | NSLog(@"Lorem ipsum dolor sit amet, at ridiculus fringilla tristique, ante commodo sed, commodo condimentum turpis, quam euismod praesent tincidunt. Erat vestibulum dui auctor dictumst sem in, ullamcorper sed morbi magna et suscipit dolore, consequatur ante laoreet, nisl eget. Sociis libero et sed euismod. Quis dictum lacus in quam, est duis integer pede facilisis mauris. In nec egestas lorem in morbi platea, enim aliquam consequat, cursus saepe blanditiis, ut risus malesuada quisque ornare ornare iaculis. Adipiscing dolor sed sed ut netus, ut at aenean interdum. Ligula sed adipiscing, adipiscing nisl pede eget adipisicing mauris proin, ac quam dui suspendisse diam ultrices massa. A a odio volutpat auctor."); 33 | } 34 | NSLog(@"last log entry"); 35 | return YES; 36 | } 37 | 38 | - (void)applicationWillResignActive:(UIApplication *)application 39 | { 40 | // 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. 41 | // 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. 42 | } 43 | 44 | - (void)applicationDidEnterBackground:(UIApplication *)application 45 | { 46 | // 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. 47 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 48 | } 49 | 50 | - (void)applicationWillEnterForeground:(UIApplication *)application 51 | { 52 | // 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. 53 | } 54 | 55 | - (void)applicationDidBecomeActive:(UIApplication *)application 56 | { 57 | // 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. 58 | } 59 | 60 | - (void)applicationWillTerminate:(UIApplication *)application 61 | { 62 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 63 | } 64 | 65 | @end 66 | -------------------------------------------------------------------------------- /Example/Pods/Expecta+Snapshots/README.md: -------------------------------------------------------------------------------- 1 | Expecta Matchers for FBSnapshotTestCase 2 | ======================================= 3 | 4 | [Expecta](https://github.com/specta/expecta) matchers for [ios-snapshot-test-case](https://github.com/facebook/ios-snapshot-test-case). 5 | 6 | [![Build Status](https://travis-ci.org/dblock/ios-snapshot-test-case-expecta.png)](https://travis-ci.org/dblock/ios-snapshot-test-case-expecta) 7 | 8 | ### Usage 9 | 10 | Add `Expecta+Snapshots` to your Podfile, the latest `FBSnapshotTestCase` will come in as a dependency. 11 | 12 | ``` ruby 13 | pod 'Expecta+Snapshots' 14 | ``` 15 | 16 | ### App setup 17 | 18 | Use `expect(view).to.recordSnapshotNamed(@"unique snapshot name")` to record a snapshot and `expect(view).to.haveValidSnapshotNamed(@"unique snapshot name")` to check it. 19 | 20 | If you project was compiled with Specta included, you have two extra methods that use the spec hierarchy to generate the snapshot name for you: `recordSnapshot()` and `haveValidSnapshot()`. You should only call these once per `it()` block. 21 | 22 | If you need the `usesDrawViewHierarchyInRect` property in order to correctly render UIVisualEffect, UIAppearance and Size Classes, call `[Expecta setUsesDrawViewHierarchyInRect:NO];` inside `beforeAll`. 23 | 24 | ``` Objective-C 25 | #define EXP_SHORTHAND 26 | #include 27 | #include 28 | #include 29 | #include "FBExampleView.h" 30 | 31 | SpecBegin(FBExampleView) 32 | 33 | describe(@"manual matching", ^{ 34 | 35 | it(@"matches view", ^{ 36 | FBExampleView *view = [[FBExampleView alloc] initWithFrame:CGRectMake(0, 0, 64, 64)]; 37 | expect(view).to.recordSnapshotNamed(@"FBExampleView"); 38 | expect(view).to.haveValidSnapshotNamed(@"FBExampleView"); 39 | }); 40 | 41 | it(@"doesn't match a view", ^{ 42 | FBExampleView *view = [[FBExampleView alloc] initWithFrame:CGRectMake(0, 0, 64, 64)]; 43 | expect(view).toNot.haveValidSnapshotNamed(@"FBExampleViewDoesNotExist"); 44 | }); 45 | 46 | }); 47 | 48 | describe(@"test name derived matching", ^{ 49 | 50 | it(@"matches view", ^{ 51 | FBExampleView *view = [[FBExampleView alloc] initWithFrame:CGRectMake(0, 0, 64, 64)]; 52 | expect(view).to.recordSnapshot(); 53 | expect(view).to.haveValidSnapshot(); 54 | }); 55 | 56 | it(@"doesn't match a view", ^{ 57 | FBExampleView *view = [[FBExampleView alloc] initWithFrame:CGRectMake(0, 0, 64, 64)]; 58 | expect(view).toNot.haveValidSnapshot(); 59 | }); 60 | 61 | }); 62 | 63 | SpecEnd 64 | ``` 65 | 66 | ### Sane defaults 67 | 68 | `EXPMatchers+FBSnapshotTest` will automatically figure out the tests folder, and [add a reference image](https://github.com/dblock/ios-snapshot-test-case-expecta/blob/master/EXPMatchers%2BFBSnapshotTest.m#L84-L85) directory, if you'd like to override this, you should include a `beforeAll` block setting the `setGlobalReferenceImageDir` in each file containing tests. 69 | 70 | ``` 71 | beforeAll(^{ 72 | setGlobalReferenceImageDir(FB_REFERENCE_IMAGE_DIR); 73 | }); 74 | ``` 75 | 76 | 77 | ### Example 78 | 79 | A complete project can be found in [FBSnapshotTestCaseDemo](FBSnapshotTestCaseDemo). 80 | 81 | Notably, take a look at [FBSnapshotTestCaseDemoSpecs.m](FBSnapshotTestCaseDemo/FBSnapshotTestCaseDemoTests/FBSnapshotTestCaseDemoSpecs.m) for a complete example, which is an expanded Specta version version of [FBSnapshotTestCaseDemoTests.m](https://github.com/facebook/ios-snapshot-test-case/blob/master/FBSnapshotTestCaseDemo/FBSnapshotTestCaseDemoTests/FBSnapshotTestCaseDemoTests.m). 82 | 83 | Finally you can consult the tests for [ARTiledImageView](https://github.com/dblock/ARTiledImageView/tree/master/IntegrationTests) or [NAMapKit](https://github.com/neilang/NAMapKit/tree/master/Demo/DemoTests). 84 | 85 | ### License 86 | 87 | MIT, see [LICENSE](LICENSE.md) 88 | -------------------------------------------------------------------------------- /Example/Pods/Specta/Specta/Specta/SpectaDSL.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #define SpecBegin(name) _SPTSpecBegin(name, __FILE__, __LINE__) 4 | #define SpecEnd _SPTSpecEnd 5 | 6 | #define SharedExamplesBegin(name) _SPTSharedExampleGroupsBegin(name) 7 | #define SharedExamplesEnd _SPTSharedExampleGroupsEnd 8 | #define SharedExampleGroupsBegin(name) _SPTSharedExampleGroupsBegin(name) 9 | #define SharedExampleGroupsEnd _SPTSharedExampleGroupsEnd 10 | 11 | typedef void (^DoneCallback)(void); 12 | 13 | OBJC_EXTERN void describe(NSString *name, void (^block)()); 14 | OBJC_EXTERN void fdescribe(NSString *name, void (^block)()); 15 | 16 | OBJC_EXTERN void context(NSString *name, void (^block)()); 17 | OBJC_EXTERN void fcontext(NSString *name, void (^block)()); 18 | 19 | OBJC_EXTERN void it(NSString *name, void (^block)()); 20 | OBJC_EXTERN void fit(NSString *name, void (^block)()); 21 | 22 | OBJC_EXTERN void example(NSString *name, void (^block)()); 23 | OBJC_EXTERN void fexample(NSString *name, void (^block)()); 24 | 25 | OBJC_EXTERN void specify(NSString *name, void (^block)()); 26 | OBJC_EXTERN void fspecify(NSString *name, void (^block)()); 27 | 28 | #define pending(...) spt_pending_(__VA_ARGS__, nil) 29 | #define xdescribe(...) spt_pending_(__VA_ARGS__, nil) 30 | #define xcontext(...) spt_pending_(__VA_ARGS__, nil) 31 | #define xexample(...) spt_pending_(__VA_ARGS__, nil) 32 | #define xit(...) spt_pending_(__VA_ARGS__, nil) 33 | #define xspecify(...) spt_pending_(__VA_ARGS__, nil) 34 | 35 | OBJC_EXTERN void beforeAll(void (^block)()); 36 | OBJC_EXTERN void afterAll(void (^block)()); 37 | 38 | OBJC_EXTERN void beforeEach(void (^block)()); 39 | OBJC_EXTERN void afterEach(void (^block)()); 40 | 41 | OBJC_EXTERN void before(void (^block)()); 42 | OBJC_EXTERN void after(void (^block)()); 43 | 44 | OBJC_EXTERN void sharedExamplesFor(NSString *name, void (^block)(NSDictionary *data)); 45 | OBJC_EXTERN void sharedExamples(NSString *name, void (^block)(NSDictionary *data)); 46 | 47 | #define itShouldBehaveLike(...) spt_itShouldBehaveLike_(@(__FILE__), __LINE__, __VA_ARGS__) 48 | #define itBehavesLike(...) spt_itShouldBehaveLike_(@(__FILE__), __LINE__, __VA_ARGS__) 49 | 50 | OBJC_EXTERN void waitUntil(void (^block)(DoneCallback done)); 51 | /** 52 | * Runs the @c block and waits until the @c done block is called or the 53 | * @c timeout has passed. 54 | * 55 | * @param timeout timeout for this @c block only; does not affect the global 56 | * timeout, as @c setAsyncSpecTimeout() does. 57 | * @param ^block runs test code 58 | */ 59 | OBJC_EXTERN void waitUntilTimeout(NSTimeInterval timeout, void (^block)(DoneCallback done)); 60 | 61 | OBJC_EXTERN void setAsyncSpecTimeout(NSTimeInterval timeout); 62 | 63 | // ---------------------------------------------------------------------------- 64 | 65 | #define _SPTSpecBegin(name, file, line) \ 66 | @interface name##Spec : SPTSpec \ 67 | @end \ 68 | @implementation name##Spec \ 69 | - (void)spec { \ 70 | [[self class] spt_setCurrentTestSuiteFileName:(@(file)) lineNumber:(line)]; 71 | 72 | #define _SPTSpecEnd \ 73 | } \ 74 | @end 75 | 76 | #define _SPTSharedExampleGroupsBegin(name) \ 77 | @interface name##SharedExampleGroups : SPTSharedExampleGroups \ 78 | @end \ 79 | @implementation name##SharedExampleGroups \ 80 | - (void)sharedExampleGroups { 81 | 82 | #define _SPTSharedExampleGroupsEnd \ 83 | } \ 84 | @end 85 | 86 | OBJC_EXTERN void spt_it_(NSString *name, NSString *fileName, NSUInteger lineNumber, void (^block)()); 87 | OBJC_EXTERN void spt_fit_(NSString *name, NSString *fileName, NSUInteger lineNumber, void (^block)()); 88 | OBJC_EXTERN void spt_pending_(NSString *name, ...); 89 | OBJC_EXTERN void spt_itShouldBehaveLike_(NSString *fileName, NSUInteger lineNumber, NSString *name, id dictionaryOrBlock); 90 | OBJC_EXTERN void spt_itShouldBehaveLike_block(NSString *fileName, NSUInteger lineNumber, NSString *name, NSDictionary *(^block)()); 91 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-CVLogger_Example/Pods-CVLogger_Example-frameworks.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | 4 | echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 5 | mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 6 | 7 | SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}" 8 | 9 | install_framework() 10 | { 11 | if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then 12 | local source="${BUILT_PRODUCTS_DIR}/$1" 13 | elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then 14 | local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")" 15 | elif [ -r "$1" ]; then 16 | local source="$1" 17 | fi 18 | 19 | local destination="${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 20 | 21 | if [ -L "${source}" ]; then 22 | echo "Symlinked..." 23 | source="$(readlink "${source}")" 24 | fi 25 | 26 | # use filter instead of exclude so missing patterns dont' throw errors 27 | echo "rsync -av --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\"" 28 | rsync -av --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}" 29 | 30 | local basename 31 | basename="$(basename -s .framework "$1")" 32 | binary="${destination}/${basename}.framework/${basename}" 33 | if ! [ -r "$binary" ]; then 34 | binary="${destination}/${basename}" 35 | fi 36 | 37 | # Strip invalid architectures so "fat" simulator / device frameworks work on device 38 | if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then 39 | strip_invalid_archs "$binary" 40 | fi 41 | 42 | # Resign the code if required by the build settings to avoid unstable apps 43 | code_sign_if_enabled "${destination}/$(basename "$1")" 44 | 45 | # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. 46 | if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then 47 | local swift_runtime_libs 48 | swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) 49 | for lib in $swift_runtime_libs; do 50 | echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" 51 | rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" 52 | code_sign_if_enabled "${destination}/${lib}" 53 | done 54 | fi 55 | } 56 | 57 | # Signs a framework with the provided identity 58 | code_sign_if_enabled() { 59 | if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then 60 | # Use the current code_sign_identitiy 61 | echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" 62 | echo "/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} --preserve-metadata=identifier,entitlements \"$1\"" 63 | /usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} --preserve-metadata=identifier,entitlements "$1" 64 | fi 65 | } 66 | 67 | # Strip invalid architectures 68 | strip_invalid_archs() { 69 | binary="$1" 70 | # Get architectures for current file 71 | archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | rev)" 72 | stripped="" 73 | for arch in $archs; do 74 | if ! [[ "${VALID_ARCHS}" == *"$arch"* ]]; then 75 | # Strip non-valid architectures in-place 76 | lipo -remove "$arch" -output "$binary" "$binary" || exit 1 77 | stripped="$stripped $arch" 78 | fi 79 | done 80 | if [[ "$stripped" ]]; then 81 | echo "Stripped $binary of architectures:$stripped" 82 | fi 83 | } 84 | 85 | 86 | if [[ "$CONFIGURATION" == "Debug" ]]; then 87 | install_framework "Pods-CVLogger_Example/CVLogger.framework" 88 | fi 89 | if [[ "$CONFIGURATION" == "Release" ]]; then 90 | install_framework "Pods-CVLogger_Example/CVLogger.framework" 91 | fi 92 | -------------------------------------------------------------------------------- /Example/Pods/FBSnapshotTestCase/README.md: -------------------------------------------------------------------------------- 1 | FBSnapshotTestCase 2 | ====================== 3 | 4 | [![Build Status](https://travis-ci.org/facebook/ios-snapshot-test-case.svg)](https://travis-ci.org/facebook/ios-snapshot-test-case) [![Cocoa Pod Version](https://cocoapod-badges.herokuapp.com/v/FBSnapshotTestCase/badge.svg)](http://cocoadocs.org/docsets/FBSnapshotTestCase/) 5 | 6 | What it does 7 | ------------ 8 | 9 | A "snapshot test case" takes a configured `UIView` or `CALayer` and uses the 10 | `renderInContext:` method to get an image snapshot of its contents. It 11 | compares this snapshot to a "reference image" stored in your source code 12 | repository and fails the test if the two images don't match. 13 | 14 | Why? 15 | ---- 16 | 17 | At Facebook we write a lot of UI code. As you might imagine, each type of 18 | feed story is rendered using a subclass of `UIView`. There are a lot of edge 19 | cases that we want to handle correctly: 20 | 21 | - What if there is more text than can fit in the space available? 22 | - What if an image doesn't match the size of an image view? 23 | - What should the highlighted state look like? 24 | 25 | It's straightforward to test logic code, but less obvious how you should test 26 | views. You can do a lot of rectangle asserts, but these are hard to understand 27 | or visualize. Looking at an image diff shows you exactly what changed and how 28 | it will look to users. 29 | 30 | We developed `FBSnapshotTestCase` to make snapshot tests easy. 31 | 32 | Installation with CocoaPods 33 | --------------------------- 34 | 35 | 1. Add the following lines to your Podfile: 36 | 37 | ``` 38 | target "Tests" do 39 | pod 'FBSnapshotTestCase' 40 | end 41 | ``` 42 | 43 | If you support iOS 7 use `FBSnapshotTestCase/Core` instead, which doesn't contain Swift support. 44 | 45 | Replace "Tests" with the name of your test project. 46 | 47 | 2. There are [three ways](https://github.com/facebook/ios-snapshot-test-case/blob/master/FBSnapshotTestCase/FBSnapshotTestCase.h#L19-L29) of setting reference image directories, the recommended one is to define `FB_REFERENCE_IMAGE_DIR` in your scheme. This should point to the directory where you want reference images to be stored. At Facebook, we normally use this: 48 | 49 | |Name|Value| 50 | |:---|:----| 51 | |`FB_REFERENCE_IMAGE_DIR`|`$(SOURCE_ROOT)/$(PROJECT_NAME)Tests/ReferenceImages`| 52 | 53 | 54 | ![](FBSnapshotTestCaseDemo/Scheme_FB_REFERENCE_IMAGE_DIR.png) 55 | 56 | Creating a snapshot test 57 | ------------------------ 58 | 59 | 1. Subclass `FBSnapshotTestCase` instead of `XCTestCase`. 60 | 2. From within your test, use `FBSnapshotVerifyView`. 61 | 3. Run the test once with `self.recordMode = YES;` in the test's `-setUp` 62 | method. (This creates the reference images on disk.) 63 | 4. Remove the line enabling record mode and run the test. 64 | 65 | Features 66 | -------- 67 | 68 | - Automatically names reference images on disk according to test class and 69 | selector. 70 | - Prints a descriptive error message to the console on failure. (Bonus: 71 | failure message includes a one-line command to see an image diff if 72 | you have [Kaleidoscope](http://www.kaleidoscopeapp.com) installed.) 73 | - Supply an optional "identifier" if you want to perform multiple snapshots 74 | in a single test method. 75 | - Support for `CALayer` via `FBSnapshotVerifyLayer`. 76 | - `usesDrawViewHierarchyInRect` to handle cases like `UIVisualEffect`, `UIAppearance` and Size Classes. 77 | - `isDeviceAgnostic` to allow appending the device model (`iPhone`, `iPad`, `iPod Touch`, etc), OS version and screen size to the images (allowing to have multiple tests for the same «snapshot» for different `OS`s and devices). 78 | 79 | Notes 80 | ----- 81 | 82 | Your unit test must be an "application test", not a "logic test." (That is, it 83 | must be run within the Simulator so that it has access to UIKit.) In Xcode 5 84 | and later new projects only offer application tests, but older projects will 85 | have separate targets for the two types. 86 | 87 | Authors 88 | ------- 89 | 90 | `FBSnapshotTestCase` was written at Facebook by 91 | [Jonathan Dann](https://facebook.com/j.p.dann) with significant contributions by 92 | [Todd Krabach](https://facebook.com/toddkrabach). 93 | 94 | License 95 | ------- 96 | 97 | `FBSnapshotTestCase` is BSD-licensed. See `LICENSE`. 98 | --------------------------------------------------------------------------------