diff --git a/test/integration/_blockchain.js b/test/integration/_blockchain.js index ac77e50..7af0ec3 100644 --- a/test/integration/_blockchain.js +++ b/test/integration/_blockchain.js @@ -27,6 +27,8 @@ testnet.faucet = function faucet (address, amount, done) { return unspent.value > 1e3 }).pop() + if (!unspent) return callback(new Error('No unspent given')) + testnet.transactions.get(unspent.txId, function (err, tx) { if (err) return callback(err)