From 3c62cc6bba7ccc1f6f646cb575c57f7b04da3507 Mon Sep 17 00:00:00 2001 From: Ferenc Szabo Date: Tue, 5 Feb 2019 14:34:34 +0100 Subject: swarm/storage: fix test timeout with -race by increasing mget timeout (cherry picked from commit 1c3aa8d9b12d6104ccddecc1711bc6be2f5b269d) --- swarm/storage/common_test.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'swarm/storage/common_test.go') diff --git a/swarm/storage/common_test.go b/swarm/storage/common_test.go index 8ad95bfbc..23d43becc 100644 --- a/swarm/storage/common_test.go +++ b/swarm/storage/common_test.go @@ -142,10 +142,11 @@ func mget(store ChunkStore, hs []Address, f func(h Address, chunk Chunk) error) close(errc) }() var err error + timeout := 10 * time.Second select { case err = <-errc: - case <-time.NewTimer(5 * time.Second).C: - err = fmt.Errorf("timed out after 5 seconds") + case <-time.NewTimer(timeout).C: + err = fmt.Errorf("timed out after %v", timeout) } return err } -- cgit v1.2.3