e2ed
Version:
E2E testing framework over Playwright
18 lines (17 loc) • 740 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.forwardPageHistory = void 0;
const createClientFunction_1 = require("../../../createClientFunction");
const log_1 = require("../../../utils/log");
const forwardPageHistoryClient = (0, createClientFunction_1.createClientFunction)(() => window.history.forward(), {
name: 'forwardPageHistory',
});
/**
* Go forward in browser page history.
*/
const forwardPageHistory = async (page) => {
(0, log_1.log)(`Go forward in browser history from page "${page.constructor.name}"`, undefined, 5 /* LogEventType.InternalAction */);
await forwardPageHistoryClient();
await page.waitForPageLoaded();
};
exports.forwardPageHistory = forwardPageHistory;