-
Notifications
You must be signed in to change notification settings - Fork 77
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
chore(core, sequencer): add names to all snapshot tests #1690
Conversation
7c9041a
to
a72de80
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.
The changes make for much cleaner files
...stria-core/src/primitive/v1/snapshots/astria_core__primitive__v1__tests__compat_address.snap
Outdated
Show resolved
Hide resolved
@@ -845,15 +845,15 @@ mod tests { | |||
.prefix(ASTRIA_ADDRESS_PREFIX) | |||
.try_build() | |||
.unwrap(); | |||
insta::assert_json_snapshot!(&main_address.to_raw()); | |||
insta::assert_json_snapshot!("main_address", &main_address.to_raw()); |
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.
Let's never name this main_bech32m_address
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'm assuming you meant to name it main_bech32m_address
?
## Summary Added names to all snapshot tests which did not have them. ## Background If a certain test had multiple snapshot assertions, they would be named based on their ordering. Hence any reordering, removal, or addition of the snapshots would break the test, which should not be the case. This change aims to fix this problem as well as establish a best practice of naming snapshots moving forward. ## Changes - Added names to all snapshot tests and regenerated all snapshots not within Conductor (due to code freeze) ## Testing Passing all tests. ## Related Issues closes #1656
Summary
Added names to all snapshot tests which did not have them.
Background
If a certain test had multiple snapshot assertions, they would be named based on their ordering. Hence any reordering, removal, or addition of the snapshots would break the test, which should not be the case. This change aims to fix this problem as well as establish a best practice of naming snapshots moving forward.
Changes
Testing
Passing all tests.
Related Issues
closes #1656