-
Notifications
You must be signed in to change notification settings - Fork 997
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
Add transition test case of non-empty pre-state historical_roots
#3585
Conversation
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. a quick comment on the usage of a var for the list length
Therefore, we need to fill in `historical_roots` with non-empty value. | ||
""" | ||
# fill in historical_roots with non-empty values | ||
pre_historical_roots = [b'\x56' * 32 for _ in range(spec.SLOTS_PER_HISTORICAL_ROOT)] |
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.
SLOTS_PER_HISTORICAL_ROOT
is fine here but it's a bit misleading in it's relationship to historical_roots
which is a list of unbound length
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 test would do its job with > 0 items so why no set it to 1?
tests/core/pyspec/eth2spec/test/altair/transition/test_transition.py
Outdated
Show resolved
Hide resolved
Therefore, we need to fill in `historical_roots` with non-empty value. | ||
""" | ||
# fill in historical_roots with non-empty values | ||
pre_historical_roots = [b'\x56' * 32 for _ in range(spec.SLOTS_PER_HISTORICAL_ROOT)] |
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 test would do its job with > 0 items so why no set it to 1?
tests/core/pyspec/eth2spec/test/altair/transition/test_transition.py
Outdated
Show resolved
Hide resolved
Co-authored-by: Lion - dapplion <[email protected]>
Issue
To cover prysmaticlabs/prysm#13477 with this test case.
Description
historical_roots