selenium

xpath locator works in FF3, but won't work in IE7

After switching from firefox testing to internet explorer testing, some elements couldn't be found by selenium anymore. i tracked down one locator: xpath=(//a[@class='someclass'])[2] While it works as it should under firefox, it could not find this element in ie. What alternatives do i have now? JS DOM? CSS Selector? How would this l...

There is any Macro Recorder for Web Page fetching automation?

Selenium HQ records some web navigation and can replay it from Firefox. I want a similar thing, but it must have an API. ** UPDATE ** It turns out that Selenium has an API, but I will keep the question since there are alternatives. My objective is to fetch a web page periodically and save its contents to a database. The web content is...

Counting number of elements matching a CSS Selector

How can I count the number of elements that match my CSS selector?? I am trying to use SeleniumRC to test my GWT App and am trying to match elements using CSS selectors. I want to count the number of enabled Buttons in the following HTML. A button is enabled if it is under a td with class="x-panel-btn-td " and disabled if it is unde...

Run UI SeleniumRC tests as a part of CI process

I'm trying to setup CI environment for QA department. They use SeleniumRC to run UI tests in IE and FF browsers to test some web application. I had a success configuring it to run as a windows service as described here. However when i run the test it hangs. I can see iexplore.exe process spawned by Selenium service in the process list bu...

Visual Studio Web Test vs. Selenium

This can be a very opinionated question. Please keeps your posts factual. What are the pros and cons of using Microsoft Web Test in Visual Studio? Conversely, what are the pros and cons of Selenium? ...

Does Selenium RC support IE8?

Can anyone confirm if Selenium RC server fully supports IE8? ...

is it possible to read something.properties using javascript ? (in a .hta file) >> to read in Selenium

I am using Selenium to do testing, We write our test cases in html files and make test suites out of them, our requirement is to write test cases that are robust enough to change themselves as per the test environments. for this, I prefer not to enclose specifications such as urls to open, text to search for on screen, etc in the html s...

How to submit form in loop in Selenium IDE

I'm using Selenium IDE in Firefox and submiting a form. The problem is that the form can be sucesfull or unsuccesfull (random). When it's unsuccesfull it will show and error message (AJAX) and I need to try to submit the form again. I would like to write a test which will be submiting the form until it will redirect me to success page (...

Why does document.evaluate succeed in Firebug but fail in Selenium?

browser.getEval function in selenium makes iterateNext return null ..Otherwise in firebug it returns a value(same script) document.evaluate("//button[text()='Save']", document, null, XPathResult.ANY_TYPE, null) .iterateNext() .disabled; returns tr...

(Selenium) How to test whether a download of a certain file was started?

I want to test whether a certain action results in a file download (a) at all, and (b) with the file having a certain name. Is there any way to use Selenium to do this? ...

Is there a way to LOG RC Selenium test errors/failures into a database?

Im using phpunit & phpundercontrol to run the RC Selenium on every build. ...

Python Selenium handling Timeout Exceptions with a long list of URLs

Hi, I am using selenium RC to cycle through a long list of URLs, sequentially writing the HTML from each URL to a csv file. Problem: the program frequently exits at various points in list due to URL "Timed out after 30000ms" exceptions. Instead of stopping the program when it hits a URL time-out, I was trying to have the program simply ...

Typing enter/return key in selenium

Looking for a quick way to type an enter or return key in Selenium. Unfortunately the form I'm trying to test (not my own code so I can't modify) doesn't have a submit button. When working with it manually, I just type enter or return, and just need to know how to do that with the Selenium "type" command ...

Selenium.SeleniumException: ERROR: Command execution failure.

Please search the forum at http://clearspace.openqa.org for error details from the log window. The error message is: Permission denied I am getting error when i am trying to execute Selenium.IsElementPresent(ticketLocator) Help me!! ...

how to CREATE only 1 session with rc server when running PHPUnit selense html files?

My website has a Login page, so it needs to login first to run each html selense test file. The way PHPUnit framework works is creating independent test cases by running each test independently, which means it calls the Setup() function on each test case --> then calls Selenium RC Server--> then creates session id. My Code is below: req...

trouble executing Selenium python unittests in C# with ScriptEngine (.NET 3.5)

Hello all, first time poster. I'm turning to my first question on stack overflow because I've found little resources in trying to find an answer. I'm looking to execute Selenium python tests from a C# application. I don't want to have to compile the C# Selenium tests each time; I want to take advantage of IronPython scripting for dyna...

Selenium: Dynamic buttons and classes?

So, I was trying out a test case on a website and Selenium registers the events perfectly. Now, if I have to search for a particular class and get the innerHTML of that class, how would I do it assuming that I am using Java as the driving language? Just to be more clear. I have a class like this: <h1 class="classname">.....</h1> I...

Descendent Relations + Indexing in Selenium

Hello! I'm testing a web page using selenium. I want to get all the 'leaf elements and elements which contain text'. I use the following working XPath. //*[. != '' or not(*)] This works great. But now I want to loop through each of these elements and run some command on them. I actually want to get their Position, but I illustrate ...

Selenium RC: How to click link appears in grid??

I'm using Selenium RC and created all scripts in java (Using Junit test case) I want to click one grid column having "Edit" link. My code is look like, selenium.click("//table[@id='ctl00_POMSContentPlaceHolder_gvBillingCompany']//tr["+gRow+"]//td["+gCol+"]"); gRow and gCol are defined as integers and their values vary as moving to n...

Selenium RC: how to capture/handle error?

Hi, My test uses Selenium to loop through a CSV list of URLs via an HTTP proxy (working script below). As I watch the script run I can see about 10% of the calls produce "Proxy error: 502" ("Bad_Gateway"); however, the errors are not captured by my catch-all "except Exception" clause -- ie: instead of writing 'error' in the appropriate r...