Skip to content

Commit

Permalink
fix: flaky test (#2164)
Browse files Browse the repository at this point in the history
  • Loading branch information
acud committed Jun 21, 2021
1 parent 68d4cf2 commit fab0679
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/localstore/gc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1041,7 +1041,7 @@ func TestReserveEvictionWorker(t *testing.T) {
}
select {
case testHookCollectGarbageChan <- collectedCount:
case <-db.close:
case <-closed:
}
}))

Expand All @@ -1051,6 +1051,7 @@ func TestReserveEvictionWorker(t *testing.T) {
UnreserveFunc: unres,
})

closed = db.close
// insert 10 chunks that fall into the reserve, then
// expect first one to be evicted
for i := 0; i < chunkCount; i++ {
Expand Down

0 comments on commit fab0679

Please sign in to comment.