({ n, script, mode })
| 60 | } |
| 61 | |
| 62 | function main({ n, script, mode }) { |
| 63 | script = path.resolve(__dirname, '../../', `${script}`); |
| 64 | const warmup = 3; |
| 65 | const state = { n, finished: -warmup }; |
| 66 | if (mode === 'worker') { |
| 67 | Worker = require('worker_threads').Worker; |
| 68 | spawnWorker(script, bench, state); |
| 69 | } else { |
| 70 | spawnProcess(script, bench, state); |
| 71 | } |
| 72 | } |
nothing calls this directly
no test coverage detected
searching dependent graphs…