Skip to Content
0

while automation using selenium, popup are not recognized

Dec 27, 2016 at 11:38 AM

42

avatar image

I am trying to automate application using Selenium, at runtime popup are not recognized and hence i am unable to identify objects inside the pop up.

Each time the script fails with error element not found.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Sharon Keane
Jan 09, 2017 at 11:05 AM
0

Hi, I've been testing SapUI5 with selenium and I switch to pop ups using the following:

driver.switchTo().frame("contentAreaFrame");

driver.switchTo().frame("isolatedWorkArea");

I needed both lines to switch into one pop up. I used the selenium ide tool on firefox to get the frame names. Hopefully this helps.

I also used:

for (String winHandle : driver.getWindowHandles()) { driver.switchTo().window(winHandle);}

// switch focus of WebDriver to the next found window handle (that's your newly opened window)

Share
10 |10000 characters needed characters left characters exceeded