some improvements to CompressedCache test

This commit is contained in:
Igor Canadi 2014-02-14 17:47:53 -08:00
parent 422bb09cb0
commit 6aef661230

View File

@ -472,6 +472,11 @@ class DBTest {
ReopenWithColumnFamilies(cfs_plus_default, options);
}
void ReopenWithColumnFamilies(const std::vector<std::string>& cfs,
const std::vector<const Options*>& options) {
ASSERT_OK(TryReopenWithColumnFamilies(cfs, options));
}
void ReopenWithColumnFamilies(const std::vector<std::string>& cfs,
const Options* options = nullptr) {
ASSERT_OK(TryReopenWithColumnFamilies(cfs, options));
@ -2581,6 +2586,12 @@ TEST(DBTest, CompressedCache) {
ASSERT_TRUE(false);
}
CreateAndReopenWithCF({"pikachu"}, &options);
// default column family doesn't have block cache
Options no_block_cache_opts;
no_block_cache_opts.no_block_cache = true;
no_block_cache_opts.statistics = options.statistics;
ReopenWithColumnFamilies({"default", "pikachu"},
{&no_block_cache_opts, &options});
Random rnd(301);