(data)
| 57231 | } |
| 57232 | function matchKey(mockDispatch2, { path: path5, method, body, headers }) { |
| 57233 | const pathMatch = matchValue(mockDispatch2.path, path5); |
| 57234 | const methodMatch = matchValue(mockDispatch2.method, method); |
| 57235 | const bodyMatch = typeof mockDispatch2.body !== "undefined" ? matchValue(mockDispatch2.body, body) : true; |
| 57236 | const headersMatch = matchHeaders(mockDispatch2, headers); |
| 57237 | return pathMatch && methodMatch && bodyMatch && headersMatch; |
| 57238 | } |
| 57239 | function getResponseData(data) { |
| 57240 | if (Buffer.isBuffer(data)) { |
| 57241 | return data; |
| 57242 | } else if (typeof data === "object") { |
| 57243 | return JSON.stringify(data); |
| 57244 | } else { |
no test coverage detected
searching dependent graphs…