Skip to content

Commit

Permalink
fix(deps): bump socket-io to v3 (karma-runner#3586)
Browse files Browse the repository at this point in the history
* fix socket-io deprecated default export
BREAKING CHANGE:
Some projects have socket.io tests that are version sensitive.
Fixes karma-runner#3569
  • Loading branch information
muuvmuuv authored Dec 15, 2020
1 parent 3fed0bc commit 1b9e1de
Show file tree
Hide file tree
Showing 3 changed files with 95 additions and 276 deletions.
4 changes: 2 additions & 2 deletions lib/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,13 @@ const EmitterWrapper = require('./emitter_wrapper')
const processWrapper = new EmitterWrapper(process)

function createSocketIoServer (webServer, executor, config) {
const server = new SocketIO(webServer, {
const server = new SocketIO.Server(webServer, {
// avoid destroying http upgrades from socket.io to get proxied websockets working
destroyUpgrade: false,
path: config.urlRoot + 'socket.io/',
transports: config.transports,
forceJSONP: config.forceJSONP,
// Default is 5000 in socket.io v2.x.
// Default is 5000 in socket.io v2.x and v3.x.
pingTimeout: config.pingTimeout || 5000
})

Expand Down
Loading

0 comments on commit 1b9e1de

Please sign in to comment.