Skip to content

Commit

Permalink
Fix build issue under macosx
Browse files Browse the repository at this point in the history
  • Loading branch information
Chilledheart committed Sep 12, 2014
1 parent ebb5c65 commit 49fe329
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions db/db_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6036,22 +6036,22 @@ TEST(DBTest, BloomFilterWrapper) {
}
// Add a large key to make the file contain wide range
ASSERT_OK(Put(1, Key(maxKey + 55555), Key(maxKey + 55555)));
ASSERT_EQ(0, policy->GetCounter());
ASSERT_EQ(0U, policy->GetCounter());
Flush(1);

// Check if they can be found
for (int i = 0; i < maxKey; i++) {
ASSERT_EQ(Key(i), Get(1, Key(i)));
}
ASSERT_EQ(TestGetTickerCount(options, BLOOM_FILTER_USEFUL), 0);
ASSERT_EQ(maxKey, policy->GetCounter());
ASSERT_EQ(1U * maxKey, policy->GetCounter());

// Check if filter is useful
for (int i = 0; i < maxKey; i++) {
ASSERT_EQ("NOT_FOUND", Get(1, Key(i+33333)));
}
ASSERT_GE(TestGetTickerCount(options, BLOOM_FILTER_USEFUL), maxKey*0.98);
ASSERT_EQ(2 * maxKey, policy->GetCounter());
ASSERT_EQ(2U * maxKey, policy->GetCounter());
}

TEST(DBTest, SnapshotFiles) {
Expand Down

0 comments on commit 49fe329

Please sign in to comment.