I am using Firefox 11 + WebDriver 2.21.0 / WebDriver 2.22.0 (tried both).
In my scenario, when I click on a tab, it opens a confirmation window and when you click OK starts downloading a new tab from the server.
So, I view this scenario as:
driver.findElement(By.id("myTab")).click(); driver.switchTo().alert().accept();
but after he clicks on "mytab", he waits for the window to load indefinitely. This way it does not alert.accept() , and the browser waits to confirm the confirmation dialog to load a new page, so I got into a deadlock state.
This code works well in Internet Explorer.
Please help, how to deal with the situation?
java mozilla webdriver alert
Akarsh
source share