-
Notifications
You must be signed in to change notification settings - Fork 107
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
tests(rpc): Add fixed test vectors for z_getsubtreesbyindex
from zcashd to zebra
#7515
Conversation
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
I added the tests mentioned here to this PR. All the responses for the test vectors added by now are the same as zcashd:
|
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
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.
Looks good!
There's a few tricky things about how the test is run, and when we run it. I think I've fixed them in PR #7566, but we'll need to do something similar here.
Locally this test hanged with the latest changes but i want to check in the CI. |
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.
Looks like that worked!
…ashd to zebra (#7515) * add fixed test vectors for `z_getsubtreesbyindex` * change to snapshots * add test to docker * remove assert lines from snapshots * add more tests * change test description * change test name * run both tests together * wait for state version update in test * Run one test at a time to avoid state locking issues --------- Co-authored-by: teor <[email protected]>
Depends-On: #7555
Motivation
We want to test the
z_getsubtreesbyindex
against fixed test vectors obtained from zcashd and see if they match zebra.Close #7446
Solution
The idea is to add json outputs from
zcashd
into thezebra-test
crate and then create a test that could compare this fixed outputs with answers from zebrad made in real time.In order to test this in high heights we need a pretty much synchronized cache state for zebra.
Locally, i run this test as:
Review
This is not ready yet because i don't have the right outputs from zcashd. In order to use the
getsubtreesbyindex
i had to reindex and that actually ended up downloading all the blocks again so i have a couple of days at least to be in sync again with zcashd.But i pushed so other people can take a look to the overall structure and let me know if this is a good or bad idea. Thanks!
Reviewer Checklist
Follow Up Work