From 7c093f48a85c5e92b763e601b6bba51938cb02bb Mon Sep 17 00:00:00 2001 From: Derek Collison Date: Sat, 1 Jun 2013 14:33:47 -0700 Subject: [PATCH] Added additional time to wait for connection close from server --- test/ping_test.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/ping_test.go b/test/ping_test.go index d8a178bc..d4a7f40d 100644 --- a/test/ping_test.go +++ b/test/ping_test.go @@ -44,8 +44,10 @@ func TestPingInterval(t *testing.T) { expect(errRe) // Server should close the connection at this point.. - var err error + time.Sleep(PING_INTERVAL) c.SetWriteDeadline(time.Now().Add(PING_INTERVAL)) + + var err error for { _, err = c.Write([]byte("PING\r\n")) if err != nil {