Skip to content

Commit

Permalink
test: fix flaky test-watch-mode-files_watcher
Browse files Browse the repository at this point in the history
PR-URL: #46738
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Debadree Chatterjee <debadree333@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com>
  • Loading branch information
MoLow committed Feb 21, 2023
1 parent 3fd4343 commit 254574e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions test/parallel/test-watch-mode-files_watcher.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ describe('watch mode file watcher', () => {
watcher.watchPath(tmpdir.path);

const changed = once(watcher, 'changed');
await setTimeout(common.platformTimeout(100)); // avoid throttling
writeFileSync(file, 'changed');
await changed;
assert.strictEqual(changesCount, 1);
Expand Down

0 comments on commit 254574e

Please sign in to comment.