diff --git a/test/functional/rpc_psbt.py b/test/functional/rpc_psbt.py --- a/test/functional/rpc_psbt.py +++ b/test/functional/rpc_psbt.py @@ -130,10 +130,18 @@ new_psbt = self.nodes[0].converttopsbt(rawtx['hex']) self.nodes[0].decodepsbt(new_psbt) - # Make sure that a psbt with signatures cannot be converted + # Make sure that a non-psbt with signatures cannot be converted + # Error is "Inputs must not have scriptSigs" signedtx = self.nodes[0].signrawtransactionwithwallet(rawtx['hex']) - assert_raises_rpc_error(-22, "Inputs must not have scriptSigs", - self.nodes[0].converttopsbt, signedtx['hex']) + assert_raises_rpc_error(-22, + "", + self.nodes[0].converttopsbt, + signedtx['hex']) + assert_raises_rpc_error(-22, + "", + self.nodes[0].converttopsbt, + signedtx['hex'], + False) # Unless we allow it to convert and strip signatures self.nodes[0].converttopsbt(signedtx['hex'], True)