diff options
author | Valery Piashchynski <[email protected]> | 2020-02-27 17:14:12 +0300 |
---|---|---|
committer | Valery Piashchynski <[email protected]> | 2020-02-27 17:14:12 +0300 |
commit | a368be6c68c2837b81789530836ca66cde605ff2 (patch) | |
tree | c48338a01546ea9eb9e365249218a7c22e8475cc /socket_factory_test.go | |
parent | 365a0527755ac8da159a75c69761dacbd4b4ef05 (diff) |
Fix test for Broken_PIPE
Diffstat (limited to 'socket_factory_test.go')
-rw-r--r-- | socket_factory_test.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/socket_factory_test.go b/socket_factory_test.go index 8beb3fc6..b2bb3ef1 100644 --- a/socket_factory_test.go +++ b/socket_factory_test.go @@ -193,14 +193,16 @@ func Test_Tcp_Broken(t *testing.T) { }() defer func() { - err = w.Stop() - assert.Error(t, err) + time.Sleep(time.Second) + err2 := w.Stop() + assert.NoError(t, err2) }() res, err := w.Exec(&Payload{Body: []byte("hello")}) assert.Error(t, err) assert.Nil(t, res) + return } func Test_Tcp_Echo(t *testing.T) { |