You could set global.fetch to a jest.fn() that uses the mockReturnValueOnce() API for each expected fetch call: const makeFetchResp = value => ({ json: ...
確定! 回上一頁