Closed smoothdvd closed 5 years ago
my vue.config.js:
pluginOptions: { karma: { files: [ 'tests/unit/**/*.spec.js', ], karmaConfig: { browsers: ['ChromeCanaryHeadless'], frameworks: ['mocha', 'sinon-chai'], reporters: ['mocha', 'coverage'], coverageReporter: { dir: './tests/unit/coverage', reporters: [ { type: 'lcov', subdir: '.' }, { type: 'text-summary' }, ], }, }, }, },
result:
SUMMARY: ✔ 26 tests completed =============================== Coverage summary =============================== Statements : 74.29% ( 52/70 ) Branches : 92.68% ( 38/41 ) Functions : 73.17% ( 30/41 ) Lines : 76.47% ( 52/68 ) ================================================================================ 14 02 2019 11:32:09.912:ERROR [coverage]: { inspect: [Function: inspect] } Karma has exited with 0 ✨ Done in 9.96s.
I added karma-coverage to devDependencies. Anything wrong in this configure? How to fix it?
Need add some babel-plugin-istanbul's assets path to .yarnclean file and reinstall all node_modules.
my vue.config.js:
result:
I added karma-coverage to devDependencies. Anything wrong in this configure? How to fix it?