Skip to content

Commit

Permalink
pytest: Disable MPP sending for 4 tests
Browse files Browse the repository at this point in the history
These mostly deal with exact HTLC counts, and fixed number of attempts to
conclusion, so the randomization that MPP adds is not desirable.
  • Loading branch information
cdecker committed Jul 13, 2020
1 parent 32394b5 commit 8f3c455
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
3 changes: 1 addition & 2 deletions tests/test_closing.py
Original file line number Diff line number Diff line change
Expand Up @@ -732,6 +732,7 @@ def test_penalty_htlc_tx_fulfill(node_factory, bitcoind, chainparams):
may_reconnect=True,
options={'dev-no-reconnect': None})
l2 = node_factory.get_node(options={'plugin': coin_mvt_plugin,
'disable-mpp': True,
'dev-no-reconnect': None},
may_reconnect=True,
allow_broken_log=True)
Expand Down Expand Up @@ -910,11 +911,9 @@ def test_penalty_htlc_tx_timeout(node_factory, bitcoind, chainparams):
# push some money so that 1 + 4 can both send htlcs
inv = l1.rpc.invoice(10**9 // 2, '1', 'balancer')
l2.rpc.pay(inv['bolt11'])
l2.rpc.waitsendpay(inv['payment_hash'])

inv = l4.rpc.invoice(10**9 // 2, '1', 'balancer')
l2.rpc.pay(inv['bolt11'])
l2.rpc.waitsendpay(inv['payment_hash'])

# now we send two 'sticky' htlcs, l1->l5 + l4->l1
amt = 10**8 // 2
Expand Down
2 changes: 1 addition & 1 deletion tests/test_connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -1963,7 +1963,7 @@ def test_fulfill_incoming_first(node_factory, bitcoind):
# We manually reconnect l2 & l3, after 100 blocks; hence allowing manual
# reconnect, but disabling auto connect, and massive cltv so 2/3 doesn't
# time out.
l1, l2, l3 = node_factory.line_graph(3, opts=[{},
l1, l2, l3 = node_factory.line_graph(3, opts=[{'disable-mpp': True},
{'may_reconnect': True,
'dev-no-reconnect': None},
{'may_reconnect': True,
Expand Down
8 changes: 6 additions & 2 deletions tests/test_pay.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,11 @@ def test_pay_exclude_node(node_factory, bitcoind):
"""
# FIXME: Remove our reliance on HTLCs failing on startup and the need for
# this plugin
opts = [{}, {'plugin': os.path.join(os.getcwd(), 'tests/plugins/fail_htlcs.py')}, {}]
opts = [
{'disable-mpp': True},
{'plugin': os.path.join(os.getcwd(), 'tests/plugins/fail_htlcs.py')},
{}
]
l1, l2, l3 = node_factory.line_graph(3, opts=opts, wait_for_announce=True)
amount = 10**8

Expand Down Expand Up @@ -1615,7 +1619,7 @@ def exhaust_channel(opener, peer, scid, already_spent=0):
# We connect every node to l5; in a line and individually.
# Keep fixed fees so we can easily calculate exhaustion
l1, l2, l3, l4, l5 = node_factory.line_graph(5, fundchannel=False,
opts={'feerates': (7500, 7500, 7500, 7500)})
opts={'feerates': (7500, 7500, 7500, 7500), 'disable-mpp': True})

# scid12
l1.fund_channel(l2, 10**6, wait_for_active=False)
Expand Down

0 comments on commit 8f3c455

Please sign in to comment.