Skip to content

Commit

Permalink
Merge pull request #4407 from filecoin-project/steb/fix-blockcache-te…
Browse files Browse the repository at this point in the history
…st-flake

give the TimeCacheBS tests a bit more time
  • Loading branch information
magik6k authored Oct 15, 2020
2 parents 7ccb2aa + 86e3072 commit 7e5b1ac
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/timedbs/timedbs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
)

func TestTimedBSSimple(t *testing.T) {
tc := timedbs.NewTimedCacheBS(3 * time.Millisecond)
tc := timedbs.NewTimedCacheBS(10 * time.Millisecond)
_ = tc.Start(context.Background())
defer func() {
_ = tc.Stop(context.Background())
Expand All @@ -36,7 +36,7 @@ func TestTimedBSSimple(t *testing.T) {
require.NoError(t, err)
require.True(t, has)

time.Sleep(4 * time.Millisecond)
time.Sleep(15 * time.Millisecond)

// We should still have everything.
has, err = tc.Has(b1.Cid())
Expand All @@ -60,7 +60,7 @@ func TestTimedBSSimple(t *testing.T) {
require.NoError(t, err)
require.ElementsMatch(t, ks, []cid.Cid{b1.Cid(), b2.Cid(), b3.Cid()})

time.Sleep(4 * time.Millisecond)
time.Sleep(10 * time.Millisecond)

// should still have b2, and b3, but not b1

Expand Down

0 comments on commit 7e5b1ac

Please sign in to comment.