Skip to content

Commit

Permalink
test: Fix pending tests for virtual machine inside Travis.
Browse files Browse the repository at this point in the history
  • Loading branch information
JSMonk committed Apr 26, 2019
1 parent 3b99387 commit e073e42
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,19 +172,17 @@ const runTests = function(baseopts) {

await waitForWatcher(watcher);

(async () => {
for (let path of paths.slice(0, 5)) {
await write(path, Date.now());
}
await delay(100);
for (let path of paths.slice(5)) {
await write(path, Date.now());
}
delay();
})();
for (let path of paths.slice(0, 5)) {
await write(path, Date.now());
}
await delay(100);
for (let path of paths.slice(5)) {
await write(path, Date.now());
}

await waitFor([[spy, 4]]);
await waitFor([[spy, 9]]);
await delay(1000);
paths.forEach(path => {
spy.should.have.been.calledWith(path);
});
Expand Down Expand Up @@ -281,6 +279,7 @@ const runTests = function(baseopts) {
await waitFor([[spy, 11]]);
await waitFor([[spy, 22]]);
await waitFor([[spy, 33]]);
await delay(1000);

spy.should.have.been.calledWith(test1Path);
spy.should.have.been.calledWith(test2Path);
Expand Down

0 comments on commit e073e42

Please sign in to comment.