views:

140

answers:

1

Hi guys!

I have the following problem...

For a while now i noticed a bug in isElementPresent function in selenium RC 2.0a5.

It works only half of the time or so.

I have wait before it i have pageload before it and i made sure that the id is NOT dinamically generated. Still...

I do a waitForElementToAppear which is implemented using the Waiter in Selenium... http://release.seleniumhq.org/selenium-remote-control/0.9.0/doc/java/com/thoughtworks/selenium/Wait.html

And then when i'm trying to use the element OR doing an isElementPresent check... It sometimes fails to use that element although i do have a screenshot of it being there..

Also i tried using Thread.sleep to wait out. It sometimes works, sometimes not.

So do you guys encountered the same problem too?

thanks, Gergely.

A: 

Current Selenium RC version is 1.0.3. What you are using is a WebDriver remote server, so you shouldn't use it with your Selenium RC tests - stay on RC 1.0.3. Selenium Server 2.0a5 is for the RemoteWebDriver. And also 2.0a5 is Alpha release, so you should expect bugs

ZloiAdun
I'm using selenium-server-standalone-2.0a5. It has selenium rc bundled with in it. Also i do think it has the same one as in 2.0a4 not? Well, however... I will try your approche. :) Thanks!
Hannibal
It seems that it helped with the issue of isElementPresent. What i'm now facing is that sometimes it does not kill firefox. And when i look at the server in the morning i see at least a dozen or so windows open.I'm guessing that the tearDown is not executed but i'm not sure..Anyways. Thanks! :)
Hannibal
The Selenium 2.0 releases contain a fully backwards-compatible implementation of Selenium 1.x. In fact, they're a shared source tree. The "alpha" flag is related to the changing API for Selenium 2 and does not reflect the quality of the underlying implementation. So, in short, 2.0a5 should work just fine and if not, that's a bug that should be reported so it can be fixed.
nirvdrum