Skip to content

Commit

Permalink
fix(build): Require correct dependencies for prod build (meanjs#1855)
Browse files Browse the repository at this point in the history
  • Loading branch information
simison authored and cicorias committed Sep 12, 2017
1 parent 95962cd commit af7786e
Show file tree
Hide file tree
Showing 3 changed files with 10,986 additions and 31 deletions.
15 changes: 9 additions & 6 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,7 @@ var _ = require('lodash'),
wiredep = require('wiredep').stream,
path = require('path'),
endOfLine = require('os').EOL,
protractor = require('gulp-protractor').protractor,
webdriver_update = require('gulp-protractor').webdriver_update,
webdriver_standalone = require('gulp-protractor').webdriver_standalone,
del = require('del'),
KarmaServer = require('karma').Server,
semver = require('semver');

// Local settings
Expand Down Expand Up @@ -332,13 +328,15 @@ gulp.task('mocha:coverage', ['pre-test', 'mocha'], function () {

// Karma test runner task
gulp.task('karma', function (done) {
var KarmaServer = require('karma').Server;
new KarmaServer({
configFile: __dirname + '/karma.conf.js'
}, done).start();
});

// Run karma with coverage options set and write report
gulp.task('karma:coverage', function (done) {
var KarmaServer = require('karma').Server;
new KarmaServer({
configFile: __dirname + '/karma.conf.js',
preprocessors: {
Expand Down Expand Up @@ -416,15 +414,20 @@ gulp.task('mongo-seed', function (done) {
});

// Downloads the selenium webdriver if protractor version is compatible
gulp.task('webdriver_update', webdriver_update);
gulp.task('webdriver_update', function (done) {
return require('gulp-protractor').webdriver_update(done);
});

// Start the standalone selenium server
// NOTE: This is not needed if you reference the
// seleniumServerJar in your protractor.conf.js
gulp.task('webdriver_standalone', webdriver_standalone);
gulp.task('webdriver_standalone', function (done) {
return require('gulp-protractor').webdriver_standalone(done);
});

// Protractor test runner task
gulp.task('protractor', ['webdriver_update'], function () {
var protractor = require('gulp-protractor').protractor;
gulp.src([])
.pipe(protractor({
configFile: 'protractor.conf.js'
Expand Down
Loading

0 comments on commit af7786e

Please sign in to comment.