Skip to content

Commit

Permalink
chore: use node for testEnvironment
Browse files Browse the repository at this point in the history
  • Loading branch information
G-Rath committed Feb 15, 2020
1 parent 6de8ac5 commit 281fbee
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
"js",
"jsx"
],
"testEnvironment": "node",
"transform": {
"^.+\\.tsx?$": "ts-jest"
},
Expand Down
6 changes: 4 additions & 2 deletions src/__tests__/volume.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -978,8 +978,10 @@ describe('volume', () => {
vol.writeFileSync('/lol.txt', '1');
setTimeout(() => {
vol.watchFile('/lol.txt', { interval: 1 }, (curr, prev) => {
vol.unwatchFile('/lol.txt');
done();
process.nextTick(() => {
vol.unwatchFile('/lol.txt');
done();
});
});
vol.writeFileSync('/lol.txt', '2');
}, 1);
Expand Down

0 comments on commit 281fbee

Please sign in to comment.