Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-07 Thread Rodrigo Julian Martin
Hello Bret, ie.down_load_time is a Watir 1.5 feature, right? Im afraid I still have to use the 1.4.1 release (because of WET compatibility for example). Is there a way I could manage this with 1.4.1? My code is like this: [code] $browser.links.each do |link|

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-07 Thread Daniel Browne
If you knew of some text that was always present in the html of a loaded page, but not present when one of the error pages is displayed you could use: ie.html.match(/some_text_that_is_always_present/) I imagine there is a better way to do it though. Cheers, Daniel. On 07/06/06, Rodrigo

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-07 Thread Bret Pettichord
On 6/7/06, Rodrigo Julian Martin [EMAIL PROTECTED] wrote: Hello Bret, ie.down_load_time is a Watir 1.5 feature, right?No. It's been in Watir for a long time. It is in 1.4.1. Well, I need a way of check that each link that was clicked have loaded "completely" a page, else I need to

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-02 Thread Praveen Kumar Kammitta
) -- Message: 1 Date: Thu, 1 Jun 2006 17:22:41 -0300 From: Rodrigo Julian Martin [EMAIL PROTECTED] Subject: Re: [Wtr-general] [question] Setting timeout for a ie.wait method? To: wtr-general@rubyforge.org Message-ID: [EMAIL PROTECTED] Content-Type: text

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-01 Thread Chris McMahon
I'm doing this because I need to test if a page has been loaded correctly after clicking a link, maybe there's a easier form of checking this.. def wait_for_page(seconds) begin @ie.link(:text,My Incredibly Important Link).click do_the_next_thing_method rescue sleep 1

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-01 Thread Bret Pettichord
On 6/1/06, Rodrigo Julian Martin [EMAIL PROTECTED] wrote: I was wondering if there's a way of setting the timeout parameter for the .wait method… I mean, let's say that a page doesn't load in 10 seconds. Could I trap that the .wait method failed after 10 seconds in order to log that?

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-01 Thread Chris McMahon
P.S. I have my doubts about McMahon's suggestion. :) I'm doing something very similar to this in my current Watir scripts right now, except I haven't put in the max-retries logic yet. -Chris ___ Wtr-general mailing list Wtr-general@rubyforge.org

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-01 Thread Bret Pettichord
The problem is that link().click won't return until the page is loaded. Maybe you meant to use link().ole_object.click instead?BretOn 6/1/06, Chris McMahon [EMAIL PROTECTED] wrote: P.S. I have my doubts about McMahon's suggestion.:)I'm doing something very similar to this in my current Watir

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-01 Thread Chris McMahon
On 6/1/06, Bret Pettichord [EMAIL PROTECTED] wrote: The problem is that link().click won't return until the page is loaded. Maybe you meant to use link().ole_object.click instead? Ah, you're right, I misunderstood the original question. Rodrigo, in my case, I have interim pages that show

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-01 Thread John Castellucci
I had a similar requirement and addressed it by adding my methods to the Element class. This may not be the best solution, but it worked for me. module Watir class Element def click_wait(how_long = 30) wait_for(how_long) click end def wait_for(how_long=30)

Re: [Wtr-general] [question] Setting timeout for a ie.wait method?

2006-06-01 Thread Rodrigo Julian Martin
-general] [question] Setting timeout for a ie.wait method? The problem is that link().click won't return until the page is loaded. Maybe you meant to use link().ole_object.click instead? Bret On 6/1/06, Chris McMahon [EMAIL PROTECTED] wrote: P.S. I have my doubts about McMahon's suggestion