Class: Selenium::WebDriver::Edge::Bridge Private
- Inherits:
-
Remote::Bridge
- Object
- Remote::Bridge
- Selenium::WebDriver::Edge::Bridge
- Defined in:
- lib/selenium/webdriver/edge/bridge.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Constant Summary
Constants inherited from Remote::Bridge
Instance Attribute Summary
Attributes inherited from Remote::Bridge
#context, #file_detector, #http
Instance Method Summary collapse
- #browser ⇒ Object private
- #capabilities ⇒ Object private
- #driver_extensions ⇒ Object private
-
#initialize(opts = {}) ⇒ Bridge
constructor
private
A new instance of Bridge.
- #quit ⇒ Object private
Methods inherited from Remote::Bridge
#acceptAlert, #addCookie, #clearElement, #clearLocalStorage, #clearSessionStorage, #click, #clickElement, #close, command, #contextClick, #create_session, #deleteAllCookies, #deleteCookie, #dismissAlert, #doubleClick, #dragElement, #elementEquals, #executeAsyncScript, #executeScript, #find_element_by, #find_elements_by, #get, #getActiveElement, #getAlert, #getAlertText, #getAllCookies, #getAvailableLogTypes, #getCapabilities, #getCurrentUrl, #getCurrentWindowHandle, #getElementAttribute, #getElementLocation, #getElementLocationOnceScrolledIntoView, #getElementSize, #getElementTagName, #getElementText, #getElementValue, #getElementValueOfCssProperty, #getLocalStorageItem, #getLocalStorageKeys, #getLocalStorageSize, #getLocation, #getLog, #getNetworkConnection, #getPageSource, #getScreenOrientation, #getScreenshot, #getSessionStorageItem, #getSessionStorageKeys, #getSessionStorageSize, #getTitle, #getVisible, #getWindowHandles, #getWindowPosition, #getWindowSize, #goBack, #goForward, #isElementDisplayed, #isElementEnabled, #isElementSelected, #maximizeWindow, #mouseDown, #mouseMoveTo, #mouseUp, #refresh, #removeLocalStorageItem, #removeSessionStorageItem, #sendKeysToActiveElement, #sendKeysToElement, #session_id, #setAlertValue, #setImplicitWaitTimeout, #setLocalStorageItem, #setLocation, #setNetworkConnection, #setScreenOrientation, #setScriptTimeout, #setSessionStorageItem, #setTimeout, #setVisible, #setWindowPosition, #setWindowSize, #status, #submitElement, #switchToDefaultContent, #switchToFrame, #switchToParentFrame, #switchToWindow, #touchDoubleTap, #touchDown, #touchElementFlick, #touchFlick, #touchLongPress, #touchMove, #touchScroll, #touchSingleTap, #touchUp, #upload
Methods included from BridgeHelper
#element_id_from, #parse_cookie_string, #unwrap_script_result
Constructor Details
#initialize(opts = {}) ⇒ Bridge
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Bridge.
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/selenium/webdriver/edge/bridge.rb', line 27 def initialize(opts = {}) http_client = opts.delete(:http_client) if opts.has_key?(:url) url = opts.delete(:url) else @service = Service.default_service(*extract_service_args(opts)) if @service.instance_variable_get("@host") == "127.0.0.1" @service.instance_variable_set("@host", 'localhost') end @service.start url = @service.uri end caps = create_capabilities(opts) remote_opts = { :url => url, :desired_capabilities => caps } remote_opts.merge!(:http_client => http_client) if http_client super(remote_opts) end |
Instance Method Details
#browser ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
55 56 57 |
# File 'lib/selenium/webdriver/edge/bridge.rb', line 55 def browser :edge end |
#capabilities ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
66 67 68 |
# File 'lib/selenium/webdriver/edge/bridge.rb', line 66 def capabilities @capabilities ||= Remote::Capabilities.edge end |
#driver_extensions ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
59 60 61 62 63 64 |
# File 'lib/selenium/webdriver/edge/bridge.rb', line 59 def driver_extensions [ DriverExtensions::TakesScreenshot, DriverExtensions::HasInputDevices ] end |
#quit ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
70 71 72 73 74 |
# File 'lib/selenium/webdriver/edge/bridge.rb', line 70 def quit super ensure @service.stop if @service end |