aboutsummaryrefslogtreecommitdiff
path: root/src/test/validation_chainstate_tests.cpp
diff options
context:
space:
mode:
authorCarl Dong <contact@carldong.me>2022-03-21 21:42:40 -0400
committerCarl Dong <contact@carldong.me>2022-06-15 17:28:55 -0400
commit86e732def3983f99ec84b59375615bedcdc0e664 (patch)
tree662d9afcfe20ad883661be3db3b90f6f971c25e3 /src/test/validation_chainstate_tests.cpp
parent213457e170ce41a0b26c644aa010111df36414a6 (diff)
scripted-diff: test: Use CTxMemPool in TestingSetup
After this commit, there should be no explicit instantiation of CTxMemPool in src/test other than those in fuzz/ and setup_common -BEGIN VERIFY SCRIPT- find_regex="CTxMemPool\s+([^;({]+)(|\(\)|\{\});" \ && git grep -l -E "$find_regex" -- src/test \ | grep -v -e "^src/test/util/setup_common.cpp$" \ -e "^src/test/fuzz/" \ | xargs sed -i -E "s@$find_regex@CTxMemPool\& \1 = *Assert(m_node.mempool);@g" -END VERIFY SCRIPT-
Diffstat (limited to 'src/test/validation_chainstate_tests.cpp')
-rw-r--r--src/test/validation_chainstate_tests.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/validation_chainstate_tests.cpp b/src/test/validation_chainstate_tests.cpp
index 98cb713a81..102de74389 100644
--- a/src/test/validation_chainstate_tests.cpp
+++ b/src/test/validation_chainstate_tests.cpp
@@ -30,7 +30,7 @@ BOOST_AUTO_TEST_CASE(validation_chainstate_resize_caches)
ChainstateManager manager{chainman_opts};
WITH_LOCK(::cs_main, manager.m_blockman.m_block_tree_db = std::make_unique<CBlockTreeDB>(1 << 20, true));
- CTxMemPool mempool;
+ CTxMemPool& mempool = *Assert(m_node.mempool);
//! Create and add a Coin with DynamicMemoryUsage of 80 bytes to the given view.
auto add_coin = [](CCoinsViewCache& coins_view) -> COutPoint {