Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
master
Switch branches/tags
Go to file
 
 
Cannot retrieve contributors at this time
44 lines (43 sloc) 1.06 KB
const reporters = ["mocha", "coverage"];
if (process.env.COVERALLS_REPO_TOKEN) {
reporters.push("coveralls");
}
module.exports = function(config) {
config.set({
singleRun: true,
browsers: ["Firefox"],
frameworks: ["mocha"],
reporters,
coverageReporter: {
dir: "build/coverage",
reporters: [
{
type: "lcov",
subdir: "lcov"
},
{
type: "html",
subdir(browser) {
// normalization process to keep a consistent browser name
// across different OS
return browser.toLowerCase().split(/[ /-]/)[0];
}
}, {type: "text-summary"}
]
},
files: [
"node_modules/sinon/pkg/sinon.js",
"node_modules/sinon-chrome/bundle/sinon-chrome.min.js",
"add-on/webextension/main.js",
"test/unit/*.test.js"
],
preprocessors: {"add-on/*.js": ["coverage"]},
plugins: [
"karma-coveralls",
"karma-coverage",
"karma-firefox-launcher",
"karma-mocha",
"karma-mocha-reporter"
]
});
};