Browse Source

test_lightningd: Also test receive of P2WPKH is correct.

For completeness.
Existing test will check P2SH-P2WPKH address only.
P2WPKH seems OK but test it anyway in case of regression.
ppa-0.6.1
ZmnSCPxj 7 years ago
committed by Christian Decker
parent
commit
78a074af5a
  1. 10
      tests/test_lightningd.py

10
tests/test_lightningd.py

@ -3498,6 +3498,16 @@ class LightningDTests(BaseLightningDTests):
output = l1.rpc.listfunds()['outputs'][0]
assert output['address'] == addr
# Send all our money to a P2WPKH address this time.
addr = l1.rpc.newaddr("bech32")['address']
l1.rpc.withdraw(addr, "all")
l1.bitcoin.rpc.generate(1)
time.sleep(1)
# The address we detect must match what was paid to.
output = l1.rpc.listfunds()['outputs'][0]
assert output['address'] == addr
@unittest.skipIf(not DEVELOPER, "needs DEVELOPER=1")
def test_channel_persistence(self):
# Start two nodes and open a channel (to remember). l2 will

Loading…
Cancel
Save