@@ -7,7 +7,7 @@ describe('parser', function() {
7
7
it ( 'encodes an ArrayBuffer' , function ( ) {
8
8
var packet = {
9
9
type : parser . BINARY_EVENT ,
10
- data : new ArrayBuffer ( 2 ) ,
10
+ data : [ 'a' , new ArrayBuffer ( 2 ) ] ,
11
11
id : 0 ,
12
12
nsp : '/'
13
13
} ;
@@ -17,7 +17,7 @@ describe('parser', function() {
17
17
it ( 'encodes ArrayBuffers deep in JSON' , function ( ) {
18
18
var packet = {
19
19
type : parser . BINARY_EVENT ,
20
- data : { a : 'hi' , b : { why : new ArrayBuffer ( 3 ) } , c : { a : 'bye' , b : { a : new ArrayBuffer ( 6 ) } } } ,
20
+ data : [ 'a' , { a : 'hi' , b : { why : new ArrayBuffer ( 3 ) } , c : { a : 'bye' , b : { a : new ArrayBuffer ( 6 ) } } } ] ,
21
21
id : 999 ,
22
22
nsp : '/deep'
23
23
} ;
@@ -27,7 +27,7 @@ describe('parser', function() {
27
27
it ( 'encodes deep binary JSON with null values' , function ( ) {
28
28
var packet = {
29
29
type : parser . BINARY_EVENT ,
30
- data : { a : 'b' , c : 4 , e : { g : null } , h : new ArrayBuffer ( 9 ) } ,
30
+ data : [ 'a' , { a : 'b' , c : 4 , e : { g : null } , h : new ArrayBuffer ( 9 ) } ] ,
31
31
nsp : '/' ,
32
32
id : 600
33
33
} ;
0 commit comments