mirror of
https://github.com/a-nyx/maputnik-with-pmtiles.git
synced 2024-12-27 23:15:23 +01:00
34 lines
831 B
JavaScript
34 lines
831 B
JavaScript
var webpackConfig = require('./webpack.config.js');
|
|
|
|
// Karma configuration
|
|
module.exports = function(config) {
|
|
var browsers = ['Chrome'];
|
|
if (process.env.TRAVIS) {
|
|
browsers = ['Firefox'];
|
|
}
|
|
|
|
config.set({
|
|
browsers: browsers,
|
|
frameworks: ['mocha'],
|
|
// ... normal karma configuration
|
|
files: [
|
|
// all files ending in "_test"
|
|
{pattern: 'test/*_test.js', watched: false},
|
|
{pattern: 'test/**/*_test.js', watched: false}
|
|
// each file acts as entry point for the webpack configuration
|
|
],
|
|
|
|
preprocessors: {
|
|
// add webpack as preprocessor
|
|
'test/*_test.js': ['webpack'],
|
|
'test/**/*_test.js': ['webpack']
|
|
},
|
|
|
|
webpack: webpackConfig,
|
|
webpackMiddleware: {
|
|
// webpack-dev-middleware configuration
|
|
// i. e.
|
|
stats: 'errors-only'
|
|
}
|
|
});
|
|
};
|