This repository has been archived by the owner on Jan 13, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 252
Replace big macro with Objective-C method for easier debugging. #180
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
oh nice, that's a good addition. I'll review it in detail this week. |
nscoding
suggested changes
Sep 15, 2016
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple comments but this looks great.
- (NSString *)snapshotVerifyViewOrLayer:(id)viewOrLayer | ||
identifier:(NSString *)identifier | ||
suffixes:(NSOrderedSet *)suffixes | ||
tolerance:(CGFloat)tolerance |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indent all parameters
suffixes:(NSOrderedSet *)suffixes | ||
tolerance:(CGFloat)tolerance | ||
{ | ||
NSString *referenceImageDirectory = [self getReferenceImageDirectoryWithDefault:(@ FB_REFERENCE_IMAGE_DIR)]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can add an assert that viewOrLayer is not nil
This would be great to see merged, especially since we could get rid of the Swift file and use the Objective-C public API instead or am I missing something? |
nscoding
approved these changes
Sep 22, 2016
Merged
thorthugnasty
pushed a commit
to thorthugnasty/ios-snapshot-test-case
that referenced
this pull request
Jan 26, 2017
…t-case into andrewli/add-color-tolerance * 'master' of https://github.com/facebook/ios-snapshot-test-case: Fix documentation warnings (facebookarchive#205) Add Reference to IMAGE_DIFF_DIR (facebookarchive#201) Update pod version and change log (facebookarchive#199) Bump version to 2.1.4 (facebookarchive#198) Replace big macro with Objective-C method for easier debugging. (facebookarchive#180) Merge Swift 3 in master (facebookarchive#194) Fix pod verification (facebookarchive#193) Bump version to 2.3 (facebookarchive#192) Revert "Merge Swift 3 into master" (facebookarchive#191) Merge Swift 3 into master (facebookarchive#189)
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When something goes wrong, C macros are hard to debug. So I replaced the main macro with an Objective-C method.
The XCT asserts are still in the macro. So if they fail, Xcode will highlight them in the actual test class, not in FBSnapshotTestCase.