Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'test/fixtures/workload/grow-worker.js')
-rw-r--r--test/fixtures/workload/grow-worker.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/fixtures/workload/grow-worker.js b/test/fixtures/workload/grow-worker.js
new file mode 100644
index 00000000000..092d8f27751
--- /dev/null
+++ b/test/fixtures/workload/grow-worker.js
@@ -0,0 +1,14 @@
+'use strict';
+
+const { Worker } = require('worker_threads');
+const path = require('path');
+const max_snapshots = parseInt(process.env.TEST_SNAPSHOTS) || 1;
+new Worker(path.join(__dirname, 'grow.js'), {
+ execArgv: [
+ `--heapsnapshot-near-heap-limit=${max_snapshots}`,
+ ],
+ resourceLimits: {
+ maxOldGenerationSizeMb:
+ parseInt(process.env.TEST_OLD_SPACE_SIZE) || 20
+ }
+});