Skip to content

Commit c8c8bc7

Browse files
committed
feat(tests): moved from mocha to ava
closes #118
1 parent e31ec03 commit c8c8bc7

17 files changed

Lines changed: 81 additions & 2699 deletions

.babelrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
presets:['es2015-rollup']
2+
presets:['es2015']
33
}

Gruntfile.js

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -199,15 +199,6 @@ module.exports = function (grunt) {
199199
}
200200
},
201201

202-
mocha: {
203-
test: {
204-
src : ['test/testrunner.html'],
205-
options: {
206-
run: true
207-
}
208-
}
209-
},
210-
211202
shell: {
212203
publish: {
213204
command: 'npm publish'
@@ -228,6 +219,4 @@ module.exports = function (grunt) {
228219
grunt.registerTask("release", function (option) {
229220
grunt.task.run(["bump-only:" + option, "dist", "conventionalChangelog", "bump-commit", "shell:publish"]);
230221
});
231-
232-
grunt.registerTask("test", ["mocha"]);
233222
};

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,15 @@
3636
"license": "MIT",
3737
"devDependencies": {
3838
"autoprefixer-core": "^6.0.1",
39+
"ava": "^0.11.0",
3940
"babel": "^6.3.26",
4041
"babel-core": "^6.4.0",
4142
"babel-eslint": "^4.1.6",
43+
"babel-plugin-external-helpers": "^6.4.0",
4244
"babel-plugin-transform-regenerator": "^6.4.4",
45+
"babel-preset-es2015": "^6.3.13",
4346
"babel-preset-es2015-rollup": "^1.1.1",
44-
"chai": "^3.2.0",
47+
"babel-register": "^6.4.3",
4548
"commitizen": "^2.5.0",
4649
"cssnano": "^3.4.0",
4750
"cz-conventional-changelog": "^1.1.5",
@@ -60,28 +63,25 @@
6063
"grunt-contrib-watch": "^0.6.1",
6164
"grunt-conventional-changelog": "^5.0.0",
6265
"grunt-eslint": "^17.3.1",
63-
"grunt-mocha": "^0.4.15",
6466
"grunt-postcss": "^0.7.1",
6567
"grunt-retinafy": "^0.1.5",
6668
"grunt-shell": "^1.1.2",
6769
"grunt-spritesmith": "^6.1.1",
6870
"grunt-string-replace": "^1.2.1",
6971
"load-grunt-tasks": "^3.4.0",
70-
"mocha": "^2.3.4",
7172
"phantomjs": "^1.9.19",
7273
"promise": "^7.1.1",
7374
"rollup": "^0.25.1",
7475
"rollup-plugin-babel": "^2.3.9",
7576
"rollup-plugin-commonjs": "^2.2.0",
7677
"rollup-plugin-filesize": "^0.2.1",
7778
"rollup-plugin-npm": "^1.3.0",
78-
"rollup-plugin-replace": "^1.1.0",
7979
"rollup-plugin-uglify": "^0.1.0",
8080
"whatwg-fetch": "^0.11.0"
8181
},
8282
"scripts": {
8383
"commit": "git-cz",
84-
"test": "rollup -c test/rollup.config.js && grunt test"
84+
"test": "ava test/**/*.test.js --require babel-register"
8585
},
8686
"config": {
8787
"commitizen": {

rollup.umd.config.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,10 @@ var config = {
2828
commonjs({
2929
include: 'node_modules/**'
3030
}),
31-
babel(),
31+
babel({
32+
babelrc:false,
33+
presets:['es2015-rollup']
34+
}),
3235
filesize()
3336
]
3437
};

0 commit comments

Comments
 (0)