Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
canercidam committed Nov 20, 2023
1 parent 7cad445 commit 2077edf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion feeds/timeline/timeline_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ func TestTimeline_CalculateLag(t *testing.T) {
r := require.New(t)

blockTimeline := NewBlockTimeline(1, 1000000)
blockTimeline.threshold = 10

start := time.Now().UTC().Truncate(time.Minute)

Expand Down Expand Up @@ -169,7 +170,7 @@ func TestTimeline_CalculateLag(t *testing.T) {
r.Equal(float64(1+5+9+13+15+2)/float64(6), lag)
estimate, ok := blockTimeline.EstimateBlockScore()
r.True(ok)
r.Equal(0.0625, estimate)
r.Equal(0.25, estimate)

testDelay := time.Second
blockTimeline.delay = &testDelay
Expand Down

0 comments on commit 2077edf

Please sign in to comment.