Open GoogleCodeExporter opened 9 years ago
Original comment by samu...@chromium.org
on 21 Feb 2015 at 12:18
I am not able to reproduce the problem . Code is as follows:-
WebDriver driver = new ChromeDriver();
driver.get("http://google.com/");
Actions actions = new Actions(driver);
WebElement nextButton =
driver.findElement(By.linkText("Images")); Thread.sleep(3000);
actions.keyDown(Keys.CONTROL).click(nextButton).keyUp(Keys.CONTROL).build().perform();
Set <String> wins = driver.getWindowHandles();
Iterator <String> itr = wins.iterator();
String parentwin = itr.next();
String childwin = itr.next();
driver.switchTo().window(childwin);
driver.close(); // closes the 2nd window
driver.getCurrentUrl();
It throws correct error -
org.openqa.selenium.NoSuchWindowException: no such window: target window already closed
Please let me know if it differs from what you are doing
Original comment by gmanikp...@chromium.org
on 2 Mar 2015 at 10:49
Original comment by gmanikp...@chromium.org
on 30 Mar 2015 at 9:39
Original issue reported on code.google.com by
titusfor...@gmail.com
on 16 Oct 2014 at 1:22