oclif / fancy-test

extends mocha with helpful, chainable extensions

Home Page:https://npmjs.com/package/fancy-test

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Loosen typings for nock host to string | Regexp | Url

dan-barrett opened this issue · comments

export function nock(host: string, options: NockCallback | NockOptions, cb?: NockCallback) {

This library wraps nock in a very helpful way. However, in the above line of code, the type for the nock host is too restrictive. This should be changed from string to string | Regexp | Url, which is what the underlying nock constructor takes:

https://github.com/nock/nock/blob/749ec7f518078178c8080600494577073ee7a79a/types/index.d.ts#L11