From ce6e3d8137128e99b2f7f99f79327b8b440df0a2 Mon Sep 17 00:00:00 2001 From: Ross Nicoll Date: Mon, 9 Aug 2021 23:27:38 +0100 Subject: Remove relay-only rounding Remove rounding of transaction sizes when calculating fee minimums for relaying, to simplify fee logic. --- src/test/miner_tests.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/test/miner_tests.cpp') diff --git a/src/test/miner_tests.cpp b/src/test/miner_tests.cpp index ba06a2ab7..3995d3096 100644 --- a/src/test/miner_tests.cpp +++ b/src/test/miner_tests.cpp @@ -121,7 +121,7 @@ void TestPackageSelection(const CChainParams& chainparams, CScript scriptPubKey, // Calculate a fee on child transaction that will put the package just // below the block min tx fee (assuming 1 child tx of the same size). - CAmount feeToUse = blockMinFeeRate.GetFee(2*freeTxSize) - 1; + CAmount feeToUse = blockMinFeeRate.GetRelayFee(2*freeTxSize) - 1; tx.vin[0].prevout.hash = hashFreeTx; tx.vout[0].nValue = 5000000000LL - 1000 - 50000 - feeToUse; @@ -158,7 +158,7 @@ void TestPackageSelection(const CChainParams& chainparams, CScript scriptPubKey, // This tx can't be mined by itself tx.vin[0].prevout.hash = hashFreeTx2; tx.vout.resize(1); - feeToUse = blockMinFeeRate.GetFee(freeTxSize); + feeToUse = blockMinFeeRate.GetRelayFee(freeTxSize); tx.vout[0].nValue = 5000000000LL - 100000000 - feeToUse; uint256 hashLowFeeTx2 = tx.GetHash(); mempool.addUnchecked(hashLowFeeTx2, entry.Fee(feeToUse).SpendsCoinbase(false).FromTx(tx)); -- cgit v1.2.3