Suppose there are two browsers, one is ie1, another is ie2, the separate browser. You may achieve it by: ie2.do_something ie2.close ie1.refresh ie1.wait ie1.do_something.
Thanks. Wesley Chen. 2009/3/24 Darin Duphorn <[email protected]> > > Brett, > > Within this synchronization, is there a way to handle issues where the > page doesn't fully load? (insert a page refresh after a certain time?) > > We have a situation where if a separate browser maybe opened in IE 7.0 > and the automation is running on the an active browser the page doesn't > fully load and the automation hangs. We have to click refresh the page > and then the automation continues. > > When I run a full regression, I do close all browsers before starting, > and I don't run it the issue, but when we build the test it can be a > pain. > > > Thanks, > > Darin > > > > -----Original Message----- > From: [email protected] > [mailto:[email protected]] On Behalf Of Bret Pettichord > Sent: Tuesday, March 24, 2009 10:04 AM > To: [email protected] > Subject: [wtr-general] Re: Synchronization Points > > > Watir has built in synchronization. Most Watir methods will not return > until the page has finished loading. This is invisible and automatic and > > handles 95% of the synchronization needs of Web Apps. > > When Watir was first released, there were browser drivers in several > different languages. The most popular was Samie, in Perl. But Watir was > the first to include this automatic synchronization mechanism. I suspect > > that this was key to its success. Because it is invisible and automatic, > > most people don't give it much thought. > > A little history lesson for you. > > Bret > > > [email protected] wrote: > > In comercial tools, like QuickTest Pro, there are API for > > synchronization points. > > You may wait for a certain time while the page is downloded before > > performing any operations on it. > > The API ranges from simple wait() to more sophisticated functions > > waiting for specific object properties. > > > > Do we have analogs for synchronization points in Watir? > > Do we need to create a loop checking if the web page contains some > > text to guarantee it downloaded? > > > > So far I did not insert any synchronization points in the scripts and > > everything worked fine. > > > > > > > > -- > Bret Pettichord > CTO, WatirCraft LLC, www.watircraft.com > Lead Developer, Watir, www.watir.com > Blog, www.io.com/~wazmo/blog <http://www.io.com/%7Ewazmo/blog> > Twitter, www.twitter.com/bpettichord > > Watir Training: Austin March 25-26, Portland/Beaverton April 16-17 > www.watircraft.com/training > > > > > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Watir General" group. To post to this group, send email to [email protected] Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/watir-general -~----------~----~----~----~------~----~------~--~---
