selectWindow extension

description

extend the original selectWindow to select a nested frame and a window which name is null.

target: the window or frame that you want choice,and you can only use '.' as the window name to select the previous opened window.

example of use

select nested frame in the current window:

selectWindow parentFrame|childFrame  
verifyTitle this child frame  

you can use the window URL as the opened window flag if the window name is null,you nust including '.' in you command target field.And if the command target only including a '.' character,then selenium will choice the previous opened window,use it can solve some test URLs are including a random variable.

select window which window name is null and the URL is './tests/test1.html'.

selectWindow ./tests/test1.html  

Only select the previous opened window.

selectWindow .  

selectFrame(null) means returning control back to myiframe

notes

  • download the selenium-browserbot.js to replace original file in selenium directory.

download

Get it from Attachment directory

Labels

support support Delete
nested nested Delete
frame frame Delete
and and Delete
select select Delete
a a Delete
window window Delete
with with Delete
name name Delete
is is Delete
null null Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.