Skip to content

Commit 2737f32

Browse files
jkohenfabxc
authored andcommitted
Replace fatal in test goroutine (#59)
t.Fatal is supposed to be called in the same thread that runs the test.
1 parent c357bf3 commit 2737f32

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

retrieval/manager_test.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,15 @@ func TestReader_Progress(t *testing.T) {
103103
// that encodes the record's offset in its timestamp.
104104
sz, err := tailer.Size()
105105
if err != nil {
106-
t.Fatal(err)
106+
t.Error(err)
107+
break
107108
}
108109
samples := make([]tsdb.RefSample, 1000)
109110
samples[0] = tsdb.RefSample{Ref: 1, T: int64(sz) * 1000}
110111

111112
if err := w.Log(enc.Samples(samples, nil)); err != nil {
112-
t.Fatal(err)
113+
t.Error(err)
114+
break
113115
}
114116
}
115117
}()

0 commit comments

Comments
 (0)