|
@ -519,14 +519,25 @@ describe('client API ', function() { |
|
|
}; |
|
|
}; |
|
|
clients[1].sendTxProposal(opts, function(err, x) { |
|
|
clients[1].sendTxProposal(opts, function(err, x) { |
|
|
should.not.exist(err); |
|
|
should.not.exist(err); |
|
|
clients[1].getTxProposals({ |
|
|
|
|
|
|
|
|
// Create the proxy, ro, connected, device (2)
|
|
|
|
|
|
clients[0].export({ |
|
|
|
|
|
access: 'readonly' |
|
|
|
|
|
}, function(err, str) { |
|
|
|
|
|
should.not.exist(err); |
|
|
|
|
|
clients[2].import(str, function(err, wallet) { |
|
|
|
|
|
should.not.exist(err); |
|
|
|
|
|
|
|
|
|
|
|
clients[2].getTxProposals({ |
|
|
getRawTxps: true |
|
|
getRawTxps: true |
|
|
}, function(err, txs, rawTxps) { |
|
|
}, function(err, txs, rawTxps) { |
|
|
should.not.exist(err); |
|
|
should.not.exist(err); |
|
|
|
|
|
|
|
|
clients[1].getEncryptedPublicKeyRing(function(err, pkr) { |
|
|
clients[2].getEncryptedPublicKeyRing(function(err, pkr) { |
|
|
should.not.exist(err); |
|
|
should.not.exist(err); |
|
|
|
|
|
|
|
|
|
|
|
// Back to the air gapped
|
|
|
|
|
|
//
|
|
|
// Will trigger _tryToComplete and use pkr
|
|
|
// Will trigger _tryToComplete and use pkr
|
|
|
// then, needs pkr to verify the txps
|
|
|
// then, needs pkr to verify the txps
|
|
|
clients[0].parseTxProposals({ |
|
|
clients[0].parseTxProposals({ |
|
@ -542,6 +553,8 @@ describe('client API ', function() { |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
|
|
|
}); |
|
|
|
|
|
}); |
|
|
it('should be able export signatures and sign later from a ro client', |
|
|
it('should be able export signatures and sign later from a ro client', |
|
|
function(done) { |
|
|
function(done) { |
|
|
helpers.createAndJoinWallet(clients, 1, 1, function(err, w) { |
|
|
helpers.createAndJoinWallet(clients, 1, 1, function(err, w) { |
|
|