mirror of
https://github.com/nodejs/node.git
synced 2026-11-24 21:50:36 -05:00
test: reduce flakiness of test-worker-memory
Signed-off-by: Antoine du Hamel <duhamelantoine1995@gmail.com> PR-URL: https://github.com/nodejs/node/pull/67513 Reviewed-By: Stewart X Addison <sxa@redhat.com> Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Tierney Cyren <hello@bnb.im>
This commit is contained in:
1 parent
c463765478
commit
528ff04af5
1 file changed
+3
-3
@@ -8,11 +8,11 @@ const util = require('util');
|
||||
const { Worker } = require('worker_threads');
|
||||
|
||||
let numWorkers = +process.env.JOBS || require('os').availableParallelism();
|
||||
if (numWorkers > 20) {
|
||||
// Cap the number of workers at 20 (as an even divisor of 60 used as
|
||||
if (numWorkers > 10) {
|
||||
// Cap the number of workers at 10 (as an even divisor of 60 used as
|
||||
// the total number of workers started) otherwise the test fails on
|
||||
// machines with high core counts.
|
||||
numWorkers = 20;
|
||||
numWorkers = 10;
|
||||
}
|
||||
|
||||
// Verify that a Worker's memory isn't kept in memory after the thread finishes.
|
||||
|
||||
Reference in new issue
Block a user