27 static const auto testing_setup = MakeNoLogFileContext<>();
39 const auto advance_height{
57 entry.GetTxSize(), entry.GetHeight(),
59 tx_submitted_in_package,
61 tx_has_mempool_parents);
62 block_policy_estimator.processTransaction(tx_info);
64 (void)block_policy_estimator.removeTx(tx.GetHash());
68 std::list<CTxMemPoolEntry> mempool_entries;
78 std::vector<RemovedMempoolTransactionInfo> txs;
79 txs.reserve(mempool_entries.size());
81 txs.emplace_back(mempool_entry);
90 block_policy_estimator.FlushUnconfirmed();
98 (void)block_policy_estimator.estimateRawFee(conf_target, success_threshold, horizon, result_ptr);
104 (void)block_policy_estimator.estimateSmartFee(conf_target, fee_calc_ptr, conservative);
110 AutoFile fuzzed_auto_file{fuzzed_file_provider.open()};
111 block_policy_estimator.Write(fuzzed_auto_file);
112 block_policy_estimator.Read(fuzzed_auto_file);
113 (void)fuzzed_auto_file.
fclose();
const TestingSetup * g_setup
constexpr bool DEFAULT_ACCEPT_STALE_FEE_ESTIMATES
constexpr auto ALL_FEE_ESTIMATE_HORIZONS
Non-refcounted RAII wrapper for FILE*.
The BlockPolicyEstimator is used for estimating the feerate needed for a transaction to be included i...
The basic transaction that is broadcasted on the network and contained in blocks.
CTxMemPoolEntry stores data about the corresponding transaction, as well as data about all in-mempool...
T ConsumeIntegralInRange(T min, T max)
T PickValueInArray(const T(&array)[size])
static transaction_identifier FromUint256(const uint256 &id)
uint32_t current_height
Current height in the simulation.
LIMITED_WHILE(provider.remaining_bytes(), 10000)
fs::path BlockPolicyFeeEstPath(const ArgsManager &argsman)
constexpr TransactionSerParams TX_WITH_WITNESS
FUZZ_TARGET(block_policy_estimator,.init=initialize_block_policy_estimator)
void initialize_block_policy_estimator()
CTxMemPoolEntry ConsumeTxMemPoolEntry(FuzzedDataProvider &fuzzed_data_provider, const CTransaction &tx, uint32_t max_height) noexcept
uint256 ConsumeUInt256(FuzzedDataProvider &fuzzed_data_provider) noexcept
size_t CallOneOf(FuzzedDataProvider &fuzzed_data_provider, Callables... callables)
FuzzedDataProvider & fuzzed_data_provider