Tags: matscode/nock
Tags
fix: Update and clarify how .reply() can be invoked with functions (n… …ock#1520) Ref https://github.com/nock/nock/pull/1517/files#r280139478 Closes nock#1222
fix: `req.end(cb)` compatibility with Node 12 (nock#1551)
fix: Fix `req.end(cb)`; prevent TypeError in Node 12 (nock#1547) According to the docs, `req.end` can accept callback as a first argument. That's what `got` module does. Closes nock#1509 ``` request.end([data[, encoding]][, callback])# History data <string> | <Buffer> encoding <string> callback <Function> Returns: <this> Finishes sending the request. If any parts of the body are unsent, it will flush them to the stream. If the request is chunked, this will send the terminating '0\r\n\r\n'. If data is specified, it is equivalent to calling request.write(data, encoding) followed by request.end(callback). If callback is specified, it will be called when the request stream is finished. ```
fix: Restore behavior of Interceptor.filteringPath (nock#1543) Calling `filteringPath` on the intercept instance was broken as the transform fn set on the scope had the wrong name. Proxying to the Scope’s method allows for the regex version to work too. The bulk of the changed lines come from moving the tests to their appropriate file since the real logic acts on the Scope. Found when looking at Uncovered lines in coveralls.
feat: Add `conditionally()` (nock#1488) I am building a test framework which depends on nock and to support concurrency, I need to be able shutoff certain scopes (to prevent cross-pollination) when running tests concurrently.
fix: Fix `.matchHeader()` with `allowUnmocked` (nock#1480) - Move header checks into `match()`. - Rename internal method `matchIndependentOfBody()` to `matchAddress()`
fix(intercept): Better error message when options is falsy (nock#1440)
chore(package): update lockfile package-lock.json
PreviousNext