Skip to content

Commit afcddd2

Browse files
authored
Merge pull request #22 from taion/chore
Update tooling
2 parents fb060f2 + 0a292cc commit afcddd2

File tree

3 files changed

+76
-73
lines changed

3 files changed

+76
-73
lines changed

karma.conf.babel.js

Lines changed: 0 additions & 48 deletions
This file was deleted.

karma.conf.js

Lines changed: 52 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,52 @@
1-
require('babel-register');
2-
module.exports = require('./karma.conf.babel.js');
1+
const webpack = require('webpack');
2+
3+
module.exports = config => {
4+
const { env } = process;
5+
6+
const isCi = env.CONTINUOUS_INTEGRATION === 'true';
7+
8+
config.set({
9+
frameworks: ['mocha'],
10+
11+
files: ['test/index.js'],
12+
13+
preprocessors: {
14+
'test/index.js': ['webpack', 'sourcemap'],
15+
},
16+
17+
webpack: {
18+
module: {
19+
loaders: [
20+
{ test: /\.js$/, exclude: /node_modules/, loader: 'babel' },
21+
],
22+
},
23+
plugins: [
24+
new webpack.DefinePlugin({
25+
'process.env.NODE_ENV': JSON.stringify('test'),
26+
}),
27+
],
28+
devtool: 'cheap-module-inline-source-map',
29+
},
30+
31+
webpackMiddleware: {
32+
noInfo: true,
33+
},
34+
35+
reporters: ['mocha'],
36+
37+
mochaReporter: {
38+
output: 'autowatch',
39+
},
40+
41+
customLaunchers: {
42+
ChromeCi: {
43+
base: 'Chrome',
44+
flags: ['--no-sandbox'],
45+
},
46+
},
47+
48+
browsers: env.BROWSER ? env.BROWSER.split(',') : ['Chrome', 'Firefox'],
49+
50+
singleRun: isCi,
51+
});
52+
};

package.json

Lines changed: 24 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -36,35 +36,36 @@
3636
"react-router": "^2.3.0"
3737
},
3838
"devDependencies": {
39-
"babel-cli": "^6.7.7",
40-
"babel-core": "^6.8.0",
41-
"babel-eslint": "^6.0.4",
39+
"babel-cli": "^6.10.1",
40+
"babel-core": "^6.10.4",
41+
"babel-eslint": "^6.1.2",
4242
"babel-loader": "^6.2.4",
43-
"babel-plugin-add-module-exports": "^0.1.4",
44-
"babel-polyfill": "^6.7.4",
45-
"babel-preset-es2015": "^6.6.0",
43+
"babel-plugin-add-module-exports": "^0.2.1",
44+
"babel-polyfill": "^6.9.1",
45+
"babel-preset-es2015": "^6.9.0",
4646
"babel-preset-es2015-loose": "^7.0.0",
47-
"babel-preset-react": "^6.5.0",
47+
"babel-preset-react": "^6.11.1",
4848
"babel-preset-stage-1": "^6.5.0",
4949
"chai": "^3.5.0",
5050
"dom-helpers": "^2.4.0",
51-
"eslint": "^2.9.0",
52-
"eslint-config-airbnb": "^8.0.0",
53-
"eslint-plugin-import": "^1.6.1",
54-
"eslint-plugin-jsx-a11y": "^1.0.4",
55-
"eslint-plugin-react": "^5.0.1",
56-
"karma": "^0.13.22",
57-
"karma-chrome-launcher": "^0.2.3",
58-
"karma-firefox-launcher": "^0.1.7",
59-
"karma-mocha": "^1.0.1",
60-
"karma-mocha-reporter": "^2.0.2",
51+
"eslint": "^2.13.1",
52+
"eslint-config-airbnb": "^9.0.1",
53+
"eslint-plugin-import": "^1.10.2",
54+
"eslint-plugin-jsx-a11y": "^1.5.5",
55+
"eslint-plugin-react": "^5.2.2",
56+
"history": "^2.1.2",
57+
"karma": "^1.1.1",
58+
"karma-chrome-launcher": "^1.0.1",
59+
"karma-firefox-launcher": "^1.0.0",
60+
"karma-mocha": "^1.1.1",
61+
"karma-mocha-reporter": "^2.0.4",
6162
"karma-sourcemap-loader": "^0.3.7",
6263
"karma-webpack": "^1.7.0",
63-
"mocha": "^2.4.5",
64-
"react": "^15.0.2",
65-
"react-dom": "^15.0.2",
66-
"react-router": "^2.4.0",
67-
"rimraf": "^2.5.2",
68-
"webpack": "^1.13.0"
64+
"mocha": "^2.5.3",
65+
"react": "^15.2.1",
66+
"react-dom": "^15.2.1",
67+
"react-router": "^2.5.2",
68+
"rimraf": "^2.5.3",
69+
"webpack": "^1.13.1"
6970
}
7071
}

0 commit comments

Comments
 (0)