(mockDispatches, key)
| 11010 | const bodyMatch = typeof mockDispatch2.body !== "undefined" ? matchValue(mockDispatch2.body, body) : true; |
| 11011 | const headersMatch = matchHeaders(mockDispatch2, headers); |
| 11012 | return pathMatch && methodMatch && bodyMatch && headersMatch; |
| 11013 | } |
| 11014 | function getResponseData(data) { |
| 11015 | if (Buffer.isBuffer(data)) { |
| 11016 | return data; |
| 11017 | } else if (data instanceof Uint8Array) { |
| 11018 | return data; |
| 11019 | } else if (data instanceof ArrayBuffer) { |
| 11020 | return data; |
| 11021 | } else if (typeof data === "object") { |
| 11022 | return JSON.stringify(data); |
| 11023 | } else { |
| 11024 | return data.toString(); |
| 11025 | } |
no test coverage detected