create snapthot of staking module into pse after upgrade#20
Conversation
ysv
left a comment
There was a problem hiding this comment.
@ysv reviewed 3 of 3 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @masihyeganeh and @TxCorpi0x)
app/upgrade/v6/pse_staking_snapshot_test.go line 25 at r1 (raw file):
err := v6.SnapshotPSEStaking(ctx, stakingkeeper.NewQuerier(stakingKeeper), pseKeeper, addressCodec, valAddressCodec) requireT.NoError(err) // This is not an interesting test case, the real scenario can only be tested in integration tests.
but then this test doesn't seem to verify anything tangible, does it ?
Maybe we can create delegation in sim app before running SnapshotPSEStaking and verify that Score > 0 after.
Otherwise do we even need this test ?
ysv
left a comment
There was a problem hiding this comment.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @masihyeganeh, @miladz68, and @TxCorpi0x)
app/upgrade/v6/pse_staking_snapshot.go line 14 at r1 (raw file):
) func SnapshotPSEStaking(
I guess the call of this function will be added in a next PR, right ?
miladz68
left a comment
There was a problem hiding this comment.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @masihyeganeh, @TxCorpi0x, and @ysv)
app/upgrade/v6/pse_staking_snapshot_test.go line 25 at r1 (raw file):
Previously, ysv (Yaroslav Savchuk) wrote…
but then this test doesn't seem to verify anything tangible, does it ?
Maybe we can create delegation in sim app before runningSnapshotPSEStakingand verify that Score > 0 after.
Otherwise do we even need this test ?
the test verifies that no error happened when taking the snapshot. it is ok to keep it IMO.
miladz68
left a comment
There was a problem hiding this comment.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @masihyeganeh, @TxCorpi0x, and @ysv)
app/upgrade/v6/pse_staking_snapshot.go line 14 at r1 (raw file):
Previously, ysv (Yaroslav Savchuk) wrote…
I guess the call of this function will be added in a next PR, right ?
in this PR actually, it is a placeholder, it lacks proper tests.
ysv
left a comment
There was a problem hiding this comment.
Reviewable status:
complete! all files reviewed, all discussions resolved (waiting on @masihyeganeh and @TxCorpi0x)
ysv
left a comment
There was a problem hiding this comment.
@ysv reviewed 6 of 6 files at r2, all commit messages.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @masihyeganeh and @TxCorpi0x)
TxCorpi0x
left a comment
There was a problem hiding this comment.
@TxCorpi0x reviewed 3 of 3 files at r1, 6 of 6 files at r2, all commit messages.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @masihyeganeh)
Description
Reviewers checklist:
Authors checklist
This change is