Merge pull request #486 from stripe/bdorfman-snapshot-tests
Snapshot test support
This commit is contained in:
commit
7e874a12a3
|
@ -0,0 +1 @@
|
|||
github "facebook/ios-snapshot-test-case" "2.1.4"
|
|
@ -133,7 +133,7 @@
|
|||
04823F701A6849200098400B /* Project object */ = {
|
||||
isa = PBXProject;
|
||||
attributes = {
|
||||
LastSwiftUpdateCheck = 0720;
|
||||
LastSwiftUpdateCheck = 0800;
|
||||
LastUpgradeCheck = 0800;
|
||||
ORGANIZATIONNAME = Stripe;
|
||||
TargetAttributes = {
|
||||
|
|
|
@ -567,6 +567,8 @@
|
|||
F1510BBF1D5A8146000731AD /* stp_card_jcb_template.png in Resources */ = {isa = PBXBuildFile; fileRef = F1510BBC1D5A8146000731AD /* stp_card_jcb_template.png */; };
|
||||
F1510BC21D5A8146000731AD /* stp_card_jcb_template@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = F1510BBD1D5A8146000731AD /* stp_card_jcb_template@2x.png */; };
|
||||
F1510BC51D5A8146000731AD /* stp_card_jcb_template@3x.png in Resources */ = {isa = PBXBuildFile; fileRef = F1510BBE1D5A8146000731AD /* stp_card_jcb_template@3x.png */; };
|
||||
F15AC18E1DBA9CA90009EADE /* FBSnapshotTestCase.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F15AC18D1DBA9CA90009EADE /* FBSnapshotTestCase.framework */; };
|
||||
F15AC1901DBA9CC60009EADE /* FBSnapshotTestCase.framework in CopyFiles */ = {isa = PBXBuildFile; fileRef = F15AC18D1DBA9CA90009EADE /* FBSnapshotTestCase.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
|
||||
F1852F931D80B6EC00367C86 /* STPStringUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = F1852F911D80B6EC00367C86 /* STPStringUtils.h */; };
|
||||
F1852F941D80B6EC00367C86 /* STPStringUtils.h in Headers */ = {isa = PBXBuildFile; fileRef = F1852F911D80B6EC00367C86 /* STPStringUtils.h */; };
|
||||
F1852F951D80B6EC00367C86 /* STPStringUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = F1852F921D80B6EC00367C86 /* STPStringUtils.m */; };
|
||||
|
@ -630,6 +632,16 @@
|
|||
name = "Copy Files";
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
F15AC18F1DBA9CC10009EADE /* CopyFiles */ = {
|
||||
isa = PBXCopyFilesBuildPhase;
|
||||
buildActionMask = 2147483647;
|
||||
dstPath = "";
|
||||
dstSubfolderSpec = 10;
|
||||
files = (
|
||||
F15AC1901DBA9CC60009EADE /* FBSnapshotTestCase.framework in CopyFiles */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
/* End PBXCopyFilesBuildPhase section */
|
||||
|
||||
/* Begin PBXFileReference section */
|
||||
|
@ -950,6 +962,7 @@
|
|||
F1510BBC1D5A8146000731AD /* stp_card_jcb_template.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = stp_card_jcb_template.png; sourceTree = "<group>"; };
|
||||
F1510BBD1D5A8146000731AD /* stp_card_jcb_template@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "stp_card_jcb_template@2x.png"; sourceTree = "<group>"; };
|
||||
F1510BBE1D5A8146000731AD /* stp_card_jcb_template@3x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "stp_card_jcb_template@3x.png"; sourceTree = "<group>"; };
|
||||
F15AC18D1DBA9CA90009EADE /* FBSnapshotTestCase.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = FBSnapshotTestCase.framework; path = Carthage/Build/iOS/FBSnapshotTestCase.framework; sourceTree = "<group>"; };
|
||||
F1852F911D80B6EC00367C86 /* STPStringUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = STPStringUtils.h; sourceTree = "<group>"; };
|
||||
F1852F921D80B6EC00367C86 /* STPStringUtils.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = STPStringUtils.m; sourceTree = "<group>"; };
|
||||
F1C578F01D651AB200912EAE /* stp_card_applepay.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = stp_card_applepay.png; sourceTree = "<group>"; };
|
||||
|
@ -968,6 +981,7 @@
|
|||
buildActionMask = 2147483647;
|
||||
files = (
|
||||
045E7C091A5F41DE004751EF /* Stripe.framework in Frameworks */,
|
||||
F15AC18E1DBA9CA90009EADE /* FBSnapshotTestCase.framework in Frameworks */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
|
@ -1400,6 +1414,7 @@
|
|||
11C74B9A164043050071C2CA /* Frameworks */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
F15AC18D1DBA9CA90009EADE /* FBSnapshotTestCase.framework */,
|
||||
F1D64B2D1D87686E001CDB7C /* WebKit.framework */,
|
||||
04A58A451BC603BB004E7BC2 /* Fabric */,
|
||||
04365D2C1A4CF86C00A3E1D4 /* CoreGraphics.framework */,
|
||||
|
@ -1666,6 +1681,7 @@
|
|||
045E7C001A5F41DE004751EF /* Frameworks */,
|
||||
045E7C011A5F41DE004751EF /* Resources */,
|
||||
04415C711A6605BD001225ED /* Headers */,
|
||||
F15AC18F1DBA9CC10009EADE /* CopyFiles */,
|
||||
);
|
||||
buildRules = (
|
||||
);
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
buildConfiguration = "Debug"
|
||||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
|
||||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
|
||||
shouldUseLaunchSchemeArgsEnv = "YES">
|
||||
shouldUseLaunchSchemeArgsEnv = "NO">
|
||||
<Testables>
|
||||
<TestableReference
|
||||
skipped = "NO">
|
||||
|
@ -48,6 +48,13 @@
|
|||
ReferencedContainer = "container:Stripe.xcodeproj">
|
||||
</BuildableReference>
|
||||
</MacroExpansion>
|
||||
<EnvironmentVariables>
|
||||
<EnvironmentVariable
|
||||
key = "FB_REFERENCE_IMAGE_DIR"
|
||||
value = "$(SRCROOT)/Tests/ReferenceImages"
|
||||
isEnabled = "YES">
|
||||
</EnvironmentVariable>
|
||||
</EnvironmentVariables>
|
||||
<AdditionalOptions>
|
||||
</AdditionalOptions>
|
||||
</TestAction>
|
||||
|
|
|
@ -40,8 +40,7 @@ CODE_SIGN_IDENTITY = iPhone Developer
|
|||
// delimited by whitespace, so any paths with spaces in them need to be properly quoted.
|
||||
// [-F]
|
||||
|
||||
FRAMEWORK_SEARCH_PATHS = $(inherited)
|
||||
|
||||
FRAMEWORK_SEARCH_PATHS = $(inherited) $(PROJECT_DIR)/Carthage/Build/iOS
|
||||
|
||||
GCC_TREAT_WARNINGS_AS_ERRORS = YES
|
||||
|
||||
|
@ -90,3 +89,7 @@ OTHER_CFLAGS =
|
|||
// This is the basename of the product generated.
|
||||
|
||||
PRODUCT_NAME = $(TARGET_NAME)
|
||||
|
||||
|
||||
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES
|
||||
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
set -euf -o pipefail
|
||||
|
||||
carthage bootstrap --platform ios --configuration Release --no-use-binaries
|
||||
|
||||
gem install xcpretty --no-ri --no-rdoc
|
||||
xcodebuild test -workspace Stripe.xcworkspace -scheme "StripeiOS Tests" -configuration Debug -sdk iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 6,OS=latest' | xcpretty -c
|
||||
xcodebuild build -workspace Stripe.xcworkspace -scheme "Stripe iOS Example (Simple)" -sdk iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 6,OS=latest' | xcpretty -c
|
||||
|
|
Loading…
Reference in New Issue