MCPcopy Create free account
hub / github.com/nodejs/undici / checkError

Function checkError

test/node-test/client-errors.js:847–855  ·  view source on GitHub ↗
(err)

Source from the content-addressed store, hash-verified

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 () {} })

Callers 1

client-errors.jsFile · 0.85

Calls 1

okMethod · 0.80

Tested by

no test coverage detected