mirror of
https://github.com/status-im/github-comment-manager.git
synced 2025-02-19 20:58:09 +00:00
add running of mocha tests in gulp
Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
parent
905cf97a30
commit
d2b5536d65
@ -1,6 +1,7 @@
|
||||
const gulp = require('gulp')
|
||||
const babel = require('gulp-babel')
|
||||
const clean = require('gulp-clean')
|
||||
const mocha = require('gulp-mocha')
|
||||
const print = require('gulp-print').default
|
||||
const nodemon = require('gulp-nodemon')
|
||||
|
||||
@ -17,7 +18,11 @@ gulp.task('clean', () =>
|
||||
gulp.src('dist/*').pipe(clean())
|
||||
)
|
||||
|
||||
/* WARNING: This is broken right now */
|
||||
gulp.task('test', () =>
|
||||
gulp.src('test/**/*.js', {read: false})
|
||||
.pipe(mocha({reporter: 'list', compilers: '@babel/register'}))
|
||||
)
|
||||
|
||||
gulp.task('build', () =>
|
||||
gulp.src('src/**/*.js')
|
||||
.pipe(babel())
|
||||
@ -25,4 +30,4 @@ gulp.task('build', () =>
|
||||
.pipe(gulp.dest('dist/'))
|
||||
)
|
||||
|
||||
gulp.task('default', ['clean', 'build'])
|
||||
gulp.task('default', ['clean', 'test', 'build'])
|
||||
|
@ -30,6 +30,7 @@
|
||||
"gulp": "^3.9.1",
|
||||
"gulp-babel": "^8.0.0-beta.2",
|
||||
"gulp-clean": "^0.4.0",
|
||||
"gulp-mocha": "^6.0.0",
|
||||
"gulp-nodemon": "^2.2.1",
|
||||
"gulp-print": "^5.0.0",
|
||||
"mocha": "^5.2.0",
|
||||
@ -41,7 +42,7 @@
|
||||
},
|
||||
"scripts": {
|
||||
"start": "node server.js",
|
||||
"test": "mocha --require @babel/register",
|
||||
"test": "gulp test",
|
||||
"testw": "mocha --require @babel/register --watch",
|
||||
"cover": "nyc mocha",
|
||||
"devel": "gulp devel",
|
||||
|
Loading…
x
Reference in New Issue
Block a user