Selenium-Webdriver provides an API to control and communicate with web browsers.

learn more… | top users | synonyms

97
votes
16answers
56k views

Take a screenshot with Selenium WebDriver

Does anyone know if it's possible to take a screenshot using Selenium WebDriver? (Note: Not Selenium RC)
4
votes
3answers
4k views

Alert handling in Selenium 2 (WebDriver) with Java

I want to detect whether an alert is popped up or not. Currently I am using the following code: try { Alert alert = webDriver.switchTo().alert(); // check if alert exists ...
7
votes
3answers
610 views

Pytest: how to skip the rest of tests in the class if one has failed?

I'm creating the test cases for web-tests using Jenkins, Python, Selenium2(webdriver) and Py.test frameworks. So far I'm organizing my tests in the following structure: each Class is the Test ...
25
votes
16answers
22k views

How do I maximize the browser window in WebDriver (Selenium 2)?

Is there a way to maximize the browser window using WebDriver (Selenium 2) with C#?
15
votes
8answers
28k views

Selenium WebDriver and DropDown Boxes

If I want to select an option of a dropdown box, there are several ways to do that. I always used: driver.findElement(By.id("selection")).sendKeys("Germany"); But that didn't work every time. ...
3
votes
5answers
15k views

How to get text from each cell of an HTML table?

In Selenium 2.0, I have no idea how to traverse through a HTML table in a webpage. In selenium2.0 javadoc, I found two classes "TableFinder" and "TableCellFinder", but I couldn't find any examples. ...
15
votes
10answers
30k views

How do I set a an option as selected using selenium-webdriver (selenium 2.0) client in ruby

I am trying to get familiar with the new ruby selenium-webdriver as it appears more intuitive mostly than the previous version of selenium and the ruby driver that went with it. Also, i had trouble ...
4
votes
1answer
430 views

Selenium and HTML Window location

I am using Selenium's WebDriver in conjunction with java.awt.Robot to better simulate user interaction with our web application. Yes, I know it's probably unnecessary, but the customers I serve ...
3
votes
4answers
3k views

How to deal with ModalDialog using selenium webdriver?

I am unable to switch to Modal Dialog of given example http://tinyurl.com/ykt97gx I don't know how to get element on modal Dialog
1
vote
2answers
769 views

Opening new window in WebDriver using C#

EDIT 4: EDIT 3 EDIT 2 string currentWindow = driver.CurrentWindowHandle; driver.SwitchTo().Window(""); string childTitle = driver.Title; driver.SwitchTo().Window(currentWindow); ...
1
vote
2answers
883 views

How to initialize multiple browsers in WebDriver using Java?

I want to use Firefox, IE, Chrome in one single code. I can only initialize Firefox as driver = new FirefoxDriver(); but cannot initialize other browsers in the same way. For example: driver = new ...
3
votes
1answer
4k views

How to type some text in hidden field in WebDriver

I am using WebDriver with Java for test automation. I have the following HTML code for input field which is hidden: <input type="hidden" value="" name="body" id=":6b"> How to type something ...
12
votes
4answers
3k views

Unable to obtain stable firefox connection in 60 seconds (127.0.0.1:7055)

While testing scenario by cucumber i'm getting the following error when running rspec tests unable to obtain stable firefox connection in 60 seconds (127.0.0.1:7055) ...
2
votes
2answers
174 views

ImageTag exists in the TR?

EDIT: public bool getImage() { IWebElement table = driver.FindElement(By.Id("DIV_ID_1")); string name = String.Format("//*[contains(text(), \'{0}\')]", 'TEST1'); IWebElement element = ...
1
vote
2answers
3k views

How to do mouse hover using selenium webdriver in firefox 19?

I have used selenium 2.31. I have used Action class for mouse movement. Using this I moved the mouse over a menu and its submenu appeared only for a fraction of second unlike with older version of ...

1 2 3 4 5 6
15 30 50 per page