Something I'd overlooked was to copy watir.rb. I grabbed 1.282 but still get the following when I run xpath_tests.rb
 
c:/ruby/lib/ruby/site_ruby/1.8/watir/camel_case.rb:5: undefined method `wait' for module `Watir::SupportsSubElements' (NameError)
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:4049
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from C:/Watir/unittests/../unittests/setup.rb:4
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from C:/Watir/unittests/xpath_tests.rb:4
-----Original Message-----
From: Brown, Christopher [mailto:[EMAIL PROTECTED]
Sent: Wednesday, February 22, 2006 8:36 AM
To: '[email protected]'
Subject: Re: [Wtr-general] xpath support doesn't work for me

Hi Angrez ,
 
I've done as suggested and moved Watir from C:\Program Files\Watir to C:\Watir but I still get the same errors.
 
Am I correct in thinking that the xpath stuff actually resides in the Ruby installation and that the xpath_tests.rb is attempting to use
 
Anyway, these are the failures I get when I run core_tests.rb before trying to install the xpath stuff:
 
  1) Failure:
test_http_errors(TC_Navigate) [C:/Watir/unittests/../unittests/navigate_test.rb:51]:
<Watir::Exception::NavigationException> exception expected but none was thrown.
 
  2) Failure:
test_links_and_images_in_table(TC_Tables) [C:/Watir/unittests/../unittests/table_test.rb:165]:
<"106"> expected but was
<"28">.
 
154 tests, 946 assertions, 2 failures, 0 errors
 
After this I've tried a few things:
1. copying the unittest files from the CVS tarball to the Watir installation directory without overwriting existing files
2. copying the unittest files from the CVS tarball to the Watir installation directory and overwriting existing files
 
Just thought, the versions of element.rb and fnctions.rb come from the tarball. If I get the files directly from the CVS repository and try some unit testing I get the following from core_tests.rb
 
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require__': nosuch file to load -- watir/dialog (LoadError)
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from C:/Watir/unittests/../unittests/dialog_test.rb:6
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from C:/Watir/unittests/core_tests.rb:7
        from C:/Watir/unittests/core_tests.rb:7
 
Just compared my Ruby installation with the watir contents in the tarball. Gonna copy the following to my Ruby installation: IEDialog folder, win32ole folder, datahandler.rb, dialog.rb, and tidy.dll. I now get 'The object invoked has disconnected from its clients.'!
 
I don't think I need the rexml folder since its already installed with the version of Ruby. Anyway, I've tried copying everything from th etarball to Ruby's watir directory and get
 
c:/ruby/lib/ruby/site_ruby/1.8/watir/camel_case.rb:5: undefined method `wait' for module `Watir::Container' (NameError)
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:3744
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from C:/Watir/unittests/../unittests/setup.rb:4
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:in `require'
        from C:/Watir/unittests/core_tests.rb:4
 
I don't know what else to try right now.
 
Thanks again for your time
 
Chris
-----Original Message-----
From: Angrez Singh [mailto:[EMAIL PROTECTED]
Sent: Wednesday, February 22, 2006 4:08 AM
To: [email protected]
Subject: Re: [Wtr-general] xpath support doesn't work for me

Hi Brown,

Some of the test cases don't work if you install Watir in a directory that contains space in their names. For e.g. c:\Program Files. Just try to install it in c:\watir & let me know if the test cases fails as well. The error you are getting is because IE gets close & scripts are still running. I don't know why this happens but the error "The object invoked has disconnected from its clients." comes only when you are using an IE instance that is not there.

Just try installing in some other directory that don't have space in its name & let me know if the test cases succeeded or not.

Regards,
Angrez

On 2/21/06, Brown, Christopher <[EMAIL PROTECTED]> wrote:
Okay,
 
I've installed Watir 1.4.1 then run install.rb from the tar bundle (bad move?). When I run xpath_tests.rb I get errors like the following
 
 87) Error:
test_textarea_field_exists(TC_TextArea_XPath):
WIN32OLERuntimeError: Unknown property or method `navigate'
    HRESULT error code:0x80010108
      The object invoked has disconnected from its clients.
    C:/Temp/watir/unittests/../watir.rb:1324:in `method_missing'
    C:/Temp/watir/unittests/../watir.rb:1324:in `goto'
    C:/Temp/watir/unittests/../unittests/textAreafields_xpath_test.rb:11:in `gotoPage'
    C:/Temp/watir/unittests/../unittests/textAreafields_xpath_test.rb:15:in `test_textarea_field_exists'
 
88 tests, 0 assertions, 0 failures, 87 errors
 
Regards
 
Chris
-----Original Message-----
From: Angrez Singh [mailto:[EMAIL PROTECTED]]
Sent: Monday, February 20, 2006 4:59 PM
To: [email protected]
Subject: Re: [Wtr-general] xpath support doesn't work for me

Hi Brown,

Anyway, when I run my test script I get the following error message

c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:1273:in `initialize': LoadLibrary:
c:\ruby\lib\ruby\site_ruby\1.8\watir\IEDialog\Release\IEDialog.dll
(RuntimeError)
        from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:1273:in `new'
        from c:/ruby/lib/ruby/site_ruby/1.8/watir.rb:1273
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__'
        from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require'
        from G:/workspace/web_pages/trial.rb:1

The error that you are getting has nothing to do with the XPath support. Could you please try to run the xpath unit tests provided with the TAR ball to make sure that XPath is working?

Regards,
Angrez


_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general


_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general

Reply via email to