Merge #10704: [tests] nits in dbcrash.py

27c63dc [tests] nits in dbcrash.py (John Newbery)

Tree-SHA512: 2a75feeb65e6147e3337200cde982248bea8977a9585d5ee284d62bbc25f6d7c368754da0083aec37338c8f66cf698ee25bbd9e192df14a9fb976b8f75afa986
This commit is contained in:
MarcoFalke 2017-07-03 09:35:31 +02:00 committed by Pasta
parent 7e4318dda8
commit d9c541e9de
No known key found for this signature in database
GPG Key ID: D362C9F7142766AE

View File

@ -601,7 +601,10 @@ def satoshi_round(amount):
# Helper to create at least "count" utxos
# Pass in a fee that is sufficient for relay and mining new transactions.
def create_confirmed_utxos(fee, node, count):
node.generate(int(0.5*count)+101)
to_generate = int(0.5*count)+101
while to_generate > 0:
node.generate(min(25, to_generate))
to_generate -= 25
utxos = node.listunspent()
iterations = count - len(utxos)
addr1 = node.getnewaddress()