Hi all,
I am trying to get my Watir scripts running under IronRuby, but am
encountering the following error:
:0:in `require'': no such file to load -- dl (LoadError)
from C:/ironruby-0.9.0/lib/ruby/1.8/dl/import.rb:3
from ./watir/winClicker.rb:53
from ./watir.rb:42
Any help gratefully appreciated!
--
Posted via http://www.ruby-forum.com/.
Doesn''t watir use C-based extensions. In that case they have to be ported to .NET in order to use it. --- Met vriendelijke groeten - Best regards - Salutations Ivan Porto Carrero Blog: http://flanders.co.nz Twitter: http://twitter.com/casualjim Author of IronRuby in Action (http://manning.com/carrero) On Thu, Aug 20, 2009 at 1:01 PM, Qwerty Qwerty <lists at ruby-forum.com> wrote:> Hi all, > > I am trying to get my Watir scripts running under IronRuby, but am > encountering the following error: > > :0:in `require'': no such file to load -- dl (LoadError) > from C:/ironruby-0.9.0/lib/ruby/1.8/dl/import.rb:3 > from ./watir/winClicker.rb:53 > from ./watir.rb:42 > > Any help gratefully appreciated! > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Ironruby-core mailing list > Ironruby-core at rubyforge.org > http://rubyforge.org/mailman/listinfo/ironruby-core >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20090820/c962f5e8/attachment.html>
I think it only uses dl/import for FireWatir (it uses a firefox hash plugin to
communicate); IE support should just depend on win32ole. Anyone want to dig into
what watir is using dl/import for?
~Jimmy
Sent from my phone
On Aug 20, 2009, at 4:14 AM, "Ivan Porto Carrero" <ivan at
flanders.co.nz<mailto:ivan at flanders.co.nz>> wrote:
Doesn''t watir use C-based extensions. In that case they have to be
ported to .NET in order to use it.
---
Met vriendelijke groeten - Best regards - Salutations
Ivan Porto Carrero
Blog: <http://flanders.co.nz> http://flanders.co.nz
Twitter: <http://twitter.com/casualjim> http://twitter.com/casualjim
Author of IronRuby in Action
(<http://manning.com/carrero>http://manning.com/carrero)
On Thu, Aug 20, 2009 at 1:01 PM, Qwerty Qwerty <<mailto:lists at
ruby-forum.com>lists at ruby-forum.com<mailto:lists at
ruby-forum.com>> wrote:
Hi all,
I am trying to get my Watir scripts running under IronRuby, but am
encountering the following error:
:0:in `require'': no such file to load -- dl (LoadError)
from C:/ironruby-0.9.0/lib/ruby/1.8/dl/import.rb:3
from ./watir/winClicker.rb:53
from ./watir.rb:42
Any help gratefully appreciated!
--
Posted via <http://www.ruby-forum.com/> http://www.ruby-forum.com/.
_______________________________________________
Ironruby-core mailing list
<mailto:Ironruby-core at rubyforge.org>Ironruby-core at
rubyforge.org<mailto:Ironruby-core at rubyforge.org>
<http://rubyforge.org/mailman/listinfo/ironruby-core>http://rubyforge.org/mailman/listinfo/ironruby-core
_______________________________________________
Ironruby-core mailing list
Ironruby-core at rubyforge.org<mailto:Ironruby-core at rubyforge.org>
http://rubyforge.org/mailman/listinfo/ironruby-core
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://rubyforge.org/pipermail/ironruby-core/attachments/20090820/27b7d619/attachment.html>
Ok, so after hacking watir.rb, I managed to get IE to open and navigate
to the URL, but then using the following basic script:
require ''watir'' # use watir gem
test_site = ''http://www.google.com'' # set a variable
b = Watir::IE.new # open the IE browser
b.goto(test_site) # load url, go to site
b.text_field(:name, "q").set("pickaxe") # load text
"pickaxe" into
search field named "q"
b.button(:name, "btnG").click # "btnG" is the
name of the
Search button, click it
if b.text.include?("Programming Ruby")
puts "Test Passed. Found the test string: ''Programming
Ruby''."
else
puts "Test Failed! Could not find: ''Programming
Ruby''"
end
I now get the following error:
./watir/element.rb:54:in `assert_exists'': Unable to locate element,
using :name, "q" (Watir::Exception::UnknownObjectException)
from ./watir/element.rb:288:in `enabled?''
from ./watir/element.rb:60:in `assert_enabled''
from ./watir/input_elements.rb:328:in `set''
from Simplewatirscript.rb:6
--
Posted via http://www.ruby-forum.com/.
The backtrace indicates that the exception was thrown from "set" which
would imply that the call to text_field succeeded. Could you break up the line
"b.text_field(:name, "q").set("pickaxe")" into two
statements to see narrow down where the problem might be happening?
Also, could you run with "ir.exe -D", attach with VS, and get the full
call stack for all the exceptions thrown by the problematic statement? There
might be other exceptions thrown before
Watir::Exception::UnknownObjectException, and the those other exceptions might
be more useful to track down the problem. One suspect could be that COM Interop
is misbehaving somehow.
Also, what was the patch to watir.rb (and what exact version of watir are you
using) so we could try to repro the problem?
-----Original Message-----
From: ironruby-core-bounces at rubyforge.org [mailto:ironruby-core-bounces at
rubyforge.org] On Behalf Of Qwerty Qwerty
Sent: Thursday, August 27, 2009 8:48 AM
To: ironruby-core at rubyforge.org
Subject: Re: [Ironruby-core] Watir under IronRuby Error
Ok, so after hacking watir.rb, I managed to get IE to open and navigate
to the URL, but then using the following basic script:
require ''watir'' # use watir gem
test_site = ''http://www.google.com'' # set a variable
b = Watir::IE.new # open the IE browser
b.goto(test_site) # load url, go to site
b.text_field(:name, "q").set("pickaxe") # load text
"pickaxe" into
search field named "q"
b.button(:name, "btnG").click # "btnG" is the
name of the
Search button, click it
if b.text.include?("Programming Ruby")
puts "Test Passed. Found the test string: ''Programming
Ruby''."
else
puts "Test Failed! Could not find: ''Programming
Ruby''"
end
I now get the following error:
./watir/element.rb:54:in `assert_exists'': Unable to locate element,
using :name, "q" (Watir::Exception::UnknownObjectException)
from ./watir/element.rb:288:in `enabled?''
from ./watir/element.rb:60:in `assert_enabled''
from ./watir/input_elements.rb:328:in `set''
from Simplewatirscript.rb:6
--
Posted via http://www.ruby-forum.com/.
_______________________________________________
Ironruby-core mailing list
Ironruby-core at rubyforge.org
http://rubyforge.org/mailman/listinfo/ironruby-core