Open sysmat opened 3 years ago
I had the same issue after updating my project to Angular 11, and trying to set up karma-coverage
.
Fixed it by adding the kjhtml
reporter instead of the coverage
reporter:
reporters: ['progress', 'kjhtml'],
Next time when you open such an issue, please give more context. With the little information you provided it is nearly impossible to help you.
The same problem with angular 11
Make sure you have it in plugins
section:
karma.conf.js
plugins: [
require('karma-jasmine'),
require('karma-chrome-launcher'),
require('karma-jasmine-html-reporter'),
require('karma-coverage'), <--- add this line
require('@angular-devkit/build-angular/plugins/karma'),
],
The official doc assumes that you know what you're doing and omits plugins
section in the example I think.
https://github.com/karma-runner/karma-coverage#basic
and installed