electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 7c283f9cd21e372b9a324f370b5376fdfe1a628b
parent 8dabdf8bfb3abea550ed0e15c7695ad992d936fa
Author: SomberNight <somber.night@protonmail.com>
Date:   Tue,  1 Oct 2019 20:42:34 +0200

fix tests: follow-up prev

Diffstat:
Melectrum/tests/test_bolt11.py | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/electrum/tests/test_bolt11.py b/electrum/tests/test_bolt11.py @@ -75,7 +75,7 @@ class TestBolt11(ElectrumTestCase): # Roundtrip for t in tests: - o = lndecode(lnencode(t, PRIVKEY), False, t.currency) + o = lndecode(lnencode(t, PRIVKEY), expected_hrp=t.currency) self.compare(t, o) def test_n_decoding(self): @@ -84,7 +84,7 @@ class TestBolt11(ElectrumTestCase): hrp, data = bech32_decode(lnencode(LnAddr(RHASH, amount=24, tags=[('d', '')]), PRIVKEY), True) databits = u5_to_bitarray(data) databits.invert(-1) - lnaddr = lndecode(bech32_encode(hrp, bitarray_to_u5(databits)), True) + lnaddr = lndecode(bech32_encode(hrp, bitarray_to_u5(databits)), verbose=True) assert lnaddr.pubkey.serialize() != PUBKEY # But not if we supply expliciy `n` specifier! @@ -94,7 +94,7 @@ class TestBolt11(ElectrumTestCase): PRIVKEY), True) databits = u5_to_bitarray(data) databits.invert(-1) - lnaddr = lndecode(bech32_encode(hrp, bitarray_to_u5(databits)), True) + lnaddr = lndecode(bech32_encode(hrp, bitarray_to_u5(databits)), verbose=True) assert lnaddr.pubkey.serialize() == PUBKEY def test_min_final_cltv_expiry_decoding(self):