Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Frames issue using Watir-Webdriver and phantomjs

I'm writing test using Watir-Webdriver and phantomjs and I've got an issue with iframes. I'm trying to get an element with the following code:

browser.frame(:index => 0).div(:id, "wrapper").exists?

and when I'm using phantomjs, it raise an error:

NameError: uninitialized constant Watir::FramedDriver::UnknownFrameException

but when I'm using chrome driver, the code above works properly and returns "true" value.

Any ideas how can I fix it? Or maybe there is any other way to get this element using phantomjs? Any help will be appreciated. Thanks!

like image 840
corday Avatar asked Apr 21 '26 12:04

corday


1 Answers

My guess is that ghostdriver does not have support for frames. I could not find an open issue related to frames in it's bug tracker: https://github.com/detro/ghostdriver/issues If you think it is a bug in ghostdriver, you should report it there.

like image 77
Željko Filipin Avatar answered Apr 23 '26 18:04

Željko Filipin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!