X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=tests%2Fworker-files%2Fcluster%2FlongRunningWorkerHardBehavior.js;h=a95d6538b49f3647c5376c8f4459db799ac92c6c;hb=7b7d96315331635fa3c8a12b03b6893fe91bf8ec;hp=73fdad01706c896c943b0291cb6da16bd8282ad5;hpb=bdacc2d25f190728221f7fb8c8cd2aba175cb18d;p=poolifier.git diff --git a/tests/worker-files/cluster/longRunningWorkerHardBehavior.js b/tests/worker-files/cluster/longRunningWorkerHardBehavior.js index 73fdad01..a95d6538 100644 --- a/tests/worker-files/cluster/longRunningWorkerHardBehavior.js +++ b/tests/worker-files/cluster/longRunningWorkerHardBehavior.js @@ -1,13 +1,12 @@ 'use strict' -const { ClusterWorker, KillBehaviors } = require('../../../lib/index') -const TestUtils = require('../../test-utils') +const { ClusterWorker, KillBehaviors } = require('../../../lib') +const { sleepTaskFunction } = require('../../test-utils.js') async function sleep (data) { - return TestUtils.workerSleepFunction(data, 50000) + return sleepTaskFunction(data, 50000) } module.exports = new ClusterWorker(sleep, { - maxInactiveTime: 500, - async: true, - killBehavior: KillBehaviors.HARD + killBehavior: KillBehaviors.HARD, + maxInactiveTime: 500 })