mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-15 11:36:00 -05:00
[refactor] updating miniminer comments to be more accurate
This commit is contained in:
parent
83933eff00
commit
b4b01d3fb4
2 changed files with 6 additions and 6 deletions
|
@ -137,10 +137,10 @@ public:
|
||||||
*/
|
*/
|
||||||
MiniMiner(const CTxMemPool& mempool, const std::vector<COutPoint>& outpoints);
|
MiniMiner(const CTxMemPool& mempool, const std::vector<COutPoint>& outpoints);
|
||||||
|
|
||||||
/** Constructor in which the MiniMinerMempoolEntry entries have been constructed manually,
|
/** Constructor in which the MiniMinerMempoolEntry entries have been constructed manually.
|
||||||
* presumably because these transactions are not in the mempool (yet). It is assumed that all
|
* It is assumed that all entries are unique and their values are correct, otherwise results
|
||||||
* entries are unique and their values are correct, otherwise results computed by MiniMiner may
|
* computed by MiniMiner may be incorrect. Callers should check IsReadyToCalculate() after
|
||||||
* be incorrect. Callers should check IsReadyToCalculate() after construction.
|
* construction.
|
||||||
* @param[in] descendant_caches A map from each transaction to the set of txids of this
|
* @param[in] descendant_caches A map from each transaction to the set of txids of this
|
||||||
* transaction's descendant set, including itself. Each tx in
|
* transaction's descendant set, including itself. Each tx in
|
||||||
* manual_entries must have a corresponding entry in this map, and
|
* manual_entries must have a corresponding entry in this map, and
|
||||||
|
|
|
@ -646,7 +646,7 @@ BOOST_FIXTURE_TEST_CASE(manual_ctor, TestChain100Setup)
|
||||||
CTxMemPool& pool = *Assert(m_node.mempool);
|
CTxMemPool& pool = *Assert(m_node.mempool);
|
||||||
LOCK2(cs_main, pool.cs);
|
LOCK2(cs_main, pool.cs);
|
||||||
{
|
{
|
||||||
// 3 pairs of fee-bumping grandparent + parent, plus 1 low-feerate child.
|
// 3 pairs of grandparent + fee-bumping parent, plus 1 low-feerate child.
|
||||||
// 0 fee + high fee
|
// 0 fee + high fee
|
||||||
auto grandparent_zero_fee = make_tx({{m_coinbase_txns.at(0)->GetHash(), 0}}, 1);
|
auto grandparent_zero_fee = make_tx({{m_coinbase_txns.at(0)->GetHash(), 0}}, 1);
|
||||||
auto parent_high_feerate = make_tx({{grandparent_zero_fee->GetHash(), 0}}, 1);
|
auto parent_high_feerate = make_tx({{grandparent_zero_fee->GetHash(), 0}}, 1);
|
||||||
|
@ -692,7 +692,7 @@ BOOST_FIXTURE_TEST_CASE(manual_ctor, TestChain100Setup)
|
||||||
BOOST_CHECK_EQUAL(sequences.at(grandparent_double_low_feerate->GetHash()), 1);
|
BOOST_CHECK_EQUAL(sequences.at(grandparent_double_low_feerate->GetHash()), 1);
|
||||||
BOOST_CHECK_EQUAL(sequences.at(parent_med_feerate->GetHash()), 1);
|
BOOST_CHECK_EQUAL(sequences.at(parent_med_feerate->GetHash()), 1);
|
||||||
|
|
||||||
// CPFP low + med
|
// CPFP low + double low
|
||||||
BOOST_CHECK_EQUAL(sequences.at(grandparent_low_feerate->GetHash()), 2);
|
BOOST_CHECK_EQUAL(sequences.at(grandparent_low_feerate->GetHash()), 2);
|
||||||
BOOST_CHECK_EQUAL(sequences.at(parent_double_low_feerate->GetHash()), 2);
|
BOOST_CHECK_EQUAL(sequences.at(parent_double_low_feerate->GetHash()), 2);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue