I'm trying to implement Stryker in my NX project on a small part of the code initially. I've managed to configure stryker to run my tests which seems to be happening. It seems like the process is running but i'm getting the below error, which I can't work out. As you can see the tests are running, but there's a random worker message that's blowing up.
16:09:42 (71394) ERROR Stryker Unexpected error occurred while running Stryker ChildProcessCrashedError: Child process [pid 71423] exited unexpectedly with exit code 1 (without signal). Last part of stdout and stderr was:
PASS my-lib libs/my-lib/src/lib/factory/factory.spec.ts
Test Suites: 1 passed, 1 total
Tests: 2 passed, 2 total
Snapshots: 0 total
Time: 3.571 s
Error: Unknown worker message type message
This is caused by either a bug in Node.js or incorrect usage of Node.js internals.
Please open an issue with this stack trace at https://github.com/nodejs/node/issues
at Function.fail (node:internal/assert:20:9)
at Worker.[kOnMessage] (node:internal/worker:354:12)
at MessagePort.<anonymous> (node:internal/worker:232:57)
at _ZoneDelegate.invokeTask (my-project/node_modules/zone.js/bundles/zone.umd.js:449:37)
at ZoneImpl.runTask (my-project/node_modules/zone.js/bundles/zone.umd.js:196:51)
at ZoneTask.invokeTask [as invoke] (my-project/node_modules/zone.js/bundles/zone.umd.js:531:38)
at invokeTask (my-project/node_modules/zone.js/bundles/zone.umd.js:1196:22)
at globalCallback (my-project/node_modules/zone.js/bundles/zone.umd.js:1227:31)
at MessagePort.globalZoneAwareCallback (my-project/node_modules/zone.js/bundles/zone.umd.js:1263:20)
at MessagePort.[nodejs.internal.kHybridDispatch] (node:internal/event_target:820:20)
at MessagePort.<anonymous> (node:internal/per_context/messageport:23:28) {
code: 'ERR_INTERNAL_ASSERTION'
}
at ChildProcess.handleUnexpectedExit (file://my-project/node_modules/@stryker-mutator/core/dist/src/child-proxy/child-process-proxy.js:180:31)
at ChildProcess.emit (node:events:519:28)
at maybeClose (node:internal/child_process:1105:16)
at ChildProcess._handle.onexit (node:internal/child_process:305:5) {
innerError: undefined,
pid: 71423,
exitCode: 1,
signal: null
}
Summary
I'm trying to implement Stryker in my NX project on a small part of the code initially. I've managed to configure stryker to run my tests which seems to be happening. It seems like the process is running but i'm getting the below error, which I can't work out. As you can see the tests are running, but there's a random worker message that's blowing up.
Stryker config
Test runner config
Stryker environment
Test runner environment
Your Environment