mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-22 22:45:27 +01:00
test_lightningd.py: repair flaky test_bitcoin_failure
If bitcoind is still fetching blocks, we might accidentally inject the failure between getblockhash and getblock. That's OK, but it's not the failure we test for. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
a048a54f83
commit
c7718aa2e4
1 changed files with 3 additions and 0 deletions
|
@ -1118,6 +1118,9 @@ class LightningDTests(BaseLightningDTests):
|
|||
def test_bitcoin_failure(self):
|
||||
l1 = self.node_factory.get_node(fake_bitcoin_cli=True)
|
||||
|
||||
# Make sure we're not failing it between getblockhash and getblock.
|
||||
sync_blockheight([l1])
|
||||
|
||||
self.fake_bitcoind_fail(l1, 1)
|
||||
|
||||
# This should cause both estimatefee and getblockhash fail
|
||||
|
|
Loading…
Add table
Reference in a new issue