I fixed it! Guess what?

<voice size="tiny"> it was my fault </voice>

Bret Pettichord wrote:

> > Maybe everyone has more handles than me.

> Can you tell me how i would be able to tell that Watir was having handle
> problems? How would i measure how many handles are being used so that i
> could tell whether a particular change fixed this problem or not?

Because I frequently flick between applications, my first sign is
usually the <Alt+Tab>.

So the only metric I'm currently inspired to measure is how long I can
productively work without symptoms.

The problem was my test file had another test suite, where I used
WIN32OLE to create my own Internet Explorer object. Then I leaked it.
Apparently this one little leak was enough to bring down my 'puter in
only a few test runs.

> Earlier you said that you had a "wait" problem and were thus using
> Watir_Simple because it managed it for you. Watir_Simple was written for
> Watir 1.0 and included some additional calls to wait that were missing
> in the core Watir software back then. But i have been under the strong
> impression that these are all redundant with Watir 1.4.

I currently create and destroy one browser per test case, using your
IE.new_process.

(Gotta love how close Ruby brings the 'new' concept to the "object
factory" concept, huh?!)

Because I'm testing AJAX pages, if I used one IE for the whole suite,
tests would frequently discover the state of the previous test.

I will put a navigate('about:blank') in the teardown, switch to one IE
process, and see if the result is more stable.

Ultimately, unless WIN32OLE has a bug, I think all these problems
belong to Microsoft. We are using IE Automation for the exact purpose
MS created and promoted it, and we are using in the exactly way they
tell us to. If my lowly $ie handle goes away, the COM ref-count should
go to zero, the IE browser should garbage-collect itself, and all the
resources should free!

-- 
  Phlip
  http://c2.com/cgi/wiki?ZeekLand  <-- NOT a blog!!
_______________________________________________
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Reply via email to