How to handle the window pop up

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

How to handle the window pop up

reema
Hi,

How to handle the pop up window? When i close an image it asks for a confirm action. it doesn't recognise the 'ok' button. I recorded a test the command i found was
selenium.click(id='closeImg'); after this the pop up appears asking for a confirmation. using firebug also i'm not able to handle the popup window?

I am new to selenium can anyone guide me on this?
Reply | Threaded
Open this post in threaded view
|

Re: How to handle the window pop up

softwaretestingforum
Administrator
If you are using Selenium RC then you can used -

selenium.getConfirmation()

or

selenium.getAlert()

depending on whether it is confirmation or alert and selenium will close it for you.
~ seleniumtests.com