Skip to content

Commit

Permalink
Fix flaky (#425)
Browse files Browse the repository at this point in the history
  • Loading branch information
alonre24 authored Jan 16, 2024
1 parent b1f8b94 commit 877809f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/unit/test_hnsw_tiered.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3071,8 +3071,11 @@ TYPED_TEST(HNSWTieredIndexTest, bufferLimitAsync) {
TypeParam::isMulti() ? 1 : 1 - overwrite);
EXPECT_LE(tiered_index->frontendIndex->indexSize(), flat_buffer_limit);
}
// In first run, wait until all vectors are moved from flat index to HNSW backend index.
while (tiered_index->backendIndex->indexSize() < n) {
/*do nothing*/
}
}

mock_thread_pool.thread_pool_join();
EXPECT_EQ(tiered_index->backendIndex->indexSize(), 2 * n);
EXPECT_EQ(tiered_index->indexLabelCount(), n_labels);
Expand Down

0 comments on commit 877809f

Please sign in to comment.