Add a unit test that exercises the error path in CreateRateBumpTransaction when calculateCombinedBumpFee() returns nullopt due to the 500-transaction GatherClusters DoS limit being exceeded (feebumper.cpp lines 83-87).
The test works by:
- Building 501 mempool transactions across 10 independent chains (first chain has 51 transactions, remaining nine have 50 each) using TryAddToMempool to bypass cluster policy limits
- Verifying that GatherClusters returns an empty result when queried with the tip txids from all 10 chains, confirming the >500 limit is hit
- Creating a synced wallet and a transaction that spends outputs from all 10 cluster tips
- Adding the cluster tip transactions to the wallet so AllInputsMine() recognizes the inputs, matching the realistic bumpfee RPC code path where require_mine=true
- Calling CreateRateBumpTransaction with an explicit fee rate, which triggers CheckFeeRate -> calculateCombinedBumpFee -> MiniMiner -> GatherClusters -> nullopt -> WALLET_ERROR
- Asserting the result is WALLET_ERROR with exactly one error containing the expected “enormous cluster of unconfirmed transactions” message
A functional test using the bumpfee RPC is not feasible for this code path because MAX_CLUSTER_COUNT_LIMIT (64) prevents submitting a transaction to the mempool whose inputs would merge clusters totaling more than 64 transactions, making it impossible to reach the 500-tx GatherClusters limit through normal RPC operations.