Last active
November 5, 2018 01:37
-
-
Save atvanguard/205813570838a7e4a6eac53f13e8d4e5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// delegations | |
await instance.delegateTo(accounts[2], {from: accounts[3]}) | |
await instance.delegateTo(accounts[5], {from: accounts[6]}) | |
await instance.delegateTo(accounts[7], {from: accounts[8]}) | |
// V7 delegates to V5 creating a super proxy | |
await instance.delegateTo(accounts[5], {from: accounts[7]}) | |
// V5 delegates their combined voting power to V4 | |
await instance.delegateTo(accounts[4], {from: accounts[5]}) | |
// Voting begins | |
await instance.vote(0, {from: accounts[1]}) // Yes | |
await instance.vote(1, {from: accounts[2]}) // No | |
await instance.vote(2, {from: accounts[4]}) // Maybe | |
await instance.vote(2, {from: accounts[9]}) | |
// Voter 8 changes their delegation | |
await instance.delegateTo(accounts[2], {from: accounts[8]}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment