(mockDispatches, key)
| 213 | } |
| 214 | |
| 215 | function deleteMockDispatch (mockDispatches, key) { |
| 216 | const index = mockDispatches.findIndex(dispatch => { |
| 217 | if (!dispatch.consumed) { |
| 218 | return false |
| 219 | } |
| 220 | return matchKey(dispatch, key) |
| 221 | }) |
| 222 | if (index !== -1) { |
| 223 | mockDispatches.splice(index, 1) |
| 224 | } |
| 225 | } |
| 226 | |
| 227 | /** |
| 228 | * @param {string} path Path to remove trailing slash from |
no test coverage detected