Skip to content

Commit

Permalink
fix(deps): Upgrade connect 3.
Browse files Browse the repository at this point in the history
This means dropping support for node 0.8.

Fixes part of karma-runner#1410
  • Loading branch information
dignifiedquire committed May 21, 2015
1 parent 1b69db1 commit 8e48323
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 22 deletions.
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ node_js:
- "iojs"
- "0.12"
- "0.10"
- "0.8"

env:
global:
Expand Down
2 changes: 1 addition & 1 deletion lib/middleware/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ var setNoCacheHeaders = function(response) {


var setHeavyCacheHeaders = function(response) {
response.setHeader('Cache-Control', ['public', 'max-age=31536000']);
response.setHeader('Cache-Control', 'public, max-age=31536000');
};


Expand Down
2 changes: 1 addition & 1 deletion lib/middleware/runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ var path = require('path');
var helper = require('../helper');
var log = require('../logger').create();
var constant = require('../constants');
var json = require('connect').json();
var json = require('body-parser').json();

// TODO(vojta): disable when single-run mode
var createRunnerMiddleware = function(emitter, fileList, capturedBrowsers, reporter, executor,
Expand Down
8 changes: 2 additions & 6 deletions lib/middleware/source_files.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

var querystring = require('querystring');
var common = require('./common');
var pause = require('connect').utils.pause;


var findByPath = function(files, path) {
Expand All @@ -28,10 +27,7 @@ var createSourceFilesMiddleware = function(filesPromise, serveFile,
.replace(/^\/absolute/, '')
.replace(/^\/base/, basePath);

// Need to pause the request because of proxying, see:
// https://groups.google.com/forum/#!topic/q-continuum/xr8znxc_K5E/discussion
// TODO(vojta): remove once we don't care about Node 0.8
var pausedRequest = pause(request);
request.pause();

return filesPromise.then(function(files) {
// TODO(vojta): change served to be a map rather then an array
Expand All @@ -51,7 +47,7 @@ var createSourceFilesMiddleware = function(filesPromise, serveFile,
next();
}

pausedRequest.resume();
request.resume();
});
};
};
Expand Down
27 changes: 14 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -162,23 +162,24 @@
"Jeff Froom <jeff@jfroom.com>"
],
"dependencies": {
"di": "~0.0.1",
"socket.io": "0.9.16",
"body-parser": "^1.12.4",
"chokidar": ">=0.8.2",
"colors": "~0.6.2",
"connect": "^3.3.5",
"di": "~0.0.1",
"glob": "~3.2.7",
"minimatch": "~0.2",
"graceful-fs": "~2.0.1",
"http-proxy": "~0.10",
"optimist": "~0.6.0",
"rimraf": "~2.2.5",
"q": "~0.9.7",
"colors": "~0.6.2",
"lodash": "~2.4.1",
"mime": "~1.2.11",
"log4js": "~0.6.3",
"useragent": "~2.0.4",
"graceful-fs": "~2.0.1",
"connect": "~2.26.0",
"source-map": "~0.1.31"
"mime": "~1.2.11",
"minimatch": "~0.2",
"optimist": "~0.6.0",
"q": "~0.9.7",
"rimraf": "~2.2.5",
"socket.io": "0.9.16",
"source-map": "~0.1.31",
"useragent": "~2.0.4"
},
"devDependencies": {
"LiveScript": "^1.3.0",
Expand Down Expand Up @@ -229,7 +230,7 @@
"main": "./lib/index",
"bin": {},
"engines": {
"node": ">=0.8 <=0.12 || >=1 <=2"
"node": ">=0.10 <=0.12 || >=1 <=2"
},
"version": "0.12.31",
"license": "MIT"
Expand Down

0 comments on commit 8e48323

Please sign in to comment.