mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-22 20:58:09 +02:00
tests: Test for expected return values when calling functions returning a success code
This commit is contained in:
@@ -158,7 +158,7 @@ static void test_cache_erase(size_t megabytes)
|
||||
set.insert(hashes_insert_copy[i]);
|
||||
/** Erase the first quarter */
|
||||
for (uint32_t i = 0; i < (n_insert / 4); ++i)
|
||||
set.contains(hashes[i], true);
|
||||
BOOST_CHECK(set.contains(hashes[i], true));
|
||||
/** Insert the second half */
|
||||
for (uint32_t i = (n_insert / 2); i < n_insert; ++i)
|
||||
set.insert(hashes_insert_copy[i]);
|
||||
@@ -238,7 +238,7 @@ static void test_cache_erase_parallel(size_t megabytes)
|
||||
size_t start = ntodo*x;
|
||||
size_t end = ntodo*(x+1);
|
||||
for (uint32_t i = start; i < end; ++i)
|
||||
set.contains(hashes[i], true);
|
||||
BOOST_CHECK(set.contains(hashes[i], true));
|
||||
});
|
||||
|
||||
/** Wait for all threads to finish
|
||||
|
||||
Reference in New Issue
Block a user