-
Notifications
You must be signed in to change notification settings - Fork 37
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
feat(amber): change serialization to be py syntax like #505
Conversation
3c560c3
to
4c19cee
Compare
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.
I agree this looks nicer. I do think we should keep the initial indent though.
tests/syrupy/extensions/amber/__snapshots__/test_amber_filters.ambr
Outdated
Show resolved
Hide resolved
7417e1b
to
1d9665a
Compare
aa46082
to
0a12e70
Compare
3de6031
to
cb9819c
Compare
cb9819c
to
8f34d16
Compare
Codecov Report
@@ Coverage Diff @@
## next #505 +/- ##
=======================================
Coverage 99.91% 99.91%
=======================================
Files 19 19
Lines 1130 1132 +2
=======================================
+ Hits 1129 1131 +2
Misses 1 1 |
8f34d16
to
6652cc4
Compare
BREAKING CHANGE: update to serialization requires regeneration of snapshots Migration Guide * `pytest --snapshot-update` to regenerate amber snapshots
6652cc4
to
e39a738
Compare
open_paren, close_paren = next( | ||
parens | ||
for iter_type, parens in { | ||
GeneratorType: ("(", ")"), | ||
list: ("[", "]"), | ||
tuple: ("(", ")"), | ||
}.items() | ||
if isinstance(data, iter_type) | ||
) |
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.
What's the reason for dropping round brackets for the tuples?
BREAKING CHANGE: update to serialization requires regeneration of snapshots Migration Guide * `pytest --snapshot-update` to regenerate amber snapshots
# [2.0.0](v1.7.4...v2.0.0) (2022-04-10) ### Features * **amber:** change serialization to be py syntax like ([#505](#505)) ([b64b965](b64b965)) * release syrupy v2 ([#575](#575)) ([bc8b3a9](bc8b3a9)) ### BREAKING CHANGES * **amber:** update to serialization requires regeneration of snapshots Migration Guide * `pytest --snapshot-update` to regenerate amber snapshots
…ts (#535) * chore(deps): bump syrupy from 1.5.0 to 3.0.2 in /pipelines/requirements Bumps [syrupy](https://github.com/tophat/syrupy) from 1.5.0 to 3.0.2. - [Release notes](https://github.com/tophat/syrupy/releases) - [Changelog](https://github.com/tophat/syrupy/blob/master/CHANGELOG.md) - [Commits](syrupy-project/syrupy@v1.5.0...v3.0.2) --- updated-dependencies: - dependency-name: syrupy dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> * Update snapshots per syrupy breaking change syrupy-project/syrupy#505 Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Robert Craigie <robert@craigie.dev>
Description
Example
https://github.com/tophat/syrupy/blob/aa46082894e3bb646d789a6f9c09c059d80dcd18/tests/syrupy/extensions/amber/__snapshots__/test_amber_serializer.ambr#L49-L83
Related Issues
Checklist
Additional Comments
BREAKING CHANGE: update to serialization requires regeneration of snapshots
Migration Guide
pytest --snapshot-update
to regenerate amber snapshots