Add GetMapProperty to db_stress (#8551)

Summary:
Already has good coverage for GetProperty and GetIntProperty
but this one was missing.

This should add more confidence to https://github.com/facebook/rocksdb/issues/8538

Pull Request resolved: https://github.com/facebook/rocksdb/pull/8551

Test Plan:
brief local run with boosted probability showed no immediate
issues

Reviewed By: siying

Differential Revision: D29746383

Pulled By: pdillinger

fbshipit-source-id: 9f9f525bc1a7607f85e563e33bda1979ef197127
This commit is contained in:
Peter Dillinger 2021-07-19 08:09:35 -07:00 committed by Facebook GitHub Bot
parent 9e885939a3
commit d5f3b77f23

View File

@ -1766,6 +1766,14 @@ void StressTest::TestGetProperty(ThreadState* thread) const {
thread->shared->SetVerificationFailure();
}
}
if (ppt_name_and_info.second.handle_map != nullptr) {
std::map<std::string, std::string> prop_map;
if (!db_->GetMapProperty(ppt_name_and_info.first, &prop_map)) {
fprintf(stderr, "Failed to get Map property: %s\n",
ppt_name_and_info.first.c_str());
thread->shared->SetVerificationFailure();
}
}
}
}