repositories
/
poolifier.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Bump typedoc from 0.20.30 to 0.20.31 (#272)
[poolifier.git]
/
tests
/
worker-files
/
thread
/
asyncWorker.js
diff --git
a/tests/worker-files/thread/asyncWorker.js
b/tests/worker-files/thread/asyncWorker.js
index 25401cfb14dea2ff9fed837f138f349218ff7b34..0bf5d244758ce100683ea9c23faf114bd03428c8 100644
(file)
--- a/
tests/worker-files/thread/asyncWorker.js
+++ b/
tests/worker-files/thread/asyncWorker.js
@@
-1,5
+1,5
@@
'use strict'
'use strict'
-const { ThreadWorker } = require('../../../lib/index')
+const { ThreadWorker
, KillBehaviors
} = require('../../../lib/index')
async function sleep (data) {
return new Promise((resolve, reject) => {
async function sleep (data) {
return new Promise((resolve, reject) => {
@@
-7,4
+7,8
@@
async function sleep (data) {
})
}
})
}
-module.exports = new ThreadWorker(sleep, { maxInactiveTime: 500, async: true })
+module.exports = new ThreadWorker(sleep, {
+ maxInactiveTime: 500,
+ async: true,
+ killBehavior: KillBehaviors.HARD
+})