-
Notifications
You must be signed in to change notification settings - Fork 15
Open
Labels
e2e testsRelated to end-to-end testsRelated to end-to-end testsenhancementNew feature or requestNew feature or request
Milestone
Description
Goal
The goal of the test is to simulate the successful flow of a referendum on a Treasury.spend of some foreign asset:
- submit referendum with
treasury.spendcall - link - place decision deposit - link
- without a decision deposit, the referendum will time out
- modify referendum to simulate the passing of the preparation period - link
- see 5. below for what it means to modify the referendum
- vote on the referendum - link
- re-inject the referendum's data, but with an older submission datum to mimic a referendum that's been confirming for a while (and voting data that passes accordingly). This last part is harder:
- need to build the approval/support curves from the track's data,
- find the necessary approval/support values for the given elapsed confirmation period,
- and change the ref's tally accordingly,
- inject a call to the scheduler, for the next block, for
nudge_referendum
@rockbmb to confirm flow correctness ^
(✅)
Why can't we wait for the passing of a referendum's relevant periods?
Waiting for the confirmation period to elapse in tests is not viable - the smallest of all tracks is 10 minutes (100 blocks), in the Small Tipper and Whitelisted caller tracks.
Similar reasoning applies to the preparation and decision periods.
In other words, even the fastest track will introduce significant overhead in test execution.
The goal of this issue is to track the implementation of this specific flow.
Other flows like cancellation/killing/timing out can be tested independently of this "happy" path.
P.S.
Reference PR: #306
Metadata
Metadata
Assignees
Labels
e2e testsRelated to end-to-end testsRelated to end-to-end testsenhancementNew feature or requestNew feature or request