Estoy usando Jest para probar una función en mi proyecto, pero toHaveBeenCalledWith le falta mi segundo parámetro {} :
describe("api.js", () => { it("should call callback with url", () => { const mockCallback = jest.fn(); setAppBackend(mockCallback)("/duck"); expect(mockCallback).toHaveBeenCalledWith("https://www.example.org/duck", {}); }); }); ● api.js › should call callback with url expect(jest.fn()).toHaveBeenCalledWith(...expected) - Expected + Received - "https://www.example.org/duck", + "http://www.example.org/duck", {}, ¿Por qué falta {} en toHaveBeenCalledWith ?