Open cgalvarez opened 8 years ago
My bad, it should be fixed with that commit on spacejam. Can you retest please ?
The file summary.txt
is now generated, but the text coverage error: Failed to save text report
is printed to the console (not as an error, but as normal output text).
phantomjs exit with code 7 (following is the output of my npm run test
command):
Tests are ok! Meteor-coverage is saving client side coverage to the server. Client js files saved {"SUCCESS":47,"FAILED":0,"TOTAL":47}
coverage error: Failed to save text report
spacejam: phantomjs exited with code: 7
spacejam: killing meteor
spacejam: meteor killed with signal: SIGTERM
spacejam: Unknown error with exit code '7'. Exiting.
npm ERR! Linux 4.7.0-040700-generic
npm ERR! argv "/home/user/.nvm/versions/node/v6.3.1/bin/node" "/home/user/.nvm/versions/node/v6.3.1/bin/npm" "run" "test"
npm ERR! node v6.3.1
npm ERR! npm v3.10.3
npm ERR! code ELIFECYCLE
npm ERR! meteor-my-package@0.1.0 test: `rm -rf coverage; mkdir -p coverage; spacejam-mocha --coverage "out_text_summary" ./`
npm ERR! Exit status 7
npm ERR!
npm ERR! Failed at the meteor-cdn-loader@0.1.0 test script 'rm -rf coverage; mkdir -p coverage; spacejam-mocha --coverage "out_text_summary" ./'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the meteor-my-package package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! rm -rf coverage; mkdir -p coverage; spacejam-mocha --coverage "out_text_summary" ./
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs meteor-my-package
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls meteor-my-package
npm ERR! There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! Please include the following file with any support request:
npm ERR! /home/user/meteor-app/packages/my-package/npm-debug.log
The content of summary.txt
is:
=============================== Coverage summary ===============================
Statements : 13.3% ( 31/233 )
Branches : 0.76% ( 1/131 )
Functions : 5.56% ( 2/36 )
Lines : 13.9% ( 31/223 )
================================================================================
I think that the file is successfully created (you will have to confirm me that's the expected content) but somewhere istanbul throws an error.
Yeap, this is the expected behavior, you can compare with the global coverage on the root HTML report. It's quite strange because there is an end to end test to check that export. https://github.com/serut/meteor-coverage/blob/master/client/methods.e2e.tests.js#L101-L116
I've retested a couple times more, and always get like above:
coverage error: Failed to save text report
spacejam: Unknown error with exit code '7'. Exiting.
Expected Behavior
The report
out_text_summary
should output something.Current Behavior
The report
out_text_summary
does not output any report file and always outputs the messagecoverage error: Failed to save cobertura report
(without exception trace).Possible Solution
No idea.
Steps to Reproduce (for bugs)
Executed any of the following commands:
Context
I was trying to test the outputs of the multiple implemented available reports and didn't be able to get the report
out_text_summary
working.Your Environment