I am using Edge web driver with robotframework (selenium2library) on windows 10 VM. When I run the test Edge browser is invoked test are getting executed too but somewhere in the middle (keywords: Wait until element is visible/wait until page contain element) I start getting the error "No Such Window Exception". There are no multiple windows but just a single window. Did someone face these kind of problem? This keyword is already being used for same page and it worked fore few tests but suddenly same page started to fail. It works fine on other browsers
Version Details:
Window 10: 10586.218
Edge Browser:25.10586.0.0
Edge WebDriver: Microsoft WebDriver Fall 2015 Update
The Edge WebDriver is not fully implemented. I appreciate you're essentially saying a keyword that works elsewhere is not working, however you're working with something that's in development:
https://developer.microsoft.com/en-us/microsoft-edge/platform/status/webdriver/details/
We made the call not to use this until it does become fully implemented; that might be something you should consider.
Related
I have about 130 Selenium UI tests for a web app we're currently developing.
The problem I have is, whenever I run the tests locally through Visual Studio's test explorer (vstest), I have never encountered this error before.
The problem is, some of the tests keep failing due to this message when the tests are run on TFS (using vstest on TFS too). element click intercepted
I'm also 100% sure there is no overlaying element that interferes with the click method as the tests never fail with that message when run locally.
Any idea what could this be?
I had issues where all of my local tests would pass, but I would receive random errors as you mentioned when running the tests through Jenkins or TFS, usually errors indicating that my elements were not clickable, etc. - the issue ended up being the browser size.
I started running my test in headless mode and specified a large browser size. Switching to --headless and setting a browser size ended up solving most of my issues for me:
var headlessOptions = new ChromeOptions();
headlessOptions.AddArgument("--headless");
headlessOptions.AddArguments("--disable-gpu");
headlessOptions.AddArguments("--window-size=1920,1200");
You will have to use --headless for this to work too. I tried to run my tests by ONLY setting window size, but the tests would still fail anyway because the resolution of the virtual machines was not large enough to handle the browser size I had set.
You can resolve this issue by using 2 methods.
1.Running chrome in headless mode
2.Scorlling to the element before clicking or interacting with it
The root cause of this issue is due to the fact that the browser does not load with a browser size as that of browser when tested locally
If you intend to run the test in non headless mode you can use the following code to achieve the result.
IWebElement element= driver.FindElement(By.Id(selector));
((IJavaScriptExecutor)driver).ExecuteScript("arguments[0].scrollIntoView(true);", element);
I just got updated to Windows 10 (x64). My old desktop had IE 11 but a lower version, as it was running Windows 7. I now have the following IE version:
Version: 11.648.17134.0
Update Versions: 11.0.115
I downloaded the latest IEDriverServer.exe that Selenium gave me (3.14). When I run it, when I do the get(url) (various urls), afterwards it fails to find elements. I looked and noticed that before the get(), driver.getWindowHandles() had one entry, but after the get() it had zero entries. This is the latest version. I tried setting compatibility mode but that did not do any good (set or not set). The tests will work fine with Chrome but someone else wrote the test and did not verify values were non-null before calling element.sendKeys(str), which IE appears to allow but Chrome throws an exception. And there are so many instances.
So, I need to find the correct IEDriverServer for my Windows 10 IE but I am having trouble doing so. Google did not give me much except it led me to the driver I already downloaded.
Can anyone help?
As a thumb-rule you can always use the released IEDriverServer from the respective released Selenium clients.
As an example,
If you are using Selenium v3.14
Download, extract and use IEDriverServer_Win32_3.14.0.zip or IEDriverServer_x64_3.14.0.zip
Snapshot:
Update
However to work with IE11 you have to take care of a couple of things which are beyond the scope of this discussion and are as follows:
How does the registry entry HKEY_LOCAL_MACHINE\…\FEATURE_BFCACHE for InternetExplorerDriver solves the Internet Explorer 11 issue?
Internet Explorer Protective mode setting and Zoom levels
Selenium InternetExplorerDriver doesn't get focus on the window
How to ignore protected Mode Settings for Internet Explorer using setCapability() through Selenium and Java?
I have a question regarding Selenium and the current Microsoft updates:
I just installed the newest Microsoft patches on a PC and now the Selenium scripts won't work anymore. I'm using the Selenium IE Driver 2.44.0 in the scripts. Maybe something has changed in the Internet Explorer, I'm not sure. Suddenly the scripts can't find any web elements on the page anymore. An InvalidSelectorException is thrown because the findElements methods can't be executed. The IE driver opens up and it navigates to the given URL, but when it tries to find a web element, the script fails. I also tried it out on a PC which hasn't the newest updates installed yet and the scripts are working fine there, there are no problems at all.
Do you have any ideas what to do or what could be the cause?
Thanks a lot!
Yes as I stated here
If you have taken windows update KB3025390 IE will not work as expected. There is currently no resolution to that yet.
Also, Uninstalling the update KB3025390 should make the WebDriver work correctly with Internet Explorer 11. See this answer
I am trying to inspect the page during an integration test, and so I have a test which I added a breakpoint in-- Once chrome launches and the test begins, the breakpoint hits, and the browser is idle.. As soon as I open the web inspector, chrome quits with the error:
Selenium::WebDriver::Error::WebDriverError:
disconnected: received Inspector.detached event
I am using Chrome version 37.0.2062.124, and ChromeDriver version 2.10.267517
This is intended. This is because the ChromeDriver uses the DevTools API to interact with Chrome.
The DevTools within Chrome has one major disadvantage and that is it only allows one debugger (whatever that might be, whether it's you or the driver itself) attached to it. Thus, once you open it, ChromeDriver cannot use it.
This is a limitation of Chrome -> the best you can do is get your test to a point where it fails, have your test close it's session but leave the browser open. Thus you have quit your test but effectively left your browser in the state of which the test failed.
This is about chrome issue(https://bugs.chromium.org/p/chromedriver/issues/detail?id=1194).
When you are running selenium program, you cannot press F12 to open dev tools manually, or it'll throw this exception sometimes.
According to the issue list, it looks like fixed, but I still meet this bug in ChromeDriver 2.29
The same problem you can visit.
I have a local selenium server (2.42.2) running with Chromedriver and Firefox. It seems to get stuck after loading and running client.html. I can see that my functional suite code runs in node, far enough to execute the main body. Anything in registerSuite never gets called.
Here are the selenium logs:
http://pastebin.com/KKg5ycvW
I can see the browsers in the selenium sessions page, but they don't appear to be doing anything.
Try opening up a new browser window and paste in the url that you see in the existing selenium ones. Then open up dev tools and see what console errors you are getting.
Intern's runner seems to get stuck in an infinite loop if any uncaught javascript errors are thrown during unit tests if the 'reporter' hasn't been setup yet.
This has been raised as an issue in intern's github repository.