-
Notifications
You must be signed in to change notification settings - Fork 42
test: add attest after upgrade test #71
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
Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #71 +/- ##
=======================================
Coverage 95.81% 95.81%
=======================================
Files 42 42
Lines 10194 10194
=======================================
Hits 9767 9767
Misses 427 427 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
6f96aaf to
6638029
Compare
6638029 to
d58cf94
Compare
d58cf94 to
aca4787
Compare
0e7d1c5 to
6c46b05
Compare
noa-starkware
left a comment
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.
Reviewable status: 0 of 2 files reviewed, 2 unresolved discussions (waiting on @arad-starkware)
src/flow_test/flows.cairo line 7136 at r2 (raw file):
); let result = attestation_safe.attest(block_hash: Zero::zero()); assert_panic_with_error(:result, expected_error: "Index out of bounds");
Doc why we expect to fail with this error.
aca4787 to
25bdeb4
Compare
6c46b05 to
ec67025
Compare
25bdeb4 to
1505bf7
Compare
ec67025 to
d6355ec
Compare
arad-starkware
left a comment
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.
Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @noa-starkware)
src/flow_test/flows.cairo line 7136 at r2 (raw file):
Previously, noa-starkware wrote…
Doc why we expect to fail with this error.
Done.
d6355ec to
b70aa82
Compare
1505bf7 to
af22f54
Compare
noa-starkware
left a comment
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.
Reviewable status: 0 of 2 files reviewed, 2 unresolved discussions (waiting on @arad-starkware)
src/flow_test/flows.cairo line 7136 at r2 (raw file):
Previously, arad-starkware wrote…
Done.
fixed in V3 sounds like staker can attest, but we only fixed the error msg.
src/flow_test/flows.cairo line 7136 at r4 (raw file):
); let result = attestation_safe.attest(block_hash: Zero::zero()); // Fails because the staker trace has no entry for the previous epoch (fixed in V3).
Suggestion:
// Fails because a staker can’t attest in their starting epoch (zero balance).
// If the staker started in V2, the trace has no entry for that epoch, so it reverts with an "index out of bounds" error (this case).
// If the staker started in V3, the trace includes that entry, so it reverts with ATTEST_WITH_ZERO_BALANCE.b70aa82 to
ed9fb2d
Compare
af22f54 to
94bf90d
Compare
ed9fb2d to
878cc79
Compare
94bf90d to
3958f47
Compare
bdca6a8 to
2edc4c4
Compare
77a3d40 to
9d0e8f3
Compare
9d0e8f3 to
641afe8
Compare
a123f39 to
6fa473d
Compare
13fa384 to
ee36d3b
Compare
6fa473d to
9734280
Compare
ee36d3b to
18cc23d
Compare
0b9ed88 to
8a44fec
Compare
18cc23d to
d33b3ea
Compare
8a44fec to
f7f21fa
Compare
d33b3ea to
7678b32
Compare
1a95f7b to
e5c165d
Compare
7678b32 to
81dde17
Compare
e5c165d to
b42160b
Compare
81dde17 to
b364631
Compare
b364631 to
0becc70
Compare
Merge activity
|

This change is
Note
Adds a flow testing attestation behavior immediately after upgrade (fail then succeed post-epoch) and wires it into mainnet-fork tests.
AttestAfterUpgradeFlowinsrc/flow_test/flows.cairoto validate attestation immediately after upgrade:IAttestationSafeDispatcherTraitfails (no previous-epoch trace), then after advancing an epoch attestation succeeds and rewards equalcalculate_staker_strk_rewards_v2.attest_after_upgrade_flow_testinsrc/flow_test/fork_test.cairo.Written by Cursor Bugbot for commit 0becc70. This will update automatically on new commits. Configure here.