Skip to content
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

Better testing mocks and environment for private test networks #55

Open
lsaether opened this issue Oct 15, 2018 · 0 comments
Open

Better testing mocks and environment for private test networks #55

lsaether opened this issue Oct 15, 2018 · 0 comments

Comments

@lsaether
Copy link
Member

The ability to correctly test contracts is super important for avoiding expensive fiascoes. However, there is no easy way to mock / test the scheduling functionality of the Ethereum Alarm Clock on a private test network besides actually deploying the contracts first. Even then, the private network requires a TimeNode to be present to actually execute the transaction. For a better developer experience we need a way to mock the deploy of the EAC on private test networks and execute the transactions in a lightweight way.

One thing we can do is create a dumb Scheduler which will basically only be a TransactionRequest with a timelock, then have a lightweight TimeNode in a helper function exposed by this library. Something like mockSchedule(params) which will handle all the complicated stuff under the scenes. Or even a simple mockTimeNode() which will wrap over the execution. Add't we can add an easy deployEAC() function which can be ran early in a Truffle mocha test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant