diff --git a/test/node-api/test_buffer/test_finalizer.js b/test/node-api/test_buffer/test_finalizer.js index 372116bb3a0..b706c68c7c3 100644 --- a/test/node-api/test_buffer/test_finalizer.js +++ b/test/node-api/test_buffer/test_finalizer.js @@ -16,7 +16,7 @@ process.on('uncaughtException', common.mustCall((err) => { throw new Error('finalizer error'); })); } - global.gc(true); + global.gc({ type: 'minor' }); await tick(common.platformTimeout(100)); global.gc(); await tick(common.platformTimeout(100)); diff --git a/test/parallel/test-net-write-fully-async-buffer.js b/test/parallel/test-net-write-fully-async-buffer.js index 207ae24f6a3..0dddb51bd76 100644 --- a/test/parallel/test-net-write-fully-async-buffer.js +++ b/test/parallel/test-net-write-fully-async-buffer.js @@ -23,7 +23,7 @@ const server = net.createServer(common.mustCall(function(conn) { } while (conn.write(Buffer.from(data))); - global.gc(true); + global.gc({ type: 'minor' }); // The buffer allocated above should still be alive. } diff --git a/test/parallel/test-net-write-fully-async-hex-string.js b/test/parallel/test-net-write-fully-async-hex-string.js index f3115d8d2f7..37b5cd75c13 100644 --- a/test/parallel/test-net-write-fully-async-hex-string.js +++ b/test/parallel/test-net-write-fully-async-hex-string.js @@ -21,7 +21,7 @@ const server = net.createServer(common.mustCall(function(conn) { } while (conn.write(data, 'hex')); - global.gc(true); + global.gc({ type: 'minor' }); // The buffer allocated inside the .write() call should still be alive. }