New Features in Selenium 4

 The Selenium 4 WebDriver will be completely W3C Standardized. For example, it’s used heavily in mobile testing through tools such as Appium and iOS Driver. The W3C standard will encourage compatibility across different software implementations of the WebDriver API.

Let’s take an example of how Selenium Grid communicates with Driver executables as of now –

Adopting New Protocol

A test in Selenium 3.x, on the local end (through JSON wire protocol) communicates with the browser at the End node. This requires encoding and decoding of the API. In Selenium 4, the test will directly communicate without any encoding and decoding of API requests (through the W3C Protocol), though Java bindings will be backward-compatible, but focusing more on the W3C Protocol. The JSON wire protocol will no longer be used.

Selenium 4 IDE TNG

Selenium IDE support for Chrome is in the bucket. As we all know, Selenium IDE is a record and playback tool. It will now be available with much richer and more advanced features, such as

  • New plugin system – Any browser vendor will now be able to easily plug in to the new Selenium IDE. You can have your own locator strategy and plug in the Selenium IDE.
  • New CLI runner – It will be completely based on node.js, not the old HTML-based runner. It will have the following capabilities:WebDriver Playback – The new Selenium IDE runner will be completely based on WebDriver.Parallel execution — The new CLI runner will also support parallel test case execution and will provide useful information like time taken and number of test cases passed/failed.

Improved Selenium Grid

Those who have worked with Selenium Grid know how difficult it is to set up and configure. Selenium Grid supports test case execution on different browsers, operating systems, and machines, providing parallel execution capability.

There are two main elements in Selenium Grid: Hub and Node.

Hub acts as a server, a central point to control all the test machines in a network. In Selenium Grid, there is only one hub, which allocates test execution to a particular node based on capability matches.

Node is a test machine where test cases actually run.

The typical process to set up Selenium Grid has caused testers sometimes to face difficulty in connecting the node to the hub.

In Selenium 4, the Grid experience is going to be easy and smooth. There will not be any need to set up and start the hub and node separately. Once we start Selenium Server, the Grid will act as both hub and node.

Selenium 4 will come up with a more stable Selenium Grid in terms of removing all thread-safety bugs, and better support for Docker.

Better Selenium Grid UI

Selenium 4 will come with a more user-friendly UI for Grid, with relevant information about sessions running, capacity, etc.

Observability, logging, and debugging are no longer confined to DevOps in recent times. As part of this release, request tracing and logging with hooks will be improved so as to provide automation engineers a hold on debugging.

Thank you for reading!

If you liked this answer, please upvote and follow me

If you found it useful please share with others

Don’t agree or didn’t like it? Shoot me a comment! I’m sure there’s a room for improvement.

Comments

Popular posts from this blog

Common Selenium C# Exceptions and Fixes

Introduction to Visual Testing

Mobile App Testing & Tools