From ef3662ed3d1084f860645b75b1a61eea23a9fb35 Mon Sep 17 00:00:00 2001 From: Matt Reiferson Date: Fri, 7 Aug 2015 11:52:03 -0400 Subject: [PATCH] errorz --- nsqd/diskqueue_test.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/nsqd/diskqueue_test.go b/nsqd/diskqueue_test.go index caeaf5ce8..6829757f7 100644 --- a/nsqd/diskqueue_test.go +++ b/nsqd/diskqueue_test.go @@ -306,14 +306,17 @@ func benchmarkDiskQueuePut(size int64, b *testing.B) { panic(err) } defer os.RemoveAll(tmpDir) - dq := newDiskQueue(dqName, tmpDir, 1024768*100, 0, 1<<10, 2500, 2*time.Second, l) + dq := newDiskQueue(dqName, tmpDir, 1024768*100, 0, 1<<20, 2500, 2*time.Second, l) defer dq.Close() b.SetBytes(size) data := make([]byte, size) b.StartTimer() for i := 0; i < b.N; i++ { - dq.Put(data) + err := dq.Put(data) + if err != nil { + panic(err) + } } }