2 static async
waitExits (pool
, numberOfExitEventsToWait
) {
4 return new Promise(function (resolve
, reject
) {
5 pool
.workers
.forEach(w
=> {
8 if (exitEvents
=== numberOfExitEventsToWait
) {
16 static async
sleep (ms
) {
17 return new Promise(resolve
=> setTimeout(resolve
, ms
))
21 module
.exports
= TestUtils