From cc30abcae64d5da5db4db84d53d3ff4ebccdee09 Mon Sep 17 00:00:00 2001 From: Ben Johnson Date: Mon, 15 Jan 2018 08:28:53 -0700 Subject: [PATCH] Fix TSI MeasurementExists() test. --- tsdb/index/tsi1/index_test.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tsdb/index/tsi1/index_test.go b/tsdb/index/tsi1/index_test.go index d95a947311..dfebf48dcb 100644 --- a/tsdb/index/tsi1/index_test.go +++ b/tsdb/index/tsi1/index_test.go @@ -113,6 +113,10 @@ func TestIndex_MeasurementExists(t *testing.T) { // Delete second series. tags.Set([]byte("region"), []byte("west")) + sid = idx.Index.SeriesFile().SeriesID(name, tags, nil) + if sid == 0 { + t.Fatalf("got 0 series id for %s/%v", name, tags) + } if err := idx.DropSeries(sid, models.MakeKey(name, tags), 0); err != nil { t.Fatal(err) }