Reduce durability test flakyness

Summary:
Reduce flakyness by ensuring the first database gets destructed before
taking wal-file count.

Reviewers: teon.banek, mferencevic, dgleich

Reviewed By: mferencevic, dgleich

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D1105
This commit is contained in:
florijan 2018-01-12 16:45:45 +01:00
parent 65f4c53529
commit 80c5fd48e1

View File

@ -674,10 +674,9 @@ TEST_F(Durability, NoWalDuringRecovery) {
// Sleep to ensure the WAL gets flushed.
std::this_thread::sleep_for(std::chrono::milliseconds(50));
wal_files_before = DirFiles(wal_dir_).size();
ASSERT_GT(wal_files_before, 3);
}
wal_files_before = DirFiles(wal_dir_).size();
ASSERT_GT(wal_files_before, 3);
{
auto recovered_config = DbConfig();
recovered_config.db_recover_on_startup = true;