Skip to content
This repository has been archived by the owner on Aug 30, 2021. It is now read-only.

Commit

Permalink
Cleanly track mongoose connection in test task sequence
Browse files Browse the repository at this point in the history
  • Loading branch information
ilanbiala committed Mar 6, 2015
1 parent 81c2847 commit 71c4d4b
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,15 +115,13 @@ gulp.task('less', function () {
gulp.task('openMongoose', function (done) {
var mongoose = require('./config/lib/mongoose.js');

mongoose.connect(function(db) {
done();
});
mongoose.connect(done);
});

gulp.task('closeMongoose', function (done) {
var mongoose = require('./config/lib/mongoose.js');

mongoose.disconnect();
mongoose.disconnect(done);
});

// Mocha tests task
Expand Down

0 comments on commit 71c4d4b

Please sign in to comment.