Skip to content

Commit

Permalink
Tweak fuzzer logging
Browse files Browse the repository at this point in the history
  • Loading branch information
laurynas-biveinis committed Jun 22, 2021
1 parent 4a57c68 commit ca1c533
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions fuzz_deepstate/test_art_fuzz_deepstate.cpp
Expand Up @@ -133,8 +133,7 @@ TEST(ART, DeepStateFuzz) {
LOG(TRACE) << "Tried to insert duplicate key " << key;
ASSERT(mem_use_after == mem_use_before);
ASSERT(oracle.find(key) != oracle.cend())
<< "If insert returned failure, oracle must contain that "
"value";
<< "If insert returned failure, oracle must contain that key";
}
} catch (const std::bad_alloc &) {
const auto mem_use_after = test_db.get_current_memory_use();
Expand All @@ -152,15 +151,14 @@ TEST(ART, DeepStateFuzz) {
if (search_result) {
ASSERT(!test_db.empty());
ASSERT(oracle_search_result != oracle.cend())
<< "If search returned a value, oracle must contain that value";
<< "If search found a key, oracle must contain that key";
ASSERT(std::equal(search_result->cbegin(), search_result->cend(),
oracle_search_result->second.cbegin(),
oracle_search_result->second.cend()))
<< "Values stored in ART and in oracle must match";
} else {
ASSERT(oracle_search_result == oracle.cend())
<< "If search did not find a value, oracle must not contain "
"that value";
<< "If search did not find a key, oracle must not find it too ";
}
},
// Delete
Expand Down

0 comments on commit ca1c533

Please sign in to comment.