Skip to content

Commit 7df4ae5

Browse files
committed
using right build flag for fuxx testing
Signed-off-by: alanprot <[email protected]>
1 parent c73d573 commit 7df4ae5

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

integration/parquet_querier_test.go

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,23 @@
1-
//go:build integration
2-
// +build integration
1+
//go:build integration_query_fuzz
2+
// +build integration_query_fuzz
33

44
package integration
55

66
import (
77
"context"
88
"fmt"
9+
"math/rand"
10+
"path/filepath"
11+
"strconv"
12+
"testing"
13+
"time"
14+
15+
"github.com/prometheus/prometheus/model/labels"
16+
"github.com/stretchr/testify/require"
17+
"github.com/thanos-io/objstore"
18+
"github.com/thanos-io/thanos/pkg/block"
19+
"github.com/thanos-io/thanos/pkg/block/metadata"
20+
921
"github.com/cortexproject/cortex/integration/e2e"
1022
e2edb "github.com/cortexproject/cortex/integration/e2e/db"
1123
"github.com/cortexproject/cortex/integration/e2ecortex"
@@ -14,16 +26,6 @@ import (
1426
"github.com/cortexproject/cortex/pkg/util/log"
1527
cortex_testutil "github.com/cortexproject/cortex/pkg/util/test"
1628
"github.com/cortexproject/promqlsmith"
17-
"github.com/prometheus/prometheus/model/labels"
18-
"github.com/stretchr/testify/require"
19-
"github.com/thanos-io/objstore"
20-
"github.com/thanos-io/thanos/pkg/block"
21-
"github.com/thanos-io/thanos/pkg/block/metadata"
22-
"math/rand"
23-
"path/filepath"
24-
"strconv"
25-
"testing"
26-
"time"
2729
)
2830

2931
func TestParquetFuzz(t *testing.T) {
@@ -120,13 +122,14 @@ func TestParquetFuzz(t *testing.T) {
120122
cortex_testutil.Poll(t, 30*time.Second, true, func() interface{} {
121123
found := false
122124

123-
bkt.Iter(context.Background(), "", func(name string) error {
125+
err := bkt.Iter(context.Background(), "", func(name string) error {
124126
fmt.Println(name)
125127
if name == fmt.Sprintf("parquet-markers/%v-parquet-converter-mark.json", id.String()) {
126128
found = true
127129
}
128130
return nil
129131
}, objstore.WithRecursiveIter())
132+
require.NoError(t, err)
130133
return found
131134
})
132135

@@ -167,8 +170,7 @@ func TestParquetFuzz(t *testing.T) {
167170
ps := promqlsmith.New(rnd, lbls, opts...)
168171

169172
runQueryFuzzTestCases(t, ps, c1, c2, end, start, end, scrapeInterval, 500, false)
170-
fmt.Println(cortex.Metrics())
171-
173+
172174
require.NoError(t, cortex.WaitSumMetricsWithOptions(e2e.Greater(0), []string{"cortex_parquet_queryable_blocks_queried_total"}, e2e.WithLabelMatchers(
173175
labels.MustNewMatcher(labels.MatchEqual, "type", "parquet"))))
174176
}

0 commit comments

Comments
 (0)