UNPKG

webdriverio-workflo

Version:

This is a customized version of webdriverio for use with workflo framework.

30 lines (27 loc) 822 B
'use strict'; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = forward; /** * Navigate forwards in the browser history, if possible. * * @see https://w3c.github.io/webdriver/webdriver-spec.html#forward * @type protocol * */ function forward() { /*! * helper for safaridriver which doesn not support forward * Reason: "Yikes! Safari history navigation does not work. We can go forward or back, * but once we do, we can no longer communicate with the page" */ if (this.desiredCapabilities.browserName === 'safari') { return this.execute('history.go(+1)').waitForExist('body', 5000); } return this.requestHandler.create({ path: '/session/:sessionId/forward', method: 'POST' }); } module.exports = exports['default'];