mirror of
https://github.com/socketio/socket.io.git
synced 2026-04-30 03:00:39 -04:00
Added changes to reflect socket.io-parser's async encoding, and use of has-binarydata to check the event type of an event. Next added browser tests for sending and receiving of binary data via arraybuffers. Then added blob tests and blob recognition. To make blobs fully work (and Files as well), had to add packet buffering to client so that slow-encoding blobs are still sent before other events. I fixed a stupid bug I had added where I used the indexof module (for old browsers) on a string somewhere instead of an array). This was causing old IE to receive all events twice. Old iphone tests were still failing so I updated tests to reflect that some browsers can receive a blob but not construct them. Finally, reduced build size by adding the "browser" field to package.json and making browserify less confused.
21 lines
417 B
JavaScript
21 lines
417 B
JavaScript
|
|
var env = require('./support/env');
|
|
|
|
// whitelist some globals to avoid warnings
|
|
global.__eio = null;
|
|
global.WEB_SOCKET_LOGGER = null;
|
|
global.WEB_SOCKET_SUPPRESS_CROSS_DOMAIN_SWF_ERROR = null;
|
|
global.WEB_SOCKET_DISABLE_AUTO_INITIALIZATION = null;
|
|
global.WEB_SOCKET_SWF_LOCATION = null;
|
|
|
|
// node only tests
|
|
if (env.node) {
|
|
require('./url');
|
|
}
|
|
|
|
// browser only tests
|
|
if (env.browser) {
|
|
require('./connection');
|
|
}
|
|
|