Fix strategy handling in pool options (#259)
[poolifier.git] / benchmarks / internal / cluster / fixed.js
index ea61c7fcb398a40326a19f0935b7f13268050cde..fc4cc3ac8dc545ba4b8d530401b19ac396f1f02c 100644 (file)
@@ -5,6 +5,7 @@ const {
 const { runPoolifierTest } = require('../benchmark-utils')
 
 const size = 30
+const numberOfTasks = 1
 
 const fixedPool = new FixedClusterPool(
   size,
@@ -18,13 +19,13 @@ const fixedPoolLessRecentlyUsed = new FixedClusterPool(
 )
 
 async function fixedClusterTest (
-  { tasks, workerData } = { tasks: 1, workerData: { proof: 'ok' } }
+  { tasks, workerData } = { tasks: numberOfTasks, workerData: { proof: 'ok' } }
 ) {
   return runPoolifierTest(fixedPool, { tasks, workerData })
 }
 
 async function fixedClusterTestLessRecentlyUsed (
-  { tasks, workerData } = { tasks: 1, workerData: { proof: 'ok' } }
+  { tasks, workerData } = { tasks: numberOfTasks, workerData: { proof: 'ok' } }
 ) {
   return runPoolifierTest(fixedPoolLessRecentlyUsed, { tasks, workerData })
 }