Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
Signed-off-by: Ben Ye <[email protected]>
  • Loading branch information
yeya24 committed Jun 4, 2024
1 parent 8cfb22e commit 0a87eec
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tsdb/block_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ func TestBlockIndexReader_PostingsForLabelMatching(t *testing.T) {
require.NoError(t, err)
require.NotEmpty(t, files, "No chunk created.")

block, err := OpenBlock(nil, blockDir, nil)
block, err := OpenBlock(nil, blockDir, nil, nil)
require.NoError(t, err)
t.Cleanup(func() { require.NoError(t, block.Close()) })

Expand Down
3 changes: 2 additions & 1 deletion tsdb/index/index_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -560,7 +560,8 @@ func BenchmarkReader_ShardedPostings(b *testing.B) {
}

func TestDecoder_Postings_WrongInput(t *testing.T) {
_, _, err := (&Decoder{DecodePostings: DecodePostingsRaw}).DecodePostings([]byte("the cake is a lie"))
d := encoding.Decbuf{B: []byte("the cake is a lie")}
_, _, err := (&Decoder{DecodePostings: DecodePostingsRaw}).DecodePostings(d)
require.Error(t, err)
}

Expand Down

0 comments on commit 0a87eec

Please sign in to comment.