-
Notifications
You must be signed in to change notification settings - Fork 110
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
Derive Arbitrary impls for a bunch of chain and network types #2179
Conversation
The |
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.
@teor2345 The zebra-chain::primitives module has been a place for cryptographic primitives such as the signature schemes and the proof types, rather than 'utils' or other base types. Sometime like Amount got its own module. Should we have a top-level arbitrary module for things like this?
This PR enables proptests for internal and external network protocol messages.
These particular strategies are serialization-specific and consensus-critical, so I moved them to |
Motivation
We need
Arbitrary
impls to write proptests for internal and external network protocol messages.Solution
Strategy
impls foru32
and full datetimesThe code in this pull request has:
Review
Anyone can review, as long as they understand proptests.
Related Issues
Split off #2160
These tests might have caught security issue #2148
Follow Up Work
Rest of #2160