This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WebElement element = ....... | |
Select select = new Select(element); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WebDriverException: Message: Session [] was terminated due to TIMEOUT | |
Stacktrace: | |
at org.openqa.grid.internal.ActiveTestSessions.getExistingSession (ActiveTestSessions.java:105) | |
at org.openqa.grid.internal.Registry.getExistingSession (Registry.java:404) | |
at org.openqa.grid.web.servlet.handler.RequestHandler.getSession (RequestHandler.java:232) | |
at org.openqa.grid.web.servlet.handler.RequestHandler.process (RequestHandler.java:118) | |
at org.openqa.grid.web.servlet.DriverServlet.process (DriverServlet.java:83) | |
at org.openqa.grid.web.servlet.DriverServlet.doPost (DriverServlet.java:67) | |
at javax.servlet.http.HttpServlet.service (HttpServlet.java:707) | |
at javax.servlet.http.HttpServlet.service (HttpServlet.java:790) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Generated by Selenium IDE | |
from selenium import webdriver | |
from <http://selenium.webdriver.common.by|selenium.webdriver.common.by> import By | |
from selenium.webdriver.support.wait import WebDriverWait | |
from selenium.webdriver.support import expected_conditions as EC | |
import unittest | |
from time import sleep | |
class _TestUntitled(unittest.TestCase): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
self.driver.find_element(By.CSS_SELECTOR, "facebook").click() | |
wait.until(EC.number_of_windows_to_be(2)) | |
for window_handle in driver.window_handles: | |
if window_handle != original_window: | |
driver.switch_to.window(window_handle) | |
break | |
sleep(10) | |
wait.until(EC.title_contains("facebook")) | |
assert "Facebook" in driver.title | |
self.driver.close() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// The id of the checkbox we intend to click. | |
final String checkboxIdToClick = "363171428_2399318203"; | |
// Check values of the map for a webelement that has a matching id attribute. | |
getCheckboxMap().forEach((k,v) -> { | |
// If the value's attribute matches expected id, then the key webelement should be clicked since the child cannot. | |
if(v.getAttribute("id").equals(checkboxIdToClick) k.click() | |
}); | |
private Map<WebElement,WebElement> getCheckboxMap() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// The id of the checkbox we intend to click. | |
final String checkboxIdToClick = "363171428_2399318203"; | |
// Check values of the map for a webelement that has a matching id attribute. | |
getCheckboxMap().forEach((k,v) -> { | |
// If the value's attribute matches expected id, then the key webelement should be clicked since the child cannot. | |
if(v.getAttribute("id").equals(checkboxIdToClick) k.click() | |
}); | |
private Map<WebElement,WebElement> getCheckboxMap() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// The id of the checkbox we intend to click. | |
final String checkboxIdToClick = new String("363171428_2399318203") | |
// Check values of the map for a webelement that has a matching id attribute. | |
getCheckboxMap().forEach((k,v) -> { | |
// If the value's attribute matches expected id, then the key webelement should be clicked since the child cannot. | |
if(v.getAttribute("id").equals(checkboxIdToClick) k.click() | |
}); | |
private Map<WebElement,WebElement> getCheckboxMap() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
div.checkbox-button-container:nth-of-type(2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Caused by: org.openqa.selenium.json.JsonException: Unable to determine type from: <. Last 1 characters read: < | |
Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:17:03' | |
System info: host: 'ip-192-168-49-63', ip: '192.168.49.63', os.name: 'Linux', os.arch: 'amd64', os.version: '4.4.0-1100-aws', java.version: '1.8.0_265' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> https://{HIDDEN}@hub-cloud.browserstack.com/wd/hub/session | {"capabilities":{"firstMatch":[{"bstack:options":{"buildName":"OTHER ","projectName":"Public-Website-Cucumber tests","sessionName":"CI tests called from locally","os":"Windows","osVersion":"10","local":"false","seleniumVersion":"3.141.59","debug":"false","consoleLogs":"verbose","networkLogs":"false","ie":{"driver":"3.141.59"}},"browserName":"internet_explorer","browserVersion":"11","se:ieOptions":{"nativeEvents":true,"enablePersistentHover":true}}]}} |