Refactor controllers

This commit is contained in:
Yemel Jardi 2014-08-28 15:18:05 -03:00
commit 16091bd330
9 changed files with 50 additions and 47 deletions

View file

@ -752,7 +752,7 @@ describe('Wallet model', function() {
var utxo = createUTXO(w);
w.blockchain.fixUnspent(utxo);
w.createTx(toAddress, amountSatStr, null, function(ntxid) {
sinon.stub(w.blockchain, 'sendRawTransaction').yields(undefined);
sinon.stub(w.blockchain, 'broadcast').yields({statusCode: 303});
var spyCheckSentTx = sinon.spy(w, '_checkSentTx');
w.sendTx(ntxid, function () {});
chai.expect(spyCheckSentTx.calledOnce).to.be.true;