fix protocol test.
This commit is contained in:
parent
eb1a3ea6d2
commit
9459e278ca
@ -15,7 +15,7 @@ describe('Protocol', function() {
|
|||||||
|
|
||||||
function packetTest(command, payload, test) {
|
function packetTest(command, payload, test) {
|
||||||
it('should encode/decode ' + command, function(cb) {
|
it('should encode/decode ' + command, function(cb) {
|
||||||
var ver = framer[command](payload);
|
var ver = new Buffer(framer[command](payload));
|
||||||
parser.once('packet', function(packet) {
|
parser.once('packet', function(packet) {
|
||||||
assert.equal(packet.cmd, command);
|
assert.equal(packet.cmd, command);
|
||||||
test(packet.payload);
|
test(packet.payload);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user