aboutsummaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorMarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz>2023-06-30 16:25:13 +0200
committerMarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz>2023-09-15 14:34:24 +0200
commitfa56c421be04af846f479c30749b17e6663ab418 (patch)
tree26b3f14db47fb94a320da39e86eed7c5988ff654 /src/test
parent9999b89cd37fb2a23c5ebcd91d9cb31d69375933 (diff)
Return CAutoFile from BlockManager::Open*File()
This is a refactor.
Diffstat (limited to 'src/test')
-rw-r--r--src/test/blockmanager_tests.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/test/blockmanager_tests.cpp b/src/test/blockmanager_tests.cpp
index 636f5b9388..c6800c498b 100644
--- a/src/test/blockmanager_tests.cpp
+++ b/src/test/blockmanager_tests.cpp
@@ -74,13 +74,13 @@ BOOST_FIXTURE_TEST_CASE(blockmanager_scan_unlink_already_pruned_files, TestChain
// Check that the file is not unlinked after ScanAndUnlinkAlreadyPrunedFiles
// if m_have_pruned is not yet set
WITH_LOCK(chainman->GetMutex(), blockman.ScanAndUnlinkAlreadyPrunedFiles());
- BOOST_CHECK(!AutoFile(blockman.OpenBlockFile(pos, true)).IsNull());
+ BOOST_CHECK(!blockman.OpenBlockFile(pos, true).IsNull());
// Check that the file is unlinked after ScanAndUnlinkAlreadyPrunedFiles
// once m_have_pruned is set
blockman.m_have_pruned = true;
WITH_LOCK(chainman->GetMutex(), blockman.ScanAndUnlinkAlreadyPrunedFiles());
- BOOST_CHECK(AutoFile(blockman.OpenBlockFile(pos, true)).IsNull());
+ BOOST_CHECK(blockman.OpenBlockFile(pos, true).IsNull());
// Check that calling with already pruned files doesn't cause an error
WITH_LOCK(chainman->GetMutex(), blockman.ScanAndUnlinkAlreadyPrunedFiles());
@@ -90,7 +90,7 @@ BOOST_FIXTURE_TEST_CASE(blockmanager_scan_unlink_already_pruned_files, TestChain
BOOST_CHECK_NE(old_tip, new_tip);
const int new_file_number{WITH_LOCK(chainman->GetMutex(), return new_tip->GetBlockPos().nFile)};
const FlatFilePos new_pos(new_file_number, 0);
- BOOST_CHECK(!AutoFile(blockman.OpenBlockFile(new_pos, true)).IsNull());
+ BOOST_CHECK(!blockman.OpenBlockFile(new_pos, true).IsNull());
}
BOOST_FIXTURE_TEST_CASE(blockmanager_block_data_availability, TestChain100Setup)