-
Notifications
You must be signed in to change notification settings - Fork 603
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
Migrating to buidler #492
Migrating to buidler #492
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #492 +/- ##
========================================
Coverage 92.04% 92.04%
========================================
Files 39 39
Lines 1985 1985
Branches 271 271
========================================
Hits 1827 1827
Misses 158 158 Continue to review full report at Codecov.
|
@cgewecke running (run |
This reverts commit 7ef10a2.
@@ -140,11 +149,14 @@ contract('Exchanger (via Synthetix)', async accounts => { | |||
describe('and 88 seconds elapses', () => { | |||
// Note: timestamp accurancy can't be guaranteed, so provide a few seconds of buffer either way | |||
beforeEach(async () => { | |||
fastForward(88); | |||
await fastForward(87); |
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.
was this supposed to be 87 or 88 as described?
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.
I was tinkering with it due to timing issues in the setup and forgot to put this back. Doing it now. 👍
@@ -281,11 +277,11 @@ contract('RewardEscrow', async accounts => { | |||
await assert.revert( | |||
rewardEscrow.appendVestingEntry(account1, toUnit('1'), { from: feePoolAccount }) | |||
); | |||
}); | |||
}).timeout(60e3); |
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.
What affect will this have? will it fail the test if it times out or about this test?
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.
This allows individual tests to extend the default mocha timeout (which I believe is 20 secs): https://mochajs.org/#timeouts
I use the it().timeout()
functionality as this.timeout(...)
does not work with fat arrow functions due to the fact that they update this
with the global context in the top-level contract
or describe
block.
// get rawLogs as logs not decoded because the truffle cannot decode the events from the | ||
// underlying from the proxy invocation | ||
const { topics } = txn.receipt.rawLogs[0]; | ||
assert.equal(topics[1], web3.eth.abi.encodeParameter('address', account3)); |
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.
good check here that messageSender set as from acc
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.
😊
Additional improvements:
|
testnet:local
andtest:publish
to use buidler-evmtest-contracts runs in under 6m, down from nearly an hour! 🙇