Hi Everyone,
I am trying to build a watir script for a full testing of my web
application.
I must use Internet Explorer 8.
It run very well, but when im trying to getting a page with nested frames,
it fails like this:
1) Error when i try to get nested frame's elements by name's frame
...
$browser = Watir::IE.new
$browser.goto my_url
$browser.frame(:name,'frame_parent').frame(:name,'frame_child').link(:text=>'My
link').click()
*StackTrace:*
NoMethodError: unknown property or method: `documentelement'
HRESULT error code:0x80020006
Nombre desconocido.
from
D:/ruby/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classic-3.0.0/lib/watir-classic/page-container.rb:31:in
`method_missing'
from
D:/ruby/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classic-3.0.0/lib/watir-classic/page-container.rb:31:in
`page'
from
D:/ruby/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classic-3.0.0/lib/watir-classic/page-container.rb:55:in
`html'
from (irb):77
from D:/ruby/Ruby193/bin/irb:12:in `<main>'
2) Error when i try to get nested frame's elements by index's frame
...
$browser = Watir::IE.new
$browser.goto my_url
$browser.frame(:name,'frame_parent').frames[0].link(:text=>'My
link').click()
*StackTrace:*
Watir::Exception::FrameAccessDeniedException: IE will not allow access to
this frame for security reasons. You can work around this with
ie.goto(frame.src)
from
D:/ruby/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classic-3.0.0/lib/watir-classic/frame.rb:38:in
`document'
from
D:/ruby/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classic-3.0.0/lib/watir-classic/page-container.rb:31:in
`page'
from
D:/ruby/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classic-3.0.0/lib/watir-classic/page-container.rb:55:in
`html'
from (irb):78
from D:/ruby/Ruby193/bin/irb:12:in `<main>'
I can not use suggestions like " ... You can work around this with
ie.goto(frame.src) ... ", because my frame_parent has 3 frame childs and
all this frames comunicate by javascript. Working very with first frame
level ('parent_frame'), but error when getting second frame level
('frame_child').
All frames are in the same domain, in the same aplication, but even it
fails.
I have been minimized my web-browser security restrictions (Trusted Sites
Zone, enable frame scripts, activex privs,......an entire time bomb) but
doesn't wok.
Any help will be appreciated.
My current versions:
*Watir:*
watir (3.0.0)
watir-classic (3.0.0)
watir-webdriver (0.6.1)
*Ruby:*
ruby 1.9.3p194 (2012-04-20) [i386-mingw32]
Thank you,
JuanH
--
Before posting, please read http://watir.com/support. In short: search before
you ask, be nice.
[email protected]
http://groups.google.com/group/watir-general
[email protected]