tests/integration: throw if no unspent is given
This commit is contained in:
parent
755c344e16
commit
f9f41addda
1 changed files with 2 additions and 0 deletions
|
@ -27,6 +27,8 @@ testnet.faucet = function faucet (address, amount, done) {
|
||||||
return unspent.value > 1e3
|
return unspent.value > 1e3
|
||||||
}).pop()
|
}).pop()
|
||||||
|
|
||||||
|
if (!unspent) return callback(new Error('No unspent given'))
|
||||||
|
|
||||||
testnet.transactions.get(unspent.txId, function (err, tx) {
|
testnet.transactions.get(unspent.txId, function (err, tx) {
|
||||||
if (err) return callback(err)
|
if (err) return callback(err)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue