jest-fetch-mock icon indicating copy to clipboard operation
jest-fetch-mock copied to clipboard

Whats the difference between jest-fetch-mock and fetch-mock?

Open pke opened this issue 4 years ago • 2 comments

Both seem to do the same thing, why are there 2 libraries? I couldn't find a reference to each other library on either project side, so I wonder what are the differences of them?

pke avatar Oct 18 '21 15:10 pke

jest-fetch-mock can only be used with Jest. fetch-mock can be used along side another test runner.

leosuncin avatar Dec 02 '21 00:12 leosuncin

fetch-mock-jest also exists which is a lightweight wrapper specialized for Jest of the fetch-mock library.

In the end it's completely your own preference which library you use. They all help you achieve the same thing.

yinzara avatar Dec 03 '21 17:12 yinzara