jefflau / jest-fetch-mock

Jest mock for fetch
MIT License
883 stars 116 forks source link

Updated Jest and Jest Types #106

Closed janhartmann closed 5 years ago

janhartmann commented 5 years ago

Adjusted breaking change of generic signature of MockInstance:

https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/jest/index.d.ts#L810

simonphilips commented 5 years ago

It's suffices to modify:

export interface FetchMock extends jest.MockInstance<any> {

to:

export interface FetchMock extends jest.MockInstance<any,any[]> {

and depend on "@types/jest": "^23.3.14",

That way you can avoid having to upgrade your requirements to Jest 24 (which can go in some other PR).

janhartmann commented 5 years ago

Agreed, hold on.

kevcenteno commented 5 years ago

@jefflau Any chance we can get this merged + released?

jefflau commented 5 years ago

Ill have a look tomorrow! If its not in tomorrow, nudge me again. It’s chinese new year so things are a little hectic!


From: Kevin Centeno notifications@github.com Sent: Friday, February 8, 2019 1:50:18 AM To: jefflau/jest-fetch-mock Cc: Jeff Lau; Mention Subject: Re: [jefflau/jest-fetch-mock] Updated Jest and Jest Types (#106)

@jefflauhttps://github.com/jefflau Any chance we can get this merged + released?

β€” You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/jefflau/jest-fetch-mock/pull/106#issuecomment-461529375, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ABKiFWngThi1VLgyOsVbdHdN91_A8jCbks5vLGdagaJpZM4ai0RE.

kevcenteno commented 5 years ago

Ah, no worries! πŸŽ† πŸ–

janhartmann commented 5 years ago

Cheers @jefflau - enjoy it! πŸŽ‰

ma581 commented 5 years ago

Hey @kevcenteno would you please check/merge the fix? :D

kevcenteno commented 5 years ago

@ma581 it isn't my repo... Ping @jefflau

janhartmann commented 5 years ago

@jefflau will you be able to release this anytime soon?

jefflau commented 5 years ago

Sorry for the wait. I gotta pretty sick just after the new year and haven't had a chance to merge. I'm going to merge now.