test_lightning.py: reduce 121 to 101 blocks, remove segwit comment.

FWIW, the tests without valgrind take 662 seconds before we reduced
the number of blocks, and only 648 seconds now.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell 2018-03-01 10:43:30 +10:30
parent 0017b9b363
commit 742885c95e

View File

@ -58,10 +58,9 @@ def setupBitcoind(directory):
" is needed, current version is {}".format(info['version']))
info = bitcoind.rpc.getblockchaininfo()
# Make sure we have segwit and some funds
if info['blocks'] < 121:
logging.debug("SegWit not active, generating some more blocks")
bitcoind.generate_block(121 - info['blocks'])
# Make sure we have some spendable funds
if info['blocks'] < 101:
bitcoind.generate_block(101 - info['blocks'])
elif bitcoind.rpc.getwalletinfo()['balance'] < 1:
logging.debug("Insufficient balance, generating 1 block")
bitcoind.generate_block(1)