Repository navigation
Conversation
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ReviewsSee the guideline for information on the review process. |
|
You will need to squash your last commit into the first one, if it fixes a compilation error. |
| CMutableTransaction bumped_tx; | ||
| const Result result = CreateRateBumpTransaction(*wallet, original_txid, coin_control, errors, old_fee, new_fee, bumped_tx, /*require_mine=*/true, /*outputs=*/{}, /*original_change_index=*/std::nullopt); | ||
|
|
||
| BOOST_CHECK_EQUAL(static_cast<int>(result), static_cast<int>(Result::WALLET_ERROR)); |
There was a problem hiding this comment.
886eed1: I think you don't need to do this static_cast, you can simply BOOST_CHECK(result == Result::WALLET_ERROR).
| LOCK2(cs_main, pool.cs); | ||
| for (int cluster = 0; cluster < 10; ++cluster) { | ||
| CTransactionRef last_tx = m_coinbase_txns.at(cluster); | ||
| const int chain_length = cluster == 0 ? 51 : 50; // 501 total txs across all clusters. |
There was a problem hiding this comment.
886eed1: The comment 501 total tx across all clusters explains what but not why. My suggestion is mentioning the limit from GatherClusters .
| LOCK(wallet->cs_wallet); | ||
| for (const auto& tip_tx : tip_txs) { | ||
| wallet->AddToWallet(tip_tx, TxStateInactive{}, [](CWalletTx& wtx, bool /*new_tx*/) { | ||
| wtx.m_state = TxStateInactive{}; |
There was a problem hiding this comment.
886eed1: I think it can be simplified to wallet->AddToWallet(tip_tx, TxStateInactive{});.
Closes #34902
Summary
calculateCombinedBumpFee()returns no value.CreateRateBumpTransaction()returnsWALLET_ERRORwith the expected error string.Test Plan
build/bin/test_bitcoin --run_test=feebumper_tests --catch_system_error=no --log_level=messagebuild/bin/test_bitcoin --run_test=feebumper_tests/feerate_check_handles_combined_bump_fee_unavailable --catch_system_error=no --log_level=message