Skip to content

Commit fa5059b

Browse files
author
MacroFake
committed
test: Make the scriptPubKey of MiniWallet created txs mutable
This makes individual bytes of the scriptPubKey mutable, previously it could only be re-assigned as a whole.
1 parent fa29245 commit fa5059b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/functional/test_framework/wallet.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ def create_self_transfer(self, *, fee_rate=Decimal("0.003"), fee=Decimal("0"), u
294294

295295
tx = CTransaction()
296296
tx.vin = [CTxIn(COutPoint(int(utxo_to_spend['txid'], 16), utxo_to_spend['vout']), nSequence=sequence)]
297-
tx.vout = [CTxOut(int(COIN * send_value), self._scriptPubKey)]
297+
tx.vout = [CTxOut(int(COIN * send_value), bytearray(self._scriptPubKey))]
298298
tx.nLockTime = locktime
299299
if self._mode == MiniWalletMode.RAW_P2PK:
300300
self.sign_tx(tx)

0 commit comments

Comments
 (0)