You can use jest.spyOn in combination with functions like mockImplementation to mock a function while preserving type safety in TypeScript:
確定! 回上一頁