From 2d7580cd615588ad6c841585fbf6ae805c1b0d7c Mon Sep 17 00:00:00 2001 From: Brian Olson Date: Tue, 23 Aug 2022 16:09:07 -0400 Subject: [PATCH] sleeping 1ms can still starve other processes sometimes sleep 10ms to let the test run test used to fail about 1/200; haven't seen a failure in several thousand now. --- network/wsNetwork_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/network/wsNetwork_test.go b/network/wsNetwork_test.go index b36c67d85a..dc86511254 100644 --- a/network/wsNetwork_test.go +++ b/network/wsNetwork_test.go @@ -1467,7 +1467,7 @@ func TestSlowPeerDisconnection(t *testing.T) { now := time.Now() expire := now.Add(5 * time.Second) for { - time.Sleep(time.Millisecond) + time.Sleep(10 * time.Millisecond) if len(peer.sendBufferHighPrio)+len(peer.sendBufferBulk) == 0 { break }