提交 23089fd2 编写于 作者: S sdong

write_callback_test: clean test directory before running tests

Summary: write_callback_test fails if previous run didn't finish cleanly. Clean the DB before runing the test.

Test Plan: Run the test that see it doesn't fail any more.

Reviewers: andrewkr, yhchiang, yiwu, IslamAbdelRahman

Reviewed By: IslamAbdelRahman

Subscribers: kradhakrishnan, leveldb, andrewkr, dhruba

Differential Revision: https://reviews.facebook.net/D56859
上级 792762c4
......@@ -123,6 +123,7 @@ TEST_F(WriteCallbackTest, WriteWithCallbackTest) {
DB* db;
DBImpl* db_impl;
DestroyDB(dbname, options);
ASSERT_OK(DB::Open(options, dbname, &db));
db_impl = dynamic_cast<DBImpl*>(db);
......@@ -282,6 +283,8 @@ TEST_F(WriteCallbackTest, WriteCallBackTest) {
DB* db;
DBImpl* db_impl;
DestroyDB(dbname, options);
options.create_if_missing = true;
Status s = DB::Open(options, dbname, &db);
ASSERT_OK(s);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册