mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-03-03 18:57:06 +01:00
pytest: test to show that listpays doesn't remember bolt11 string.
[Separated into separate commit by RR]
This commit is contained in:
parent
669daf680e
commit
f4f2853ded
1 changed files with 24 additions and 0 deletions
|
@ -3193,3 +3193,27 @@ def test_pay_fail_unconfirmed_channel(node_factory, bitcoind):
|
||||||
|
|
||||||
# Now l1 can pay to l2.
|
# Now l1 can pay to l2.
|
||||||
l1.rpc.pay(invl2)
|
l1.rpc.pay(invl2)
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.mark.xfail(strict=True)
|
||||||
|
def test_bolt11_null_after_pay(node_factory, bitcoind):
|
||||||
|
l1, l2 = node_factory.get_nodes(2)
|
||||||
|
|
||||||
|
amount_sat = 10 ** 6
|
||||||
|
# pay a generic bolt11 and test if the label bol11 is null
|
||||||
|
# inside the command listpays
|
||||||
|
|
||||||
|
# create l2->l1 channel.
|
||||||
|
l2.fundwallet(amount_sat * 5)
|
||||||
|
l1.rpc.connect(l2.info['id'], 'localhost', l2.port)
|
||||||
|
l2.rpc.fundchannel(l1.info['id'], amount_sat * 3)
|
||||||
|
|
||||||
|
# Let the channel confirm.
|
||||||
|
bitcoind.generate_block(6)
|
||||||
|
sync_blockheight(bitcoind, [l1, l2])
|
||||||
|
|
||||||
|
invl1 = l1.rpc.invoice(Millisatoshi(amount_sat * 2 * 1000), 'j', 'j')['bolt11']
|
||||||
|
l2.rpc.pay(invl1)
|
||||||
|
|
||||||
|
pays = l2.rpc.listpays()["pays"]
|
||||||
|
assert pays[0]["bolt11"] == invl1
|
||||||
|
|
Loading…
Add table
Reference in a new issue