
| Key: |
SEL-166
|
| Type: |
Bug
|
| Status: |
Open
|
| Priority: |
Major
|
| Assignee: |
Unassigned
|
| Reporter: |
Aslak Hellesoy
|
| Votes: |
0
|
| Watchers: |
0
|
|
If you were logged in you would be able to see more operations.
|
|
|
Selenium
Created: 12/Dec/05 08:17 AM
Updated: 16/Oct/06 02:19 AM
|
|
| Component/s: |
Pop-Up Windows
|
| Affects Version/s: |
0.6
|
| Fix Version/s: |
None
|
|
|
Original Estimate:
|
Unknown
|
Remaining Estimate:
|
Unknown
|
Time Spent:
|
Unknown
|
|
|
If a popup issues a post followed by a redirect, the this.recordPageLoad callback function will get called _after_ the popup is closed, and there will be no 'current' window.
The attached patch fixes this problem
|
|
Description
|
If a popup issues a post followed by a redirect, the this.recordPageLoad callback function will get called _after_ the popup is closed, and there will be no 'current' window.
The attached patch fixes this problem
|
Show » |
|
Index: selenium-browserbot.js
===================================================================
--- selenium-browserbot.js (revision 1919)
+++ selenium-browserbot.js (working copy)
@@ -58,7 +58,13 @@
var self = this;
this.recordPageLoad = function() {
- LOG.debug("Page load detected, location=" + self.getCurrentWindow().location);
+ LOG.debug("Page load detected");
+ // If a popup issues a post followed by a redirect, this callback
+ // function will get called _after_ the popup is closed, and there
+ // will be no 'current' window.
+ if(self.getCurrentWindow()) {
+ LOG.debug("location=" + self.getCurrentWindow().location);
+ }
self.currentPage = null;
self.newPageLoaded = true;
};
@@ -238,7 +244,7 @@
targetWindow = eval(evalString);
}
if (!targetWindow) {
- throw new SeleniumError("Window does not exist");
+ //throw new SeleniumError("Window does not exist:" + windowName);
}
return targetWindow;
};