You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm currently running nyc --reporter=lcov --reporter=text-lcov npm test to produce a coverage report. However, on the tests finishing and the creation of the coverage report the following error is given -
/node_modules/nyc/index.js:440
if (parentInfo.children.indexOf(info.uuid) === -1) {
^
TypeError: Cannot read property 'children' of undefined
at infos.forEach.info (/node_modules/nyc/index.js:440:22)
at Array.forEach ()
at NYC.writeProcessIndex (/node_modules/nyc/index.js:437:9)
at /node_modules/nyc/bin/nyc.js:68:9
at ChildProcess. (/node_modules/foreground-child/index.js:52:5)
at emitTwo (events.js:126:13)
at ChildProcess.emit (events.js:214:7)
at maybeClose (internal/child_process.js:915:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
I've tried uninstalling and reinstalling nyc and tried other coverage reports e.g. clover etc but the problem still exists.
Thanks
The text was updated successfully, but these errors were encountered:
This was reported at istanbuljs/nyc#1067. The fix has been merged to nyc but not yet released (will be released in nyc@14.1.0).
Without seeing your repo I can only assume that your npm test also runs nyc. My advice is to avoid recursively running nyc as this is largely untested. Assuming npm test runs tests under nyc I recommend rewriting your above command to npm test && nyc report --reporter=lcov --reporter-text-lcov.
Hi
I'm currently running
nyc --reporter=lcov --reporter=text-lcov npm test
to produce a coverage report. However, on the tests finishing and the creation of the coverage report the following error is given -/node_modules/nyc/index.js:440
if (parentInfo.children.indexOf(info.uuid) === -1) {
^
TypeError: Cannot read property 'children' of undefined
at infos.forEach.info (/node_modules/nyc/index.js:440:22)
at Array.forEach ()
at NYC.writeProcessIndex (/node_modules/nyc/index.js:437:9)
at /node_modules/nyc/bin/nyc.js:68:9
at ChildProcess. (/node_modules/foreground-child/index.js:52:5)
at emitTwo (events.js:126:13)
at ChildProcess.emit (events.js:214:7)
at maybeClose (internal/child_process.js:915:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
I've tried uninstalling and reinstalling nyc and tried other coverage reports e.g. clover etc but the problem still exists.
Thanks
The text was updated successfully, but these errors were encountered: