test: rename CBlockHeader .rehash()/.sha256 -> .hash_int for consistency

Note that we unfortunately can't use a scripted diff here, as the
`sha256` symbol is also used for other instances (e.g. as function
in hashlib, or in the `UTXO` class in p2p_segwit.py).
This commit is contained in:
Sebastian Falbesoner
2025-06-12 14:13:55 +02:00
parent 8b09cc350a
commit 23be0ec2f0
33 changed files with 141 additions and 145 deletions

View File

@@ -68,7 +68,7 @@ class MutatedBlocksTest(BitcoinTestFramework):
return False
get_block_txn = honest_relayer.last_message['getblocktxn']
return get_block_txn.block_txn_request.blockhash == block.sha256 and \
return get_block_txn.block_txn_request.blockhash == block.hash_int and \
get_block_txn.block_txn_request.indexes == [1]
honest_relayer.wait_until(self_transfer_requested, timeout=5)
@@ -93,7 +93,7 @@ class MutatedBlocksTest(BitcoinTestFramework):
# The honest relayer should be able to complete relaying the block by
# sending the blocktxn that was requested.
block_txn = msg_blocktxn()
block_txn.block_transactions = BlockTransactions(blockhash=block.sha256, transactions=[tx])
block_txn.block_transactions = BlockTransactions(blockhash=block.hash_int, transactions=[tx])
honest_relayer.send_and_ping(block_txn)
assert_equal(self.nodes[0].getbestblockhash(), block.hash)