(err)
| 845 | t.after(client.destroy.bind(client)) |
| 846 | |
| 847 | function checkError (err) { |
| 848 | // Different platforms error with different codes... |
| 849 | p.ok( |
| 850 | err.code === 'EPIPE' || |
| 851 | err.code === 'ECONNRESET' || |
| 852 | err.code === 'UND_ERR_SOCKET' || |
| 853 | err.message === 'other side closed' |
| 854 | ) |
| 855 | } |
| 856 | |
| 857 | { |
| 858 | const body = new Readable({ read () {} }) |