Skip to content

Commit

Permalink
Make sure gulp test will exit
Browse files Browse the repository at this point in the history
  • Loading branch information
pfleidi committed Jan 9, 2016
1 parent 11777ea commit 3b5c621
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
7 changes: 5 additions & 2 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ const gulp = require('gulp');
const eslint = require('gulp-eslint');
const mocha = require('gulp-mocha');
const istanbul = require('gulp-istanbul');
const exit = require('gulp-exit');

const dbConfigPath = path.join(__dirname, 'config', 'database.js');
const dbPath = path.join(__dirname, 'db');
Expand Down Expand Up @@ -46,7 +47,8 @@ gulp.task('lint', function () {
return gulp.src(['**/*.js','!node_modules/**'])
.pipe(eslint())
.pipe(eslint.format())
.pipe(eslint.failAfterError());
.pipe(eslint.failAfterError())
.pipe(exit());
});

gulp.task('pre-test', function () {
Expand All @@ -58,6 +60,7 @@ gulp.task('pre-test', function () {
gulp.task('test', ['pre-test'], function () {
return gulp.src('./test/**/*_test.js')
.pipe(mocha())
.pipe(istanbul.writeReports(istanbulSettings));
.pipe(istanbul.writeReports(istanbulSettings))
.pipe(exit());
});

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
"coveralls": "^2.11.6",
"gulp": "^3.9.0",
"gulp-eslint": "^1.1.1",
"gulp-exit": "0.0.2",
"gulp-istanbul": "^0.10.3",
"gulp-mocha": "^2.2.0",
"supertest": "^1.1.0"
Expand Down
1 change: 0 additions & 1 deletion routes/api.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
'use strict';

const Promise = require('bluebird');
const _ = require('lodash');

module.exports = function api(config, models) {
Expand Down

0 comments on commit 3b5c621

Please sign in to comment.