Skip to content

Commit

Permalink
test: make node-api/test_buffer/test_finalizer not flaky
Browse files Browse the repository at this point in the history
PR-URL: #43418
Reviewed-By: Benjamin Gruenbaum <[email protected]>
Reviewed-By: Chengzhong Wu <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
  • Loading branch information
mcollina authored and targos committed Jul 12, 2022
1 parent 58646ea commit 3948acc
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion test/node-api/test_buffer/test_finalizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ process.on('uncaughtException', common.mustCall((err) => {
throw new Error('finalizer error');
}));
}
global.gc(true);
await tick(common.platformTimeout(100));
global.gc();
await tick(10);
await tick(common.platformTimeout(100));
global.gc();
await tick(common.platformTimeout(100));
})().then(common.mustCall());

0 comments on commit 3948acc

Please sign in to comment.