second_curtain 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/.gitignore +20 -0
- data/.travis.yml +7 -0
- data/CHANGELOG +20 -0
- data/Demo/Demo/ASHAppDelegate.h +15 -0
- data/Demo/Demo/ASHAppDelegate.m +18 -0
- data/Demo/Demo/ASHViewController.h +13 -0
- data/Demo/Demo/ASHViewController.m +30 -0
- data/Demo/Demo/Base.lproj/Main.storyboard +30 -0
- data/Demo/Demo/Demo-Info.plist +40 -0
- data/Demo/Demo/Demo-Prefix.pch +16 -0
- data/Demo/Demo/Images.xcassets/AppIcon.appiconset/Contents.json +23 -0
- data/Demo/Demo/Images.xcassets/LaunchImage.launchimage/Contents.json +23 -0
- data/Demo/Demo/en.lproj/InfoPlist.strings +2 -0
- data/Demo/Demo/main.m +18 -0
- data/Demo/Demo.xcodeproj/project.pbxproj +517 -0
- data/Demo/Demo.xcodeproj/project.xcworkspace/contents.xcworkspacedata +7 -0
- data/Demo/Demo.xcodeproj/project.xcworkspace/xcshareddata/Demo.xccheckout +41 -0
- data/Demo/Demo.xcodeproj/project.xcworkspace/xcuserdata/ash.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- data/Demo/Demo.xcodeproj/xcshareddata/xcschemes/Demo.xcscheme +96 -0
- data/Demo/Demo.xcodeproj/xcuserdata/ash.xcuserdatad/xcschemes/xcschememanagement.plist +27 -0
- data/Demo/Demo.xcodeproj/xcuserdata/orta.xcuserdatad/xcschemes/xcschememanagement.plist +27 -0
- data/Demo/Demo.xcworkspace/contents.xcworkspacedata +1 -0
- data/Demo/Demo.xcworkspace/xcshareddata/Demo.xccheckout +41 -0
- data/Demo/Demo.xcworkspace/xcuserdata/ash.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- data/Demo/Demo.xcworkspace/xcuserdata/orta.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- data/Demo/DemoTests/DemoTests-Info.plist +22 -0
- data/Demo/DemoTests/DemoTests.m +52 -0
- data/Demo/DemoTests/ReferenceImages/ASHViewControllerSpec/a_view_controller_with_a_loaded_view_should_have_a_valid_snapshot@2x.png +0 -0
- data/Demo/DemoTests/ReferenceImages/ASHViewControllerSpec/views_should_be_green@2x.png +0 -0
- data/Demo/DemoTests/ReferenceImages/ASHViewControllerSpec/views_should_be_red@2x.png +0 -0
- data/Demo/DemoTests/en.lproj/InfoPlist.strings +2 -0
- data/Demo/Makefile +15 -0
- data/Demo/Podfile +16 -0
- data/Demo/Podfile.lock +21 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPBackwardCompatibility.h +42 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPBlockDefinedMatcher.h +25 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPDefines.h +17 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPDoubleTuple.h +13 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPExpect.h +45 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPFloatTuple.h +13 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatcher.h +20 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatcherHelpers.h +4 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beCloseTo.h +7 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beFalsy.h +3 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beGreaterThan.h +6 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beGreaterThanOrEqualTo.h +6 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beIdenticalTo.h +10 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beInTheRangeOf.h +6 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beInstanceOf.h +7 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beKindOf.h +5 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beLessThan.h +6 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beLessThanOrEqualTo.h +6 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beNil.h +5 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beSubclassOf.h +5 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beSupersetOf.h +4 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beTruthy.h +3 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+beginWith.h +5 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+conformTo.h +3 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+contain.h +5 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+endWith.h +3 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+equal.h +5 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+haveCountOf.h +10 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+notify.h +4 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+raise.h +4 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+raiseWithReason.h +3 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers+respondTo.h +3 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPMatchers.h +24 -0
- data/Demo/Pods/BuildHeaders/Expecta/EXPUnsupportedObject.h +11 -0
- data/Demo/Pods/BuildHeaders/Expecta/Expecta.h +27 -0
- data/Demo/Pods/BuildHeaders/Expecta/ExpectaSupport.h +64 -0
- data/Demo/Pods/BuildHeaders/Expecta/NSObject+Expecta.h +14 -0
- data/Demo/Pods/BuildHeaders/Expecta/NSValue+Expecta.h +8 -0
- data/Demo/Pods/BuildHeaders/Expecta+Snapshots/EXPMatchers+FBSnapshotTest.h +21 -0
- data/Demo/Pods/BuildHeaders/FBSnapshotTestCase/FBSnapshotTestCase.h +87 -0
- data/Demo/Pods/BuildHeaders/FBSnapshotTestCase/FBSnapshotTestController.h +147 -0
- data/Demo/Pods/BuildHeaders/FBSnapshotTestCase/UIImage+Compare.h +37 -0
- data/Demo/Pods/BuildHeaders/FBSnapshotTestCase/UIImage+Diff.h +37 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTExample.h +14 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTExampleGroup.h +40 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTNestedReporter.h +5 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTReporter.h +33 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTSharedExampleGroups.h +17 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTSpec.h +21 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTXCTestCase.h +27 -0
- data/Demo/Pods/BuildHeaders/Specta/SPTXCTestReporter.h +9 -0
- data/Demo/Pods/BuildHeaders/Specta/Specta.h +70 -0
- data/Demo/Pods/BuildHeaders/Specta/SpectaSupport.h +46 -0
- data/Demo/Pods/BuildHeaders/Specta/SpectaTypes.h +3 -0
- data/Demo/Pods/BuildHeaders/Specta/SpectaUtility.h +14 -0
- data/Demo/Pods/BuildHeaders/Specta/XCTestCase+Specta.h +4 -0
- data/Demo/Pods/BuildHeaders/Specta/XCTestLog+Specta.h +7 -0
- data/Demo/Pods/BuildHeaders/Specta/XCTestRun+Specta.h +8 -0
- data/Demo/Pods/Expecta/LICENSE +19 -0
- data/Demo/Pods/Expecta/README.md +308 -0
- data/Demo/Pods/Expecta/src/EXPBackwardCompatibility.h +42 -0
- data/Demo/Pods/Expecta/src/EXPBackwardCompatibility.m +17 -0
- data/Demo/Pods/Expecta/src/EXPBlockDefinedMatcher.h +25 -0
- data/Demo/Pods/Expecta/src/EXPBlockDefinedMatcher.m +60 -0
- data/Demo/Pods/Expecta/src/EXPDefines.h +17 -0
- data/Demo/Pods/Expecta/src/EXPDoubleTuple.h +13 -0
- data/Demo/Pods/Expecta/src/EXPDoubleTuple.m +42 -0
- data/Demo/Pods/Expecta/src/EXPExpect.h +45 -0
- data/Demo/Pods/Expecta/src/EXPExpect.m +214 -0
- data/Demo/Pods/Expecta/src/EXPFloatTuple.h +13 -0
- data/Demo/Pods/Expecta/src/EXPFloatTuple.m +42 -0
- data/Demo/Pods/Expecta/src/EXPMatcher.h +20 -0
- data/Demo/Pods/Expecta/src/EXPUnsupportedObject.h +11 -0
- data/Demo/Pods/Expecta/src/EXPUnsupportedObject.m +20 -0
- data/Demo/Pods/Expecta/src/Expecta.h +27 -0
- data/Demo/Pods/Expecta/src/Expecta.m +15 -0
- data/Demo/Pods/Expecta/src/ExpectaSupport.h +64 -0
- data/Demo/Pods/Expecta/src/ExpectaSupport.m +187 -0
- data/Demo/Pods/Expecta/src/NSObject+Expecta.h +14 -0
- data/Demo/Pods/Expecta/src/NSValue+Expecta.h +8 -0
- data/Demo/Pods/Expecta/src/NSValue+Expecta.m +21 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatcherHelpers.h +4 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatcherHelpers.m +9 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beCloseTo.h +7 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beCloseTo.m +49 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beFalsy.h +3 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beFalsy.m +24 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beGreaterThan.h +6 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beGreaterThan.m +20 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beGreaterThanOrEqualTo.h +6 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beGreaterThanOrEqualTo.m +20 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beIdenticalTo.h +10 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beIdenticalTo.m +24 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beInTheRangeOf.h +6 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beInTheRangeOf.m +30 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beInstanceOf.h +7 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beInstanceOf.m +27 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beKindOf.h +5 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beKindOf.m +27 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beLessThan.h +6 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beLessThan.m +20 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beLessThanOrEqualTo.h +6 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beLessThanOrEqualTo.m +20 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beNil.h +5 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beNil.m +16 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beSubclassOf.h +5 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beSubclassOf.m +27 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beSupersetOf.h +4 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beSupersetOf.m +57 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beTruthy.h +3 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beTruthy.m +24 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beginWith.h +5 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+beginWith.m +49 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+conformTo.h +3 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+conformTo.m +33 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+contain.h +5 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+contain.m +38 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+endWith.h +3 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+endWith.m +49 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+equal.h +5 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+equal.m +24 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+haveCountOf.h +10 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+haveCountOf.m +36 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+notify.h +4 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+notify.m +63 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+raise.h +4 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+raise.m +30 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+raiseWithReason.h +3 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+raiseWithReason.m +35 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+respondTo.h +3 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers+respondTo.m +28 -0
- data/Demo/Pods/Expecta/src/matchers/EXPMatchers.h +24 -0
- data/Demo/Pods/Expecta+Snapshots/EXPMatchers+FBSnapshotTest.h +21 -0
- data/Demo/Pods/Expecta+Snapshots/EXPMatchers+FBSnapshotTest.m +308 -0
- data/Demo/Pods/Expecta+Snapshots/LICENSE.md +22 -0
- data/Demo/Pods/Expecta+Snapshots/README.md +85 -0
- data/Demo/Pods/FBSnapshotTestCase/FBSnapshotTestCase.h +87 -0
- data/Demo/Pods/FBSnapshotTestCase/FBSnapshotTestCase.m +82 -0
- data/Demo/Pods/FBSnapshotTestCase/FBSnapshotTestController.h +147 -0
- data/Demo/Pods/FBSnapshotTestCase/FBSnapshotTestController.m +376 -0
- data/Demo/Pods/FBSnapshotTestCase/LICENSE +29 -0
- data/Demo/Pods/FBSnapshotTestCase/README.md +83 -0
- data/Demo/Pods/FBSnapshotTestCase/UIImage+Compare.h +37 -0
- data/Demo/Pods/FBSnapshotTestCase/UIImage+Compare.m +87 -0
- data/Demo/Pods/FBSnapshotTestCase/UIImage+Diff.h +37 -0
- data/Demo/Pods/FBSnapshotTestCase/UIImage+Diff.m +56 -0
- data/Demo/Pods/Headers/Expecta/EXPBackwardCompatibility.h +42 -0
- data/Demo/Pods/Headers/Expecta/EXPBlockDefinedMatcher.h +25 -0
- data/Demo/Pods/Headers/Expecta/EXPDefines.h +17 -0
- data/Demo/Pods/Headers/Expecta/EXPDoubleTuple.h +13 -0
- data/Demo/Pods/Headers/Expecta/EXPExpect.h +45 -0
- data/Demo/Pods/Headers/Expecta/EXPFloatTuple.h +13 -0
- data/Demo/Pods/Headers/Expecta/EXPMatcher.h +20 -0
- data/Demo/Pods/Headers/Expecta/EXPMatcherHelpers.h +4 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beCloseTo.h +7 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beFalsy.h +3 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beGreaterThan.h +6 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beGreaterThanOrEqualTo.h +6 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beIdenticalTo.h +10 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beInTheRangeOf.h +6 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beInstanceOf.h +7 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beKindOf.h +5 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beLessThan.h +6 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beLessThanOrEqualTo.h +6 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beNil.h +5 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beSubclassOf.h +5 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beSupersetOf.h +4 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beTruthy.h +3 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+beginWith.h +5 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+conformTo.h +3 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+contain.h +5 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+endWith.h +3 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+equal.h +5 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+haveCountOf.h +10 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+notify.h +4 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+raise.h +4 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+raiseWithReason.h +3 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers+respondTo.h +3 -0
- data/Demo/Pods/Headers/Expecta/EXPMatchers.h +24 -0
- data/Demo/Pods/Headers/Expecta/EXPUnsupportedObject.h +11 -0
- data/Demo/Pods/Headers/Expecta/Expecta.h +27 -0
- data/Demo/Pods/Headers/Expecta/ExpectaSupport.h +64 -0
- data/Demo/Pods/Headers/Expecta/NSObject+Expecta.h +14 -0
- data/Demo/Pods/Headers/Expecta/NSValue+Expecta.h +8 -0
- data/Demo/Pods/Headers/Expecta+Snapshots/EXPMatchers+FBSnapshotTest.h +21 -0
- data/Demo/Pods/Headers/FBSnapshotTestCase/FBSnapshotTestCase.h +87 -0
- data/Demo/Pods/Headers/FBSnapshotTestCase/FBSnapshotTestController.h +147 -0
- data/Demo/Pods/Headers/FBSnapshotTestCase/UIImage+Compare.h +37 -0
- data/Demo/Pods/Headers/FBSnapshotTestCase/UIImage+Diff.h +37 -0
- data/Demo/Pods/Headers/Specta/SPTExample.h +14 -0
- data/Demo/Pods/Headers/Specta/SPTExampleGroup.h +40 -0
- data/Demo/Pods/Headers/Specta/SPTNestedReporter.h +5 -0
- data/Demo/Pods/Headers/Specta/SPTReporter.h +33 -0
- data/Demo/Pods/Headers/Specta/SPTSharedExampleGroups.h +17 -0
- data/Demo/Pods/Headers/Specta/SPTSpec.h +21 -0
- data/Demo/Pods/Headers/Specta/SPTXCTestCase.h +27 -0
- data/Demo/Pods/Headers/Specta/SPTXCTestReporter.h +9 -0
- data/Demo/Pods/Headers/Specta/Specta.h +70 -0
- data/Demo/Pods/Headers/Specta/SpectaSupport.h +46 -0
- data/Demo/Pods/Headers/Specta/SpectaTypes.h +3 -0
- data/Demo/Pods/Headers/Specta/SpectaUtility.h +14 -0
- data/Demo/Pods/Headers/Specta/XCTestCase+Specta.h +4 -0
- data/Demo/Pods/Headers/Specta/XCTestLog+Specta.h +7 -0
- data/Demo/Pods/Headers/Specta/XCTestRun+Specta.h +8 -0
- data/Demo/Pods/Manifest.lock +21 -0
- data/Demo/Pods/Pods-DemoTests-EXPMatchers+FBSnapshotTest-Private.xcconfig +6 -0
- data/Demo/Pods/Pods-DemoTests-EXPMatchers+FBSnapshotTest-dummy.m +5 -0
- data/Demo/Pods/Pods-DemoTests-EXPMatchers+FBSnapshotTest-prefix.pch +5 -0
- data/Demo/Pods/Pods-DemoTests-EXPMatchers+FBSnapshotTest.xcconfig +2 -0
- data/Demo/Pods/Pods-DemoTests-Expecta+Snapshots-Private.xcconfig +6 -0
- data/Demo/Pods/Pods-DemoTests-Expecta+Snapshots-dummy.m +5 -0
- data/Demo/Pods/Pods-DemoTests-Expecta+Snapshots-prefix.pch +5 -0
- data/Demo/Pods/Pods-DemoTests-Expecta+Snapshots.xcconfig +2 -0
- data/Demo/Pods/Pods-DemoTests-Expecta-Private.xcconfig +5 -0
- data/Demo/Pods/Pods-DemoTests-Expecta-dummy.m +5 -0
- data/Demo/Pods/Pods-DemoTests-Expecta-prefix.pch +5 -0
- data/Demo/Pods/Pods-DemoTests-Expecta.xcconfig +1 -0
- data/Demo/Pods/Pods-DemoTests-FBSnapshotTestCase-Private.xcconfig +6 -0
- data/Demo/Pods/Pods-DemoTests-FBSnapshotTestCase-dummy.m +5 -0
- data/Demo/Pods/Pods-DemoTests-FBSnapshotTestCase-prefix.pch +6 -0
- data/Demo/Pods/Pods-DemoTests-FBSnapshotTestCase.xcconfig +2 -0
- data/Demo/Pods/Pods-DemoTests-Specta-Private.xcconfig +6 -0
- data/Demo/Pods/Pods-DemoTests-Specta-dummy.m +5 -0
- data/Demo/Pods/Pods-DemoTests-Specta-prefix.pch +5 -0
- data/Demo/Pods/Pods-DemoTests-Specta.xcconfig +2 -0
- data/Demo/Pods/Pods-DemoTests-acknowledgements.markdown +109 -0
- data/Demo/Pods/Pods-DemoTests-acknowledgements.plist +151 -0
- data/Demo/Pods/Pods-DemoTests-dummy.m +5 -0
- data/Demo/Pods/Pods-DemoTests-environment.h +32 -0
- data/Demo/Pods/Pods-DemoTests-resources.sh +68 -0
- data/Demo/Pods/Pods-DemoTests.xcconfig +6 -0
- data/Demo/Pods/Pods.xcodeproj/project.pbxproj +1390 -0
- data/Demo/Pods/Pods.xcodeproj/xcuserdata/ash.xcuserdatad/xcschemes/Pods-DemoTests-Expecta+Snapshots.xcscheme +59 -0
- data/Demo/Pods/Pods.xcodeproj/xcuserdata/ash.xcuserdatad/xcschemes/Pods-DemoTests-Expecta.xcscheme +59 -0
- data/Demo/Pods/Pods.xcodeproj/xcuserdata/ash.xcuserdatad/xcschemes/Pods-DemoTests-FBSnapshotTestCase.xcscheme +59 -0
- data/Demo/Pods/Pods.xcodeproj/xcuserdata/ash.xcuserdatad/xcschemes/Pods-DemoTests-Specta.xcscheme +59 -0
- data/Demo/Pods/Pods.xcodeproj/xcuserdata/ash.xcuserdatad/xcschemes/Pods-DemoTests.xcscheme +59 -0
- data/Demo/Pods/Pods.xcodeproj/xcuserdata/ash.xcuserdatad/xcschemes/xcschememanagement.plist +62 -0
- data/Demo/Pods/Specta/LICENSE +20 -0
- data/Demo/Pods/Specta/README.md +146 -0
- data/Demo/Pods/Specta/src/SPTExample.h +14 -0
- data/Demo/Pods/Specta/src/SPTExample.m +16 -0
- data/Demo/Pods/Specta/src/SPTExampleGroup.h +40 -0
- data/Demo/Pods/Specta/src/SPTExampleGroup.m +326 -0
- data/Demo/Pods/Specta/src/SPTNestedReporter.h +5 -0
- data/Demo/Pods/Specta/src/SPTNestedReporter.m +194 -0
- data/Demo/Pods/Specta/src/SPTReporter.h +33 -0
- data/Demo/Pods/Specta/src/SPTReporter.m +134 -0
- data/Demo/Pods/Specta/src/SPTSharedExampleGroups.h +17 -0
- data/Demo/Pods/Specta/src/SPTSharedExampleGroups.m +62 -0
- data/Demo/Pods/Specta/src/SPTSpec.h +21 -0
- data/Demo/Pods/Specta/src/SPTSpec.m +31 -0
- data/Demo/Pods/Specta/src/SPTXCTestCase.h +27 -0
- data/Demo/Pods/Specta/src/SPTXCTestCase.m +151 -0
- data/Demo/Pods/Specta/src/SPTXCTestReporter.h +9 -0
- data/Demo/Pods/Specta/src/SPTXCTestReporter.m +11 -0
- data/Demo/Pods/Specta/src/Specta.h +70 -0
- data/Demo/Pods/Specta/src/Specta.m +144 -0
- data/Demo/Pods/Specta/src/SpectaSupport.h +46 -0
- data/Demo/Pods/Specta/src/SpectaTypes.h +3 -0
- data/Demo/Pods/Specta/src/SpectaUtility.h +14 -0
- data/Demo/Pods/Specta/src/SpectaUtility.m +65 -0
- data/Demo/Pods/Specta/src/XCTestCase+Specta.h +4 -0
- data/Demo/Pods/Specta/src/XCTestCase+Specta.m +26 -0
- data/Demo/Pods/Specta/src/XCTestLog+Specta.h +7 -0
- data/Demo/Pods/Specta/src/XCTestLog+Specta.m +49 -0
- data/Demo/Pods/Specta/src/XCTestRun+Specta.h +8 -0
- data/Demo/Pods/Specta/src/XCTestRun+Specta.m +44 -0
- data/Gemfile +5 -0
- data/LICENSE +21 -0
- data/README.md +146 -0
- data/Rakefile +7 -0
- data/second_curtain.gemspec +20 -0
- data/spec/sample_output.txt +79 -0
- data/spec/second_shutter/kaleidoscope_command_spec.rb +25 -0
- data/spec/second_shutter/parser_spec.rb +39 -0
- data/spec/second_shutter/test_suite_spec.rb +32 -0
- data/spec/second_shutter/upload_manager_spec.rb +60 -0
- data/spec/second_shutter/upload_spec.rb +34 -0
- data/spec/second_shutter/xcode_test_case_spec.rb +22 -0
- metadata +315 -1
@@ -0,0 +1,27 @@
|
|
1
|
+
#import <Foundation/Foundation.h>
|
2
|
+
#import "ExpectaSupport.h"
|
3
|
+
|
4
|
+
#define EXPObjectify(value) _EXPObjectify(@encode(__typeof__((value))), (value))
|
5
|
+
|
6
|
+
#define EXP_expect(actual) _EXP_expect(self, __LINE__, __FILE__, ^id{ return EXPObjectify((actual)); })
|
7
|
+
|
8
|
+
#define EXPMatcherInterface(matcherName, matcherArguments) _EXPMatcherInterface(matcherName, matcherArguments)
|
9
|
+
#define EXPMatcherImplementationBegin(matcherName, matcherArguments) _EXPMatcherImplementationBegin(matcherName, matcherArguments)
|
10
|
+
#define EXPMatcherImplementationEnd _EXPMatcherImplementationEnd
|
11
|
+
|
12
|
+
#import "EXPMatchers.h"
|
13
|
+
|
14
|
+
#ifdef EXP_SHORTHAND
|
15
|
+
# define expect(...) EXP_expect((__VA_ARGS__))
|
16
|
+
#endif
|
17
|
+
|
18
|
+
#ifdef EXP_OLD_SYNTAX
|
19
|
+
# import "EXPBackwardCompatibility.h"
|
20
|
+
#endif
|
21
|
+
|
22
|
+
@interface Expecta : NSObject
|
23
|
+
|
24
|
+
+ (NSTimeInterval)asynchronousTestTimeout;
|
25
|
+
+ (void)setAsynchronousTestTimeout:(NSTimeInterval)timeout;
|
26
|
+
|
27
|
+
@end
|
@@ -0,0 +1,64 @@
|
|
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
|
+
} copy]; \
|
57
|
+
_EXP_release(matcher); \
|
58
|
+
return _EXP_autorelease(matcherBlock); \
|
59
|
+
} \
|
60
|
+
@end
|
61
|
+
|
62
|
+
#ifdef __cplusplus
|
63
|
+
}
|
64
|
+
#endif
|
@@ -0,0 +1,14 @@
|
|
1
|
+
#import <Foundation/Foundation.h>
|
2
|
+
|
3
|
+
@interface NSObject (Expecta)
|
4
|
+
|
5
|
+
#ifdef USE_XCTEST
|
6
|
+
- (void)recordFailureWithDescription:(NSString *)description
|
7
|
+
inFile:(NSString *)filename
|
8
|
+
atLine:(NSUInteger)lineNumber
|
9
|
+
expected:(BOOL)expected;
|
10
|
+
#else
|
11
|
+
- (void)failWithException:(NSException *)exception;
|
12
|
+
#endif
|
13
|
+
|
14
|
+
@end
|
@@ -0,0 +1,21 @@
|
|
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 <Expecta/Expecta.h>
|
10
|
+
|
11
|
+
@interface EXPExpectFBSnapshotTest : NSObject
|
12
|
+
@end
|
13
|
+
|
14
|
+
/// Set the default folder for image tests to run in
|
15
|
+
extern void setGlobalReferenceImageDir(char *reference);
|
16
|
+
|
17
|
+
EXPMatcherInterface(haveValidSnapshot, (void));
|
18
|
+
EXPMatcherInterface(recordSnapshot, (void));
|
19
|
+
|
20
|
+
EXPMatcherInterface(haveValidSnapshotNamed, (NSString *snapshot));
|
21
|
+
EXPMatcherInterface(recordSnapshotNamed, (NSString *snapshot));
|
@@ -0,0 +1,87 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) 2013, 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 <QuartzCore/QuartzCore.h>
|
12
|
+
|
13
|
+
#import <UIKit/UIKit.h>
|
14
|
+
|
15
|
+
#import <XCTest/XCTest.h>
|
16
|
+
|
17
|
+
#ifndef FB_REFERENCE_IMAGE_DIR
|
18
|
+
#define FB_REFERENCE_IMAGE_DIR "\"$(SOURCE_ROOT)/$(PROJECT_NAME)Tests/ReferenceImages\""
|
19
|
+
#endif
|
20
|
+
|
21
|
+
/**
|
22
|
+
Similar to our much-loved XCTAssert() macros. Use this to perform your test. No need to write an explanation, though.
|
23
|
+
@param view The view to snapshot
|
24
|
+
@param identifier An optional identifier, used is there are multiple snapshot tests in a given -test method.
|
25
|
+
*/
|
26
|
+
#define FBSnapshotVerifyView(view__, identifier__) \
|
27
|
+
{ \
|
28
|
+
NSError *error__ = nil; \
|
29
|
+
NSString *referenceImagesDirectory__ = [NSString stringWithFormat:@"%s", FB_REFERENCE_IMAGE_DIR]; \
|
30
|
+
BOOL comparisonSuccess__ = [self compareSnapshotOfView:(view__) referenceImagesDirectory:referenceImagesDirectory__ identifier:(identifier__) error:&error__]; \
|
31
|
+
XCTAssertTrue(comparisonSuccess__, @"Snapshot comparison failed: %@", error__); \
|
32
|
+
}
|
33
|
+
|
34
|
+
/**
|
35
|
+
Similar to our much-loved XCTAssert() macros. Use this to perform your test. No need to write an explanation, though.
|
36
|
+
@param layer The layer to snapshot
|
37
|
+
@param identifier An optional identifier, used is there are multiple snapshot tests in a given -test method.
|
38
|
+
*/
|
39
|
+
#define FBSnapshotVerifyLayer(layer__, identifier__) \
|
40
|
+
{ \
|
41
|
+
NSError *error__ = nil; \
|
42
|
+
NSString *referenceImagesDirectory__ = [NSString stringWithFormat:@"%s", FB_REFERENCE_IMAGE_DIR]; \
|
43
|
+
BOOL comparisonSuccess__ = [self compareSnapshotOfLayer:(layer__) referenceImagesDirectory:referenceImagesDirectory__ identifier:(identifier__) error:&error__]; \
|
44
|
+
XCTAssertTrue(comparisonSuccess__, @"Snapshot comparison failed: %@", error__); \
|
45
|
+
}
|
46
|
+
|
47
|
+
/**
|
48
|
+
The base class of view snapshotting tests. If you have small UI component, it's often easier to configure it in a test
|
49
|
+
and compare an image of the view to a reference image that write lots of complex layout-code tests.
|
50
|
+
|
51
|
+
In order to flip the tests in your subclass to record the reference images set `recordMode` to YES before calling
|
52
|
+
-[super setUp].
|
53
|
+
*/
|
54
|
+
@interface FBSnapshotTestCase : XCTestCase
|
55
|
+
|
56
|
+
/**
|
57
|
+
When YES, the test macros will save reference images, rather than performing an actual test.
|
58
|
+
*/
|
59
|
+
@property (readwrite, nonatomic, assign) BOOL recordMode;
|
60
|
+
|
61
|
+
/**
|
62
|
+
Performs the comparisong or records a snapshot of the layer if recordMode is YES.
|
63
|
+
@param layer The Layer to snapshot
|
64
|
+
@param referenceImagesDirectory The directory in which reference images are stored.
|
65
|
+
@param identifier An optional identifier, used is there are muliptle snapshot tests in a given -test method.
|
66
|
+
@param error An error to log in an XCTAssert() macro if the method fails (missing reference image, images differ, etc).
|
67
|
+
@returns YES if the comparison (or saving of the reference image) succeeded.
|
68
|
+
*/
|
69
|
+
- (BOOL)compareSnapshotOfLayer:(CALayer *)layer
|
70
|
+
referenceImagesDirectory:(NSString *)referenceImagesDirectory
|
71
|
+
identifier:(NSString *)identifier
|
72
|
+
error:(NSError **)errorPtr;
|
73
|
+
|
74
|
+
/**
|
75
|
+
Performs the comparisong or records a snapshot of the view if recordMode is YES.
|
76
|
+
@param view The view to snapshot
|
77
|
+
@param referenceImagesDirectory The directory in which reference images are stored.
|
78
|
+
@param identifier An optional identifier, used is there are muliptle snapshot tests in a given -test method.
|
79
|
+
@param error An error to log in an XCTAssert() macro if the method fails (missing reference image, images differ, etc).
|
80
|
+
@returns YES if the comparison (or saving of the reference image) succeeded.
|
81
|
+
*/
|
82
|
+
- (BOOL)compareSnapshotOfView:(UIView *)view
|
83
|
+
referenceImagesDirectory:(NSString *)referenceImagesDirectory
|
84
|
+
identifier:(NSString *)identifier
|
85
|
+
error:(NSError **)errorPtr;
|
86
|
+
|
87
|
+
@end
|
@@ -0,0 +1,147 @@
|
|
1
|
+
/*
|
2
|
+
* Copyright (c) 2013, 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 <Foundation/Foundation.h>
|
12
|
+
#import <UIKit/UIKit.h>
|
13
|
+
|
14
|
+
typedef NS_ENUM(NSInteger, FBSnapshotTestControllerErrorCode) {
|
15
|
+
FBSnapshotTestControllerErrorCodeUnknown,
|
16
|
+
FBSnapshotTestControllerErrorCodeNeedsRecord,
|
17
|
+
FBSnapshotTestControllerErrorCodePNGCreationFailed,
|
18
|
+
FBSnapshotTestControllerErrorCodeImagesDifferentSizes,
|
19
|
+
FBSnapshotTestControllerErrorCodeImagesDifferent,
|
20
|
+
};
|
21
|
+
/**
|
22
|
+
Errors returned by the methods of FBSnapshotTestController use this domain.
|
23
|
+
*/
|
24
|
+
extern NSString *const FBSnapshotTestControllerErrorDomain;
|
25
|
+
|
26
|
+
/**
|
27
|
+
Errors returned by the methods of FBSnapshotTestController sometimes contain this key in the `userInfo` dictionary.
|
28
|
+
*/
|
29
|
+
extern NSString *const FBReferenceImageFilePathKey;
|
30
|
+
|
31
|
+
/**
|
32
|
+
Provides the heavy-lifting for FBSnapshotTestCase. It loads and saves images, along with performing the actual pixel-
|
33
|
+
by-pixel comparison of images.
|
34
|
+
Instances are initialized with the test class, and directories to read and write to.
|
35
|
+
*/
|
36
|
+
@interface FBSnapshotTestController : NSObject
|
37
|
+
|
38
|
+
/**
|
39
|
+
Record snapshots.
|
40
|
+
**/
|
41
|
+
@property(readwrite, nonatomic, assign) BOOL recordMode;
|
42
|
+
|
43
|
+
/**
|
44
|
+
Designated initializer.
|
45
|
+
Before this methods returns the controller enumerates over the test methods in `testClass` and loads the images
|
46
|
+
for those tests.
|
47
|
+
@param testClass The subclass of FBSnapshotTestCase that is using this controller.
|
48
|
+
@param referenceImagesDirectory The directory where the reference images are stored.
|
49
|
+
@returns An instance of FBSnapshotTestController.
|
50
|
+
*/
|
51
|
+
- (id)initWithTestClass:(Class)testClass;
|
52
|
+
|
53
|
+
|
54
|
+
/**
|
55
|
+
Performs the comparison of the layer.
|
56
|
+
@param layer The Layer to snapshot.
|
57
|
+
@param referenceImagesDirectory The directory in which reference images are stored.
|
58
|
+
@param identifier An optional identifier, used is there are muliptle snapshot tests in a given -test method.
|
59
|
+
@param error An error to log in an XCTAssert() macro if the method fails (missing reference image, images differ, etc).
|
60
|
+
@returns YES if the comparison (or saving of the reference image) succeeded.
|
61
|
+
*/
|
62
|
+
- (BOOL)compareSnapshotOfLayer:(CALayer *)layer
|
63
|
+
selector:(SEL)selector
|
64
|
+
identifier:(NSString *)identifier
|
65
|
+
error:(NSError **)errorPtr;
|
66
|
+
|
67
|
+
/**
|
68
|
+
Performs the comparison of the view.
|
69
|
+
@param view The view to snapshot.
|
70
|
+
@param referenceImagesDirectory The directory in which reference images are stored.
|
71
|
+
@param identifier An optional identifier, used is there are muliptle snapshot tests in a given -test method.
|
72
|
+
@param error An error to log in an XCTAssert() macro if the method fails (missing reference image, images differ, etc).
|
73
|
+
@returns YES if the comparison (or saving of the reference image) succeeded.
|
74
|
+
*/
|
75
|
+
- (BOOL)compareSnapshotOfView:(UIView *)view
|
76
|
+
selector:(SEL)selector
|
77
|
+
identifier:(NSString *)identifier
|
78
|
+
error:(NSError **)errorPtr;
|
79
|
+
|
80
|
+
/**
|
81
|
+
Performs the comparison of a view or layer.
|
82
|
+
@param view The view or layer to snapshot.
|
83
|
+
@param referenceImagesDirectory The directory in which reference images are stored.
|
84
|
+
@param identifier An optional identifier, used is there are muliptle snapshot tests in a given -test method.
|
85
|
+
@param error An error to log in an XCTAssert() macro if the method fails (missing reference image, images differ, etc).
|
86
|
+
@returns YES if the comparison (or saving of the reference image) succeeded.
|
87
|
+
*/
|
88
|
+
- (BOOL)compareSnapshotOfViewOrLayer:(id)viewOrLayer
|
89
|
+
selector:(SEL)selector
|
90
|
+
identifier:(NSString *)identifier
|
91
|
+
error:(NSError **)errorPtr;
|
92
|
+
|
93
|
+
|
94
|
+
/**
|
95
|
+
The directory in which referfence images are stored.
|
96
|
+
*/
|
97
|
+
@property (readwrite, nonatomic, copy) NSString *referenceImagesDirectory;
|
98
|
+
|
99
|
+
/**
|
100
|
+
Loads a reference image.
|
101
|
+
@param selector The test method being run.
|
102
|
+
@param identifier The optional identifier, used when multiple images are tested in a single -test method.
|
103
|
+
@param error An error, if this methods returns nil, the error will be something useful.
|
104
|
+
@returns An image.
|
105
|
+
*/
|
106
|
+
- (UIImage *)referenceImageForSelector:(SEL)selector
|
107
|
+
identifier:(NSString *)identifier
|
108
|
+
error:(NSError **)error;
|
109
|
+
|
110
|
+
/**
|
111
|
+
Saves a reference image.
|
112
|
+
@param selector The test method being run.
|
113
|
+
@param identifier The optional identifier, used when multiple images are tested in a single -test method.
|
114
|
+
@param error An error, if this methods returns NO, the error will be something useful.
|
115
|
+
@returns An image.
|
116
|
+
*/
|
117
|
+
- (BOOL)saveReferenceImage:(UIImage *)image
|
118
|
+
selector:(SEL)selector
|
119
|
+
identifier:(NSString *)identifier
|
120
|
+
error:(NSError **)errorPtr;
|
121
|
+
|
122
|
+
/**
|
123
|
+
Performs a pixel-by-pixel comparison of the two images.
|
124
|
+
@param referenceImage The reference (correct) image.
|
125
|
+
@param image The image to test against the reference.
|
126
|
+
@param error An error that indicates why the comparison failed if it does.
|
127
|
+
@param YES if the comparison succeeded and the images are the same.
|
128
|
+
*/
|
129
|
+
- (BOOL)compareReferenceImage:(UIImage *)referenceImage
|
130
|
+
toImage:(UIImage *)image
|
131
|
+
error:(NSError **)errorPtr;
|
132
|
+
|
133
|
+
/**
|
134
|
+
Saves the reference image and the test image to `failedOutputDirectory`.
|
135
|
+
@param referenceImage The reference (correct) image.
|
136
|
+
@param testImage The image to test against the reference.
|
137
|
+
@param selector The test method being run.
|
138
|
+
@param identifier The optional identifier, used when multiple images are tested in a single -test method.
|
139
|
+
@param error An error that indicates why the comparison failed if it does.
|
140
|
+
@param YES if the save succeeded.
|
141
|
+
*/
|
142
|
+
- (BOOL)saveFailedReferenceImage:(UIImage *)referenceImage
|
143
|
+
testImage:(UIImage *)testImage
|
144
|
+
selector:(SEL)selector
|
145
|
+
identifier:(NSString *)identifier
|
146
|
+
error:(NSError **)errorPtr;
|
147
|
+
@end
|
@@ -0,0 +1,37 @@
|
|
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 <UIKit/UIKit.h>
|
32
|
+
|
33
|
+
@interface UIImage (Compare)
|
34
|
+
|
35
|
+
- (BOOL)compareWithImage:(UIImage *)image;
|
36
|
+
|
37
|
+
@end
|
@@ -0,0 +1,37 @@
|
|
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 <UIKit/UIKit.h>
|
32
|
+
|
33
|
+
@interface UIImage (Diff)
|
34
|
+
|
35
|
+
- (UIImage *)diffWithImage:(UIImage *)image;
|
36
|
+
|
37
|
+
@end
|
@@ -0,0 +1,14 @@
|
|
1
|
+
#import <Foundation/Foundation.h>
|
2
|
+
#import "SpectaTypes.h"
|
3
|
+
|
4
|
+
@interface SPTExample : NSObject
|
5
|
+
|
6
|
+
@property (nonatomic, copy) NSString *name;
|
7
|
+
@property (nonatomic, copy) id block;
|
8
|
+
@property (nonatomic) BOOL pending;
|
9
|
+
@property (nonatomic, getter = isFocused) BOOL focused;
|
10
|
+
|
11
|
+
- (id)initWithName:(NSString *)name block:(id)block;
|
12
|
+
|
13
|
+
@end
|
14
|
+
|
@@ -0,0 +1,40 @@
|
|
1
|
+
#import <Foundation/Foundation.h>
|
2
|
+
#import <XCTest/XCTest.h>
|
3
|
+
#import "SpectaTypes.h"
|
4
|
+
|
5
|
+
@class
|
6
|
+
SPTExample
|
7
|
+
;
|
8
|
+
|
9
|
+
@interface SPTExampleGroup : NSObject
|
10
|
+
|
11
|
+
@property (nonatomic, copy) NSString *name;
|
12
|
+
@property (nonatomic, strong) SPTExampleGroup *root;
|
13
|
+
@property (nonatomic, strong) SPTExampleGroup *parent;
|
14
|
+
@property (nonatomic, strong) NSMutableArray *children;
|
15
|
+
@property (nonatomic, strong) NSMutableArray *beforeAllArray;
|
16
|
+
@property (nonatomic, strong) NSMutableArray *afterAllArray;
|
17
|
+
@property (nonatomic, strong) NSMutableArray *beforeEachArray;
|
18
|
+
@property (nonatomic, strong) NSMutableArray *afterEachArray;
|
19
|
+
@property (nonatomic, strong) NSMutableDictionary *sharedExamples;
|
20
|
+
@property (nonatomic) unsigned int exampleCount;
|
21
|
+
@property (nonatomic) unsigned int ranExampleCount;
|
22
|
+
@property (nonatomic, getter=isFocused) BOOL focused;
|
23
|
+
|
24
|
+
+ (void)setAsyncSpecTimeout:(NSTimeInterval)timeout;
|
25
|
+
- (id)initWithName:(NSString *)name parent:(SPTExampleGroup *)parent root:(SPTExampleGroup *)root;
|
26
|
+
|
27
|
+
- (SPTExampleGroup *)addExampleGroupWithName:(NSString *)name;
|
28
|
+
- (SPTExampleGroup *)addExampleGroupWithName:(NSString *)name focused:(BOOL)focused;
|
29
|
+
|
30
|
+
- (SPTExample *)addExampleWithName:(NSString *)name block:(id)block;
|
31
|
+
- (SPTExample *)addExampleWithName:(NSString *)name block:(id)block focused:(BOOL)focused;
|
32
|
+
|
33
|
+
- (void)addBeforeAllBlock:(SPTVoidBlock)block;
|
34
|
+
- (void)addAfterAllBlock:(SPTVoidBlock)block;
|
35
|
+
- (void)addBeforeEachBlock:(SPTVoidBlock)block;
|
36
|
+
- (void)addAfterEachBlock:(SPTVoidBlock)block;
|
37
|
+
|
38
|
+
- (NSArray *)compileExamplesWithNameStack:(NSArray *)nameStack;
|
39
|
+
|
40
|
+
@end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
#import <XCTest/XCTest.h>
|
2
|
+
|
3
|
+
@interface SPTReporter : XCTestLog
|
4
|
+
|
5
|
+
/*
|
6
|
+
* Returns a singleton reporter used to generate Specta's test output.
|
7
|
+
* The type of reporter can be customized by subclassing and setting the
|
8
|
+
* SPECTA_REPORTER_CLASS environment variable.
|
9
|
+
*
|
10
|
+
* Subclasses may override methods from XCTestObserver to change test output.
|
11
|
+
* Initialization shuld be performed in the -startObserving / -stopObserving methods,
|
12
|
+
* and MUST invoke the super class implementation.
|
13
|
+
*/
|
14
|
+
+ (instancetype)sharedReporter;
|
15
|
+
|
16
|
+
#pragma mark - Run Stack
|
17
|
+
|
18
|
+
@property (nonatomic, strong, readonly) NSArray *runStack;
|
19
|
+
@property (nonatomic, assign, readonly) NSUInteger runStackCount;
|
20
|
+
|
21
|
+
@property (nonatomic, assign, readonly) NSInteger numberOfTestCases;
|
22
|
+
@property (nonatomic, assign, readonly) NSInteger numberOfCompletedTestCases;
|
23
|
+
|
24
|
+
#pragma mark - Printing
|
25
|
+
|
26
|
+
- (void)printString:(NSString *)string;
|
27
|
+
- (void)printStringWithFormat:(NSString *)formatString, ... NS_FORMAT_FUNCTION(1,2);
|
28
|
+
|
29
|
+
- (void)printLine;
|
30
|
+
- (void)printLine:(NSString *)line;
|
31
|
+
- (void)printLineWithFormat:(NSString *)formatString, ... NS_FORMAT_FUNCTION(1,2);
|
32
|
+
|
33
|
+
@end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
#import <Foundation/Foundation.h>
|
2
|
+
#import "SpectaTypes.h"
|
3
|
+
|
4
|
+
@class
|
5
|
+
SPTExampleGroup
|
6
|
+
;
|
7
|
+
|
8
|
+
@interface SPTSharedExampleGroups : NSObject
|
9
|
+
|
10
|
+
+ (void)addSharedExampleGroupWithName:(NSString *)name block:(SPTDictionaryBlock)block exampleGroup:(SPTExampleGroup *)exampleGroup;
|
11
|
+
+ (SPTDictionaryBlock)sharedExampleGroupWithName:(NSString *)name exampleGroup:(SPTExampleGroup *)exampleGroup;
|
12
|
+
+ (void)defineSharedExampleGroups;
|
13
|
+
|
14
|
+
+ (void)recordFailureWithDescription:(NSString *)description inFile:(NSString *)filename atLine:(NSUInteger)lineNumber expected:(BOOL)expected;
|
15
|
+
|
16
|
+
@end
|
17
|
+
|
@@ -0,0 +1,21 @@
|
|
1
|
+
#import <Foundation/Foundation.h>
|
2
|
+
|
3
|
+
@class
|
4
|
+
SPTExample
|
5
|
+
, SPTExampleGroup
|
6
|
+
;
|
7
|
+
|
8
|
+
@interface SPTSpec : NSObject
|
9
|
+
|
10
|
+
@property (nonatomic, strong) SPTExampleGroup *rootGroup;
|
11
|
+
@property (nonatomic, strong) NSMutableArray *groupStack;
|
12
|
+
@property (nonatomic, strong) NSArray *compiledExamples;
|
13
|
+
@property (nonatomic, strong) 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
|
@@ -0,0 +1,27 @@
|
|
1
|
+
#import <XCTest/XCTest.h>
|
2
|
+
#import "XCTestCase+Specta.h"
|
3
|
+
|
4
|
+
@class
|
5
|
+
SPTSpec
|
6
|
+
, SPTExample
|
7
|
+
;
|
8
|
+
|
9
|
+
@interface SPTXCTestCase : XCTestCase
|
10
|
+
|
11
|
+
@property (nonatomic, strong) NSInvocation *spt_invocation;
|
12
|
+
@property (nonatomic, strong) XCTestCaseRun *spt_run;
|
13
|
+
@property (nonatomic, assign) BOOL spt_skipped;
|
14
|
+
@property (nonatomic, assign, readonly, getter = spt_isPending) BOOL spt_pending;
|
15
|
+
|
16
|
+
+ (BOOL)spt_isDisabled;
|
17
|
+
+ (void)spt_setDisabled:(BOOL)disabled;
|
18
|
+
+ (BOOL)spt_focusedExamplesExist;
|
19
|
+
|
20
|
+
+ (SPTSpec *)spt_spec;
|
21
|
+
- (void)spt_setCurrentSpecWithFileName:(const char *)fileName lineNumber:(NSUInteger)lineNumber;
|
22
|
+
- (void)spt_defineSpec;
|
23
|
+
- (void)spt_unsetCurrentSpec;
|
24
|
+
- (void)spt_runExampleAtIndex:(NSUInteger)index;
|
25
|
+
- (SPTExample *)spt_getCurrentExample;
|
26
|
+
|
27
|
+
@end
|
@@ -0,0 +1,9 @@
|
|
1
|
+
#import "SPTReporter.h"
|
2
|
+
|
3
|
+
/**
|
4
|
+
* Reporter that produces output identical to XCode's default output. Useful when integrating with 3rd-party tools that
|
5
|
+
* may not like SPTNestedReporter's indented output.
|
6
|
+
*/
|
7
|
+
@interface SPTXCTestReporter : SPTReporter
|
8
|
+
|
9
|
+
@end
|