go back / go searchMock window object behaviorsDecember 1, 2021jest.spyOn(window, "close").mockImplementation(() => {}); window.HTMLElement.prototype.scrollIntoView = function () {}; codemockjavascript