-
-
Notifications
You must be signed in to change notification settings - Fork 26
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
Add option to specify custom snapshot differ #64
Merged
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
bradleyjkemp
approved these changes
Jun 9, 2020
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.
Thanks @smitt04 this looks great! You're right, difflib won't work very well for large string fields so having this flexibility would be useful 🙂
I've just suggested a small wording change to make it clear that this is purely a UI option and doesn't affect snapshot comparison.
Co-authored-by: Bradley Kemp <bradleyjkemp@users.noreply.github.com>
bradleyjkemp
approved these changes
Sep 14, 2022
yevgenypats
referenced
this pull request
in cloudquery/plugin-sdk
Oct 4, 2022
…#215) This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [github.com/bradleyjkemp/cupaloy/v2](https://togithub.com/bradleyjkemp/cupaloy) | require | minor | `v2.7.0` -> `v2.8.0` | --- ### Release Notes <details> <summary>bradleyjkemp/cupaloy</summary> ### [`v2.8.0`](https://togithub.com/bradleyjkemp/cupaloy/releases/tag/v2.8.0) [Compare Source](https://togithub.com/bradleyjkemp/cupaloy/compare/v2.7.0...v2.8.0) #### What's Changed - Add option to specify custom snapshot differ by [@​smitt04](https://togithub.com/smitt04) in [https://github.com/bradleyjkemp/cupaloy/pull/64](https://togithub.com/bradleyjkemp/cupaloy/pull/64) #### New Contributors - [@​smitt04](https://togithub.com/smitt04) made their first contribution in [https://github.com/bradleyjkemp/cupaloy/pull/64](https://togithub.com/bradleyjkemp/cupaloy/pull/64) **Full Changelog**: bradleyjkemp/cupaloy@v2.7.0...v2.8.0 </details> --- ### Configuration 📅 **Schedule**: Branch creation - "before 3am on the first day of the month" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Renovate Bot](https://togithub.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzMi4xODUuMyIsInVwZGF0ZWRJblZlciI6IjMyLjE4NS4zIn0=--> Co-authored-by: Renovate Bot <renovate@whitesourcesoftware.com>
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.
I have a go struct with a large string member and when diffed it looks pretty ugly and hard to read as the new lines are not interpreted and it thinks the file is a single line.
So I added the ability to add a custom differ as I prefer to use
go-cmp
.