Handle AUT in top frame

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Handle AUT in top frame

GW-5
Hi

I have an AUT that contains code like the following:

if (window.self != window.top) {
      window.open(".", "_top");
}

The idea is that the AUT should never be inside a frameset. Of course, this construction breaks the Selenium tests as the AUT reloads itself outside the frameset. Does anyone have any suggestion on to handle this kind of situation?

Thanks!
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.openqa.org/thread.jspa?threadID=1876&messageID=5322#5322

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Handle AUT in top frame

Alexandre Garel

Vidar Kongsli a écrit :

> Hi
>
> I have an AUT that contains code like the following:
>
> if (window.self != window.top) {
>       window.open(".", "_top");
> }
>
> The idea is that the AUT should never be inside a frameset. Of course, this construction breaks the Selenium tests as the AUT reloads itself outside the frameset. Does anyone have any suggestion on to handle this kind of situation?
>  
A poor man solution may be :
- write a starting page which just open your app in a new window (my_app)
- use selectWindow my_app and go with the test
Hope it helps
Alex.






Ce message est protégé par les règles relatives au secret des correspondances. Il est donc établi à destination exclusive de son destinataire. Celui-ci peut donc contenir des informations confidentielles. La divulgation de ces informations est à ce titre rigoureusement interdite. Si vous avez reçu ce message par erreur, merci de le renvoyer à l'expéditeur dont l'adresse e-mail figure ci-dessus et de détruire le message ainsi que toute pièce jointe.

This message is protected by the secrecy of correspondence rules. Therefore, this message is intended solely for the attention of the addressee. This message may contain privileged or confidential information, as such the disclosure of these informations is strictly forbidden. If, by mistake, you have received this message, please return this message to the addressser whose e-mail address is written above and destroy this message and all files attached.

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]