diff options
Diffstat (limited to 'node_modules/libnpmsearch/test/util/tnock.js')
-rw-r--r-- | node_modules/libnpmsearch/test/util/tnock.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/node_modules/libnpmsearch/test/util/tnock.js b/node_modules/libnpmsearch/test/util/tnock.js new file mode 100644 index 000000000..00b6e160e --- /dev/null +++ b/node_modules/libnpmsearch/test/util/tnock.js @@ -0,0 +1,12 @@ +'use strict' + +const nock = require('nock') + +module.exports = tnock +function tnock (t, host) { + const server = nock(host) + t.tearDown(function () { + server.done() + }) + return server +} |