refactor: split TestUtils class into arrow functions
[poolifier.git] / tests / worker-files / cluster / asyncWorker.js
... / ...
CommitLineData
1'use strict'
2const { ClusterWorker, KillBehaviors } = require('../../../lib')
3const { sleepWorkerFunction } = require('../../test-utils')
4
5async function sleep (data) {
6 return sleepWorkerFunction(data, 2000)
7}
8
9module.exports = new ClusterWorker(sleep, {
10 maxInactiveTime: 500,
11 killBehavior: KillBehaviors.HARD
12})