-
Notifications
You must be signed in to change notification settings - Fork 309
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
Merge in class filtering solution from issue 336 #343
Conversation
The test above failed because the no NG attributes serializer removed the auto-added angular classes as expected. Don't know if that helps the case for the fact that this works. |
|
How do I update the snapshot? I didn't see anything referencing the snapshots in the npm scripts |
Hi, you can do this:
Indeed there is no update snapshot script but you just need to use jest cli option. |
Ah, I didn't realize there was a separate NPM project in the example directory. I've made the changes you requested. |
Sorry this has gotten stale. I'll get around to making the changes this weekend. |
Alright! Changes are made. The regexes are now more targeted at things following those prefixes. |
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.
Awesome! Looks great! Thanks so much!
Can you add an entry to CHANGELOG.md
so we can merge it directly?
@ahnpnl please have another look and we can get this merged.
LGTM, only needs to resolve the conflict and add Probably this also needs to be ivy compatible, but that will be for another PR imo. |
How about also this which creeped in since updating to 8.1.3 with ivy support:
Also, you said ivy compatible can come after but that support is already in master so... required? |
The current snapshot serializer in 8.1.3 is already compatible with ivy. This PR is only an enhancement to get rid of unwanted attributes :) |
Changelog is updated, I'm hoping you intended for me to put it in the 8.1.3 changes! Merge conflict is also resolved. |
No, 8.1.3 is already released. I will fix in on the 8.2 release though. |
Released in v8.2.0. |
Summary
Adds in filtering for contents of attributes as proposed in #336 (thanks for the sample code @ravishivt !)
Fixes #336
Test Plan
Tested by adding into storyshots tests for my company, but additional automated testing would be great. Please advise on what I should do for that. Sample from one of the tests:
Update: the example app snapshot test verifies this functionality.
What's required for testing (prerequisites)?
What are the steps to reproduce (after prerequisites)?
Compatibility
(assuming the other serializer code works, this should too)
Checklist
README.md
CHANGELOG.md
example/App.js
)