Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
  • Loading branch information
fpetkovski committed Feb 20, 2023
1 parent 71be061 commit 0222886
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions pkg/store/storepb/testutil/series.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,18 @@ import (
"time"

"github.com/cespare/xxhash"
"github.com/prometheus/prometheus/model/histogram"
"github.com/prometheus/prometheus/storage"
"github.com/prometheus/prometheus/tsdb/chunkenc"
"github.com/stretchr/testify/require"
"go.uber.org/atomic"

"github.com/efficientgo/core/testutil"
"github.com/gogo/protobuf/types"
"github.com/prometheus/prometheus/model/histogram"
"github.com/prometheus/prometheus/model/labels"
"github.com/prometheus/prometheus/storage"
"github.com/prometheus/prometheus/tsdb"
"github.com/prometheus/prometheus/tsdb/chunkenc"
"github.com/prometheus/prometheus/tsdb/chunks"
"github.com/prometheus/prometheus/tsdb/index"
"github.com/prometheus/prometheus/tsdb/wlog"

"github.com/efficientgo/core/testutil"
"github.com/stretchr/testify/require"
"go.uber.org/atomic"

"github.com/thanos-io/thanos/pkg/store/hintspb"
"github.com/thanos-io/thanos/pkg/store/labelpb"
Expand Down Expand Up @@ -72,6 +70,10 @@ func CreateHeadWithSeries(t testing.TB, j int, opts HeadGenOptions) (*tsdb.Head,
if opts.ScrapeInterval == 0 {
opts.ScrapeInterval = 1 * time.Millisecond
}
// Use float type if sample type is not set.
if opts.SampleType == chunkenc.ValNone {
opts.SampleType = chunkenc.ValFloat
}

fmt.Printf(
"Creating %d %d-sample series with %s interval in %s\n",
Expand Down

0 comments on commit 0222886

Please sign in to comment.