psbt: sign without finalizing

We don't always want to finalize after signing, so make it possible to
do that.
This commit is contained in:
Andrew Chow committed 2021-09-28 19:13:42 -04:00
1 parent 6a5381a06b
commit a99ed89865
11 files changed
+32 -20

No files matched your search

+3 -1
View File
@@ -119,7 +119,9 @@ class PSBTTest(BitcoinTestFramework):
self.nodes[0].walletpassphrase(passphrase="password", timeout=1000000)
# Sign the transaction and send
signed_tx = self.nodes[0].walletprocesspsbt(psbtx)['psbt']
signed_tx = self.nodes[0].walletprocesspsbt(psbt=psbtx, finalize=False)['psbt']
finalized_tx = self.nodes[0].walletprocesspsbt(psbt=psbtx, finalize=True)['psbt']
assert signed_tx != finalized_tx
final_tx = self.nodes[0].finalizepsbt(signed_tx)['hex']
self.nodes[0].sendrawtransaction(final_tx)