From 6088e0f8c7db14e439ee644bc065f82249117b11 Mon Sep 17 00:00:00 2001 From: Ilan Biala Date: Sun, 29 Nov 2015 20:13:46 -0500 Subject: [PATCH] fix(test): Remove npm warnings by testing against Node >=0.12 Fixes #1015 --- .travis.yml | 1 - gulpfile.js | 13 ++++++------- package.json | 10 +++++----- 3 files changed, 11 insertions(+), 13 deletions(-) diff --git a/.travis.yml b/.travis.yml index d16640de96..ac5dc88e67 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,6 @@ language: node_js sudo: false node_js: - - 0.10 - 0.12 - 4 - 5 diff --git a/gulpfile.js b/gulpfile.js index 861c3b83d4..f7d9e0271f 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -18,7 +18,8 @@ var _ = require('lodash'), endOfLine = require('os').EOL, protractor = require('gulp-protractor').protractor, webdriver_update = require('gulp-protractor').webdriver_update, - webdriver_standalone = require('gulp-protractor').webdriver_standalone; + webdriver_standalone = require('gulp-protractor').webdriver_standalone, + KarmaServer = require('karma').Server; // Set NODE_ENV to 'test' gulp.task('env:test', function () { @@ -207,12 +208,10 @@ gulp.task('mocha', function (done) { // Karma test runner task gulp.task('karma', function (done) { - return gulp.src([]) - .pipe(plugins.karma({ - configFile: 'karma.conf.js', - action: 'run', - singleRun: true - })); + new KarmaServer({ + configFile: __dirname + '/karma.conf.js', + singleRun: true + }, done).start(); }); // Drops the MongoDB database, used in e2e testing diff --git a/package.json b/package.json index cf4959be1d..7f75da645f 100644 --- a/package.json +++ b/package.json @@ -11,8 +11,8 @@ "url": "https://github.com/meanjs/mean.git" }, "engines": { - "node": ">=0.10.28", - "npm": ">=1.4.28" + "node": ">=0.12.0", + "npm": ">=2.0.0" }, "scripts": { "start": "grunt", @@ -77,7 +77,7 @@ "grunt-contrib-watch": "~0.6.1", "grunt-env": "~0.4.4", "grunt-eslint": "~17.3.1", - "grunt-karma": "~0.11.2", + "grunt-karma": "~0.12.1", "grunt-mocha-istanbul": "^2.4.0", "grunt-mocha-test": "~0.12.7", "grunt-ng-annotate": "^1.0.1", @@ -93,7 +93,6 @@ "gulp-cssmin": "~0.1.7", "gulp-eslint": "~1.0.0", "gulp-jshint": "^1.11.2", - "gulp-karma": "~0.0.4", "gulp-less": "^3.0.3", "gulp-livereload": "^3.8.0", "gulp-load-plugins": "^1.0.0-rc.1", @@ -105,7 +104,8 @@ "gulp-sass": "^2.0.3", "gulp-uglify": "^1.2.0", "gulp-util": "^3.0.6", - "karma": "~0.12.37", + "istanbul": "~0.4.1", + "karma": "~0.13.15", "karma-chrome-launcher": "~0.2.0", "karma-coverage": "~0.4.2", "karma-firefox-launcher": "~0.1.6",