From 20d3971db4611c9229262b26d973a9df1a71f9f6 Mon Sep 17 00:00:00 2001 From: Tiago Ferraz Date: Thu, 12 Feb 2015 19:02:46 -0200 Subject: Add generation of coverage information from jasmine tests. Coverage is always generated when tests are executed, information is in web-ui/coverage --- web-ui/karma.conf.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'web-ui/karma.conf.js') diff --git a/web-ui/karma.conf.js b/web-ui/karma.conf.js index 7b1d699c..48a7ac60 100644 --- a/web-ui/karma.conf.js +++ b/web-ui/karma.conf.js @@ -56,7 +56,11 @@ module.exports = function (config) { // test results reporter to use // possible values: 'dots', 'progress', 'junit', 'growl', 'coverage' - reporters: ['progress', 'junit'], + reporters: ['progress', 'junit', 'coverage'], + + preprocessors: { + 'app/js/!(lib)/**/*.js': ['coverage'] + }, // enable / disable watching file and executing tests whenever any file changes autoWatch: true, @@ -87,6 +91,11 @@ module.exports = function (config) { junitReporter: { outputFile: 'test-results.xml', suite: '' + }, + + coverageReporter: { + type : 'html', + dir : 'coverage/' } }); -- cgit v1.2.3