
| Key: |
WTR-206
|
| Type: |
Bug
|
| Status: |
Open
|
| Priority: |
Minor
|
| Assignee: |
Unassigned
|
| Reporter: |
Rafael
|
| Votes: |
0
|
| Watchers: |
0
|
|
If you were logged in you would be able to see more operations.
|
|
|
Watir
Created: 01/May/08 11:22 AM
Updated: 28/Oct/08 05:16 PM
|
|
| Component/s: |
None
|
| Affects Version/s: |
1.5.4
|
| Fix Version/s: |
1.6.0
|
|
|
Original Estimate:
|
Unknown
|
Remaining Estimate:
|
Unknown
|
Time Spent:
|
Unknown
|
|
Environment:
|
Windows XP pro, IE 7.0
|
|
|
If several IE windows are open (>= 4) and IE.close_all is called, not all of them get closed (only 3 or so IE instances get closed - no exceptions thrown whatsoever). I tried having 8 IE windows open and had to call IE.close_all three times to be able to shut down all windows.
To reproduce:
- Open several IE windows manually (8 is a good number).
- Open irb and require 'watir' (or instead launch watir-console from DOS)
- Execute Watir::IE.close_all
- Note that not all of the windows get closed even though the command returns a successful completion.
|
|
Description
|
If several IE windows are open (>= 4) and IE.close_all is called, not all of them get closed (only 3 or so IE instances get closed - no exceptions thrown whatsoever). I tried having 8 IE windows open and had to call IE.close_all three times to be able to shut down all windows.
To reproduce:
- Open several IE windows manually (8 is a good number).
- Open irb and require 'watir' (or instead launch watir-console from DOS)
- Execute Watir::IE.close_all
- Note that not all of the windows get closed even though the command returns a successful completion.
|
Show » |
|
to Bret Pettichord <bret@pettichord.com>
date Fri, May 2, 2008 at 10:56 AM
subject RE: IE.close_all
Ok so I did some debugging on this. The culprit is close_modal in close_all.rb.
If you comment out line 16 in close_all.rb (which is a call to ie.close_modal), all IE windows close as expected when you call IE.close_all.
I didn't do any debugging within close_modal itself, but I found out this is the culprit while fiddling around with adding logs to IE.each and close_all:
1. The first thing I tried was to see if IE.each was actually reading all the IE windows in the stack. I noticed that if I commented out "yield id" within IE.each (ie.rb file), all IE windows were recognized, but if I left that line uncommented, then not all the IE windows would be recognized.
2. Then I commented out ie.close_modal in close_all.rb/Watir::IE#self.close_all_but and noticed that all of the IE windows in the stack were being logged even with yield id (in ie.rb/Watir::IE#self.each) uncommented out.
3. Then I just got rid of all my log statements and modifications to ie.rb and close_all.rb and just commented out close_modal (line 16 in close_all.rb) and reran the test and all the IE windows were all closed.
Seems like close_modal is messing up with IE.each for some reason. If have more time, I'll do some more debugging. Hope this helps in the meantime,
R.