Skip to content

Commit

Permalink
Setup test defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
zalegrala committed Apr 26, 2024
1 parent 7bc262a commit 5edc7b3
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions tempodb/blocklist/poller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@ import (
)

var (
testPollConcurrency = uint(10)
testPollFallback = true
testBuilders = 1
testPollConcurrency = uint(10)
testPollFallback = true
testBuilders = 1
testEmptyTenantIndexAge = 1 * time.Minute
)

type mockJobSharder struct {
Expand Down Expand Up @@ -260,10 +261,11 @@ func TestTenantIndexFallback(t *testing.T) {
}

poller := NewPoller(&PollerConfig{
PollConcurrency: testPollConcurrency,
PollFallback: tc.pollFallback,
TenantIndexBuilders: testBuilders,
StaleTenantIndex: tc.staleTenantIndex,
PollConcurrency: testPollConcurrency,
PollFallback: tc.pollFallback,
TenantIndexBuilders: testBuilders,
StaleTenantIndex: tc.staleTenantIndex,
EmptyTenantDeletionAge: testEmptyTenantIndexAge,
}, &mockJobSharder{
owns: tc.isTenantIndexBuilder,
}, r, c, w, log.NewNopLogger())
Expand Down Expand Up @@ -573,6 +575,7 @@ func TestPollTolerateConsecutiveErrors(t *testing.T) {
PollFallback: testPollFallback,
TenantIndexBuilders: testBuilders,
TolerateConsecutiveErrors: tc.tolerate,
EmptyTenantDeletionAge: testEmptyTenantIndexAge,
}, s, r, c, w, log.NewNopLogger())

_, _, err := poller.Do(b)
Expand Down

0 comments on commit 5edc7b3

Please sign in to comment.