Skip to content

Commit c1d1c6e

Browse files
cdeckerrustyrussell
authored andcommitted
pytest: Fix up the test_mutual_connect_race
A failing payment would doom all subsequent ones. Now we step down the amount a single satoshi so any prior channel_hints do not doom the payment outright. Changelog-None
1 parent 65665a4 commit c1d1c6e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tests/test_connection.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4376,7 +4376,11 @@ def test_mutual_reconnect_race(node_factory, executor, bitcoind):
43764376
def send_many_payments():
43774377
for i in range(20):
43784378
time.sleep(0.5)
4379-
inv = l2.rpc.invoice(100, "label-" + str(i), "desc")['bolt11']
4379+
inv = l2.rpc.invoice(
4380+
100 - i, # Ensure prior chanhints don't block us
4381+
"label-" + str(i),
4382+
"desc"
4383+
)['bolt11']
43804384
try:
43814385
l1.rpc.pay(inv)
43824386
except RpcError:

0 commit comments

Comments
 (0)