AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Informational 15 Bitcoin

Merge bitcoin/bitcoin#36810: test: construct `miner_tests` transactions declaratively

Public commit record

What the developer wrote

Authored by merge-script

91/100 · Strong
Merge bitcoin/bitcoin#36810: test: construct `miner_tests` transactions declaratively

8d33ffe47e38ebf84e2c832d426d307484a8d342 test: construct miner_tests sigops transactions declaratively (yuvicc)
b2ce6c1727e762cd63eb5353df52a529861d8af8 test: construct miner_tests package selection transactions declaratively (yuvicc)

Pull request description:

Part of #36692.

Add `MakeTx()` and use it in `TestPackageSelection` and `TestPrioritisedMining` so each transaction is fully specified where it is created, instead of overwriting the `prevout` and `nValue` of the previous one. Also build the `CreateBigSigOpsTx()` and `CreateBigSigOpsCluster()` transactions in place.

One implicit dependency is now explicit: BulkTransaction() pads the output script of hashFreeTx2, and the next two transactions inherited it. Their size matters for the fee rate checks, so the padded script is now passed to `MakeTx()` explicitly.

The txid, wtxid and fee of every transaction added to the mempool are unchanged.

ACKs for top commit:
purpleKarrot:
ACK 8d33ffe47e38ebf84e2c832d426d307484a8d342
alexanderwiederin:
ACK 8d33ffe47e38ebf84e2c832d426d307484a8d342
maflcko:
review ACK 8d33ffe47e38ebf84e2c832d426d307484a8d342 🦆

Tree-SHA512: ce4a052769e3dc78e1ba2aacded671c61a226fa5e501e07e4ab2325421abae78cdc8a6e3b3731983db0cbe8cb9f8e9ba5c291bda9481ed94d4c7ce266b09d51c
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification✓ Links an issue, advisory, or supporting reference
The short version

What changed, and why it matters

This commit is a pure test-code cleanup. It refactors how fake transactions are built in Bitcoin Core's miner unit tests, making them more explicit and easier to read. It does not change any production code, network behavior, or transaction hashes used in the tests.

Recommended action

No security action needed. This is a routine test refactor; review can be limited to code-quality and test-correctness checks.

Security signals we found

No strong security signals were identified.

Risk score

Why this scored 15/100

Our methodology →
Potential impact 0/30
Exploitability 0/25
Stealth signal 0/15
Affected reach 0/15
Confidence 10/10
Evidence quality 5/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.