test: rename CTransaction .sha256 -> .txid_int for consistency

Note that we unfortunately can't use a scripted diff here, as the same
property name is also used for `CBlockHeader`/`CBlock` instances.
This commit is contained in:
Sebastian Falbesoner committed 2025-06-11 00:52:25 +02:00
1 parent ce83924237
commit 81af4334e8
13 files changed
+114 -114

No files matched your search

+4 -4
View File
@@ -1424,7 +1424,7 @@ class TaprootTest(BitcoinTestFramework):
fund_tx = tx_from_hex(node.signrawtransactionwithwallet(fund_tx.serialize().hex())["hex"])
# Construct UTXOData entries
for i in range(count_this_tx):
utxodata = UTXOData(outpoint=COutPoint(fund_tx.sha256, i), output=fund_tx.vout[i], spender=spenders[done])
utxodata = UTXOData(outpoint=COutPoint(fund_tx.txid_int, i), output=fund_tx.vout[i], spender=spenders[done])
if utxodata.spender.need_vin_vout_mismatch:
mismatching_utxos.append(utxodata)
else:
@@ -1648,7 +1648,7 @@ class TaprootTest(BitcoinTestFramework):
# Construct a deterministic chain of transactions creating UTXOs to the test's spk's (so that they
# come from distinct txids).
txn = []
lasttxid = coinbase.sha256
lasttxid = coinbase.txid_int
amount = 5000000000
for i, spk in enumerate(old_spks + tap_spks):
val = 42000000 * (i + 7)
@@ -1660,9 +1660,9 @@ class TaprootTest(BitcoinTestFramework):
tx.vout = list(reversed(tx.vout))
tx.nLockTime = 0
amount -= val
lasttxid = tx.sha256
lasttxid = tx.txid_int
txn.append(tx)
spend_info[spk]['prevout'] = COutPoint(tx.sha256, i & 1)
spend_info[spk]['prevout'] = COutPoint(tx.txid_int, i & 1)
spend_info[spk]['utxo'] = CTxOut(val, spk)
# Mine those transactions
self.init_blockinfo(self.nodes[0])