Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Added parser test for newline.

  • Loading branch information...
commit 2a5c7b2c5b5febbf892cc2f5d2de439b5e0b56a0 1 parent 85991d9
@rauchg rauchg authored
Showing with 8 additions and 0 deletions.
  1. +8 −0 test/parser.test.js
View
8 test/parser.test.js
@@ -341,6 +341,14 @@
parser.encodePacket({ type: 'message', data: '5', endpoint: '' })
, parser.encodePacket({ type: 'message', data: '53d', endpoint: '' })
]).should().eql('\ufffd5\ufffd3:::5\ufffd7\ufffd3:::53d')
+ },
+
+ 'test decoding newline': function () {
+ parser.decodePacket('3:::\n').should().eql({
+ type: 'message'
+ , endpoint: ''
+ , data: '\n'
+ });
}
};
Please sign in to comment.
Something went wrong with that request. Please try again.