-
Notifications
You must be signed in to change notification settings - Fork 126
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
test: reduce number of happyPath steps #1179
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,13 +22,10 @@ var happyPathSteps = concatSteps( | |
stepsRedelegateForOptOut("consu"), | ||
stepsDowntimeWithOptOut("consu"), | ||
stepsRedelegate("consu"), | ||
stepsDowntime("consu"), | ||
stepsRejectEquivocationProposal("consu", 2), // prop to tombstone bob is rejected | ||
stepsDoubleSignOnProviderAndConsumer("consu"), // carol double signs on provider, bob double signs on consumer | ||
stepsSubmitEquivocationProposal("consu", 2), // now prop to tombstone bob is submitted and accepted | ||
stepsStartRelayer(), | ||
stepsConsumerRemovalPropNotPassing("consu", 3), // submit removal prop but vote no on it - chain should stay | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Checked in There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. When is the short happy path executed? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's a misnomer. |
||
stepsStopChain("consu", 4), // stop chain | ||
stepsStopChain("consu", 3), // stop chain | ||
) | ||
|
||
var shortHappyPathSteps = concatSteps( | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,7 +21,7 @@ func stepsRejectEquivocationProposal(consumerName string, propNumber uint) []Ste | |
ValPowers: &map[validatorID]uint{ | ||
validatorID("alice"): 509, | ||
validatorID("bob"): 500, | ||
validatorID("carol"): 495, | ||
validatorID("carol"): 501, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why were the voting powers changed here? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Some steps that changed the voting power were removed. Steps are executed sequentially, so if you remove one of them you have to account for the removal in other places. |
||
}, | ||
ValBalances: &map[validatorID]uint{ | ||
validatorID("bob"): 9500000000, | ||
|
@@ -35,7 +35,7 @@ func stepsRejectEquivocationProposal(consumerName string, propNumber uint) []Ste | |
ValPowers: &map[validatorID]uint{ | ||
validatorID("alice"): 509, | ||
validatorID("bob"): 500, | ||
validatorID("carol"): 495, | ||
validatorID("carol"): 501, | ||
}, | ||
}, | ||
}, | ||
|
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.
No need to test for downtime twice, testing for downtime with soft opt-out also covers "normal" downtime.
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.
Although both use the
downtimeSlashAction
action, instepsDowntimeWithOptOut
there doesn't seem that slashing takes place sincealice
has < 5% of the total voting power. While instepsDowntime
,bob
is indeed slashed.Additionally
stepsDowntime
is also performing anunjailValidatorAction
.Therefore, wouldn't we weaken the
happyPathSteps
by removing thestepsDowntime
?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.
It will, but there's an additional issue that proposes changes to how this runs in the CI:
We can have multiple jobs running in parallel and make the execution time shorter