|
Patch which handles page-transitions within nested IFrames. Submitted by Steven Haberman. Hi, I've contracted on two straight projects in a row that use iframes heavily. Basically, I had to make a copy of SelfRemovingLoadListener and make one Thanks, In implementing support for multi-frame (and potentially multi-window) apps, I propose we refactor the Selenium UI, separating it into one top-level window for Selenium suite, test, controls (and log?), and another for the AUT. Selenium Core now provides the capability to test multi-window or multi-framed applications. |
|||||||||||||||||||||||||||||||||||||
This patch adds some support for honouring the "target" attribute of a link in FireFox.
Index: selenium-browserbot.js
===================================================================
— selenium-browserbot.js (revision 417)
+++ selenium-browserbot.js (working copy)
@@ -549,7 +549,11 @@
if (needsProgrammaticClick && !preventDefault) {
// Try the element itself, as well as it's parent - this handles clicking images inside links.
if (element.href) {
+ if (element.target) { + this.currentWindow.frames[element.target].location.href = element.href; + } else { + this.currentWindow.location.href = element.href; + }
}
else if (element.parentNode.href) {
this.currentWindow.location.href = element.parentNode.href;