Browse Source

Replace connect with express

Not a huge functional difference for how we're using it, but
express is better maintained and much more active.
pull/481/head
Gabe Gorelick 7 years ago
parent
commit
e85dad1f7e
No known key found for this signature in database
GPG Key ID: E25EDE6B9096D77D
  1. 5
      package.json
  2. 5
      tests/test.js

5
package.json

@ -37,15 +37,14 @@ @@ -37,15 +37,14 @@
"main": "papaparse.js",
"devDependencies": {
"chai": "^4.1.2",
"connect": "^3.3.3",
"eslint": "^4.19.1",
"express": "^4.16.3",
"grunt": "^1.0.2",
"grunt-contrib-uglify": "^3.3.0",
"mocha": "^3.5.0",
"mocha-phantomjs": "^4.1.0",
"open": "0.0.5",
"phantomjs-prebuilt": "^2.1.16",
"serve-static": "^1.7.1"
"phantomjs-prebuilt": "^2.1.16"
},
"scripts": {
"lint": "eslint --no-ignore papaparse.js Gruntfile.js .eslintrc.js 'tests/**/*.js'",

5
tests/test.js

@ -1,10 +1,9 @@ @@ -1,10 +1,9 @@
var connect = require('connect');
var serveStatic = require('serve-static');
var express = require('express');
var open = require('open');
var path = require('path');
var childProcess = require('child_process');
var server = connect().use(serveStatic(path.join(__dirname, '/..'))).listen(8071, function () {
var server = express().use(express.static(path.join(__dirname, '/..'))).listen(8071, function () {
if (process.argv.indexOf('--phantomjs') !== -1) {
childProcess.spawn('node_modules/.bin/mocha-phantomjs', ['http://localhost:8071/tests/tests.html'], {
stdio: 'inherit'

Loading…
Cancel
Save