forked from pointfreeco/swift-snapshot-testing
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GUAC 5181 software maintenance #2
Closed
Closed
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
* Updated interface Let's introduce a more streamlined version of `assertSnapshot` that takes an `of` instead of a `matching` parameter: ```diff -assertSnapshot(matching: value, as: .json) +assertSnapshot(of: value, as: .json) ``` While `matching` read OK, it is also a little confusing, since it sounds like the value itself is a snapshot, but the helper is really taking a snapshot _of_ the value to be compared. We'll keep the old version around for a long time as a soft deprecation, but whenever we get close to realizing a 2.0 we can make a harder break. * wip
Co-authored-by: Mahmood Tahir <[email protected]>
* wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * fix * beta 6 * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * wip * fix * wip * wip * wip * wip * wip * wip * wip * wip * wip * small things * wip * DocC + swift-format (pointfreeco#765) * DocC and swift-format support * wip * wip * wip --------- Co-authored-by: Brandon Williams <[email protected]>
* Escape carriage returns explicitly Either Xcode or SwiftSyntax is stripping the carriage return out of the snapshot, but either way we should probably explicitly escape them for visibility. Fixes pointfreeco#771. * simplify * wip
* Update .spi.yml Fix watchOS builds by selecting correct scheme * Update .spi.yml
A MacroTesting bug report encountered an index crash: pointfreeco/swift-macro-testing#6 Even when updating to `index(_:offsetBy:limitedBy:)`, the crash remained, so I've resorted to more explicit limiting math. This seems to fix the crash.
XCTest test cases can be configured with `continueAfterFailure = false`, and in fact UI tests are configured with this by default, but in these cases inline snapshots will never be written because the failure aborts the test before we write to the snapshot state. This commit reorders things to fix the problem.
…ntfreeco#788) Right now we preserve the `()`, which leads to atypical Swift code, like: ```swift assertCustomInline() { """ ... """ } ```
Of course I'd trip over this... 😅 SwiftPackageIndex/SPIManifest#34
Making `assertInlineSnapshot` simply unavailable when another dependency locks to 508.0.1. I think there are too many significant changes in swift-syntax 509 to support the function in earlier versions.
* Add record mode to inline snapshots * wip
pointfreeco#812) * Improve the speed of comparing memory buffers by using a workaround to a missed compiler optimization Co-authored-by: Eric Jensen <[email protected]> * Update NSImage.swift * Update UIImage.swift * fix --------- Co-authored-by: Eric Jensen <[email protected]> Co-authored-by: Stephen Celis <[email protected]>
If recording, don't look for the reference image in the bundle, since this sets the file name for generation later. Instead, look for a local copy of the file (since we won't be recording tests in CI), so that's where the new file gets generated.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Rebase on the newest version of the snapshot library
assertCustomInline()
toassertCustomInline { ... }
(TransformassertCustomInline()
toassertCustomInline { ... }
pointfreeco/swift-snapshot-testing#788)