-
Notifications
You must be signed in to change notification settings - Fork 79
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
Add more integration tests #952
Conversation
25289d5
to
50ad421
Compare
50ad421
to
edbe5c1
Compare
No snapshot
edbe5c1
to
9e3bb5b
Compare
Codecov Report
@@ Coverage Diff @@
## develop #952 +/- ##
===========================================
+ Coverage 15.25% 19.89% +4.63%
===========================================
Files 104 104
Lines 2523 2523
===========================================
+ Hits 385 502 +117
+ Misses 2138 2021 -117
Continue to review full report at Codecov.
|
1a459f5
to
61690dd
Compare
Install IPFS in Travis environment f Add sudo to IPFS installation Fix IPFS installation command Add util init IPFS after install Test also isIPFSRunning
61690dd
to
dad6398
Compare
@dapplion The |
I'll do the |
I can take it, which will ease testing it for me |
Looks like the problem in our - new Web3.providers.HttpProvider(`http://localhost:8545`)
+ new Web3.providers.WebsocketProvider(`ws://localhost:8545`) Because it was connecting using an http provider, the |
The issue seems to be that the devchain remains started and lerna is waiting for it to exit, which never happens. It seems to be that this is the "correct" npm behavior. I found a solution in d76491a inspired by this SO answer which forces the postscript to run even if the tests have failed and return the correct exit code to make the CI fail as it should. Update: I had to update the script once more in af2d676 because without the parenthesis |
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.
LGTM!
I've skipped some ipfs tests and moved the concerns you shared in #951 so that we can merge this.
Regarding the snapshots problem I'm not sure how to replicate it, my guess is that lerna hanging or some other issue was causing it now to show.
I've tested in 8ebe5b8 and it seems to work: https://travis-ci.org/aragon/aragon-cli/jobs/617278237#L841
Awesome, thanks for catching the issue |
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.
Awesome work on test coverage increase @dapplion and @0x6431346e ! 💯
@0x6431346e will experiment in a second iteration on how to improve IPFS-related integration tests.
Add tests to increase the code coverage of the
/lib
directory.As of 9e3bb5b it increases the coverage of
/lib
by +32.68% to 73.64%.Issues on tested code:
Tests never finish on error ✔️
travis
-npm
-ava
-nyc
or someone in the chain seems to swallow the error when it fails, forcing the test to take extra 10 minutes for the Travis timeout to kick in.I hadn't the time to investigate the cause yet.
Issues to-be-tested code (or preventing it from being tested):
No snapshot diffs ⌛
AVA does not show a diff of snapshot from Travis CI. See example https://travis-ci.org/aragon/aragon-cli/jobs/616072516#L486
acl view ✔️
This test always fails since ava thinks that the promise wrapping AragonJS never resolves, and fails with:
Trying different async constructions didn't solve the issue. Therefore the test is skipped until there's more time to find a solution
start ⌛
According to #858 the
start
commands are not yet refactored. However there's code in/lib
but the code if highly coupled with the front-end callingtask.skip()
and mutating thetask.ctx
@0xGabi, is this refactored? Is this a WIP?