Skip to content

Commit fb47a15

Browse files
committed
tests: Fix test_sign_and_send_psbt wrt VLS signatures
1 parent 9f3e3d1 commit fb47a15

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

tests/test_wallet.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -859,7 +859,6 @@ def test_psbt_version(node_factory, bitcoind, chainparams):
859859
l1.rpc.setpsbtversion(v2_funding, i)
860860

861861

862-
@unittest.skipIf(os.getenv('SUBDAEMON').startswith('hsmd:remote_hsmd') and os.getenv('VLS_PERMISSIVE') != '1', "validate_payments: unbalanced payments on channel")
863862
@unittest.skipIf(TEST_NETWORK == 'liquid-regtest', 'Core/Elements need joinpsbt support for v2')
864863
def test_sign_and_send_psbt(node_factory, bitcoind, chainparams):
865864
"""
@@ -1007,7 +1006,12 @@ def test_sign_and_send_psbt(node_factory, bitcoind, chainparams):
10071006
# But it can sign all the valid ones at once.
10081007
half_signed_psbt = l1.rpc.signpsbt(joint_psbt, signonly=sign_success)['signed_psbt']
10091008
for s in sign_success:
1010-
assert bitcoind.rpc.decodepsbt(half_signed_psbt)['inputs'][s]['partial_signatures'] is not None
1009+
decoded_input = bitcoind.rpc.decodepsbt(half_signed_psbt)['inputs'][s]
1010+
if 'partial_signatures' in decoded_input:
1011+
assert decoded_input['partial_signatures'] is not None
1012+
else:
1013+
# VLS returns signatures in final_scriptwitness instead
1014+
assert decoded_input['final_scriptwitness'] is not None
10111015

10121016
totally_signed = l2.rpc.signpsbt(half_signed_psbt)['signed_psbt']
10131017

0 commit comments

Comments
 (0)