handle_tx() tests
This commit is contained in:
parent
0a94f2514b
commit
d51df9f087
|
@ -55,7 +55,6 @@ function spec() {
|
||||||
console.log('[p2p_sync] Handle inv for a ' + CoinConst.MSG.to_str(inv.type));
|
console.log('[p2p_sync] Handle inv for a ' + CoinConst.MSG.to_str(inv.type));
|
||||||
});
|
});
|
||||||
// TODO: should limit the invs to objects we haven't seen yet
|
// TODO: should limit the invs to objects we haven't seen yet
|
||||||
console.log('getdata');
|
|
||||||
info.conn.sendGetData(invs);
|
info.conn.sendGetData(invs);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,7 @@ describe('PeerSync', function() {
|
||||||
});
|
});
|
||||||
it('should call sendGetData', function() {
|
it('should call sendGetData', function() {
|
||||||
ps.handle_inv(inv_info);
|
ps.handle_inv(inv_info);
|
||||||
expect(inv_info.conn.sendGetData.calledOnce).to.be.ok;
|
expect(inv_info.conn.sendGetData.calledTwice).to.be.ok;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue