Microsoft Edge Automation

In this blog post, I will try to go through the main issues that I faced trying to automate Microsoft Edge testing.

Microsoft Edge is a universal Windows application which targets device families instead of operating system, because of that application can easily run on different Windows devices and it doesn’t rely on OS as much as on the previous version of Windows. This is advantageous if you are a user who has several windows devices, on the hand, it makes it difficult to automate browser testing.

Since WebDriver is an emerging W3C standard, Microsoft obviously had to release the Selenium web driver version for Edge browsers. Microsoft developers admitted that they completely forgot about web driver, so it was a “last second” release. As things stand we will have to wait for a future release to have to have the final version of web driver, which will inevitably lead to dependency issues, since temporary versions will need to be updated.

IE Performance issues and Microsoft Edge

Microsoft Edge inherited performance issues from Internet Explorer. According to Microsoft,  the reason why the current IE driver is slow is that of an incompatibility with the computer architecture. If you are using the 32-bit Selenium driver against the machine which is 64 bit and you are launching a 64 bit IE browser you’ll see the performance issues. However even if you have everything perfectly set up, IE browser and the web drive will still have some performance issues. Microsoft edge is not that much different, it has a similar performance issue. Once again, we will need to wait for future releases before we see performance improvements.

Universal Application Cons

Since Microsoft is trying to make Edge a universal application, it still (as an older version) doesn’t have an inbuilt user profiling system, which is quite complicated, since web driver relies on this feature a lot. In order to configure the browser currently you can’t just set up a user profile as you are able to do with Chrome or Firefox, most of the settings are unreachable using IE Edge which is a huge disadvantage. No control over cookies, certificate warnings, pop out windows and other settings make it more complicated than it should be. The reason why is it like that right now is because Microsoft Edge is using Windows profile rather than the online browser profile. However, this feature may come in the future.

Problems with launch

Since browser automation doesn’t only end with Selenium web driver, I had to try some other tools like BRJS (which allows browsers to be configured and launched for testing). Universal Windows application requires a certain configuration of the device to be passed in order to be launched. That means that you can’t just simply launch the browser by double-clicking an executable file. It’s definitely not the end of the world since you can force the launch with a shell script so a quick cmd file can solve the problem, in addition, it’s also possible to create your own executable which launches the browser using the same shell command or invokes the process. The real issues arise when trying to terminate the browser after the execution of the test. Since you are not launching the script directly by executing a shell script, you have no control over it after the launch. Writing your own executable could help since the same executable would have the ability to kill the process after the execution, but this is a whole new topic. So in addition to the issues that Microsoft Edge carried from Internet Explorer, we now need to add launching and termination problems.

All in all, as things stand, Edge browser makes things very tricky for testing compared to Internet Explorer and other browsers. It continues to have the same performance and profiling issues that IE had. In addition, incoming Edge versions will only be compatible with the specific Edge driver, which will cause dependency issues. Also, let’s not forget the difficulty launching and killing the browser. Microsoft Edge development team promised to counter some of the issues so let’s hope that it will be better in the future.