mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-05-05 19:38:54 +02:00
test: rename CTransaction .rehash()/.hash -> .txid_hex for consistency
Note that we unfortunately can't use a scripted diff here, as the same property and method name is also used for `CBlockHeader`/`CBlock` instances.
This commit is contained in:
@@ -1540,7 +1540,7 @@ class TaprootTest(BitcoinTestFramework):
|
||||
msg = ','.join(utxo.spender.comment + ("*" if n == fail_input else "") for n, utxo in enumerate(input_utxos))
|
||||
if is_standard_tx:
|
||||
node.sendrawtransaction(tx.serialize().hex(), 0)
|
||||
assert node.getmempoolentry(tx.hash) is not None, "Failed to accept into mempool: " + msg
|
||||
assert node.getmempoolentry(tx.txid_hex) is not None, "Failed to accept into mempool: " + msg
|
||||
else:
|
||||
assert_raises_rpc_error(-26, None, node.sendrawtransaction, tx.serialize().hex(), 0)
|
||||
# Submit in a block
|
||||
@@ -1566,7 +1566,7 @@ class TaprootTest(BitcoinTestFramework):
|
||||
coinbase.vin = [CTxIn(COutPoint(0, 0xffffffff), CScript([OP_1, OP_1]), SEQUENCE_FINAL)]
|
||||
coinbase.vout = [CTxOut(5000000000, CScript([OP_1]))]
|
||||
coinbase.nLockTime = 0
|
||||
assert coinbase.hash == "f60c73405d499a956d3162e3483c395526ef78286458a4cb17b125aa92e49b20"
|
||||
assert coinbase.txid_hex == "f60c73405d499a956d3162e3483c395526ef78286458a4cb17b125aa92e49b20"
|
||||
# Mine it
|
||||
block = create_block(hashprev=int(self.nodes[0].getbestblockhash(), 16), coinbase=coinbase)
|
||||
block.rehash()
|
||||
|
||||
Reference in New Issue
Block a user