mirror of https://github.com/facebook/rocksdb.git
Make mock_env_test runnable in ROCKSDB_LITE
Summary: Make mock_env_test runnable in ROCKSDB_LITE Test Plan: mock_env_test Reviewers: igor, sdong, yhchiang, kradhakrishnan, anthony Reviewed By: anthony Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D42585
This commit is contained in:
parent
c06d1d8393
commit
ce9712d340
|
@ -252,6 +252,8 @@ TEST_F(MockEnvTest, DBTest) {
|
||||||
ASSERT_TRUE(!iterator->Valid());
|
ASSERT_TRUE(!iterator->Valid());
|
||||||
delete iterator;
|
delete iterator;
|
||||||
|
|
||||||
|
// TEST_FlushMemTable() is not supported in ROCKSDB_LITE
|
||||||
|
#ifndef ROCKSDB_LITE
|
||||||
DBImpl* dbi = reinterpret_cast<DBImpl*>(db);
|
DBImpl* dbi = reinterpret_cast<DBImpl*>(db);
|
||||||
ASSERT_OK(dbi->TEST_FlushMemTable());
|
ASSERT_OK(dbi->TEST_FlushMemTable());
|
||||||
|
|
||||||
|
@ -260,6 +262,7 @@ TEST_F(MockEnvTest, DBTest) {
|
||||||
ASSERT_OK(db->Get(ReadOptions(), keys[i], &res));
|
ASSERT_OK(db->Get(ReadOptions(), keys[i], &res));
|
||||||
ASSERT_TRUE(res == vals[i]);
|
ASSERT_TRUE(res == vals[i]);
|
||||||
}
|
}
|
||||||
|
#endif // ROCKSDB_LITE
|
||||||
|
|
||||||
delete db;
|
delete db;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue