The wait is finally over, and the Selenium 4.0 Alpha release has been launched.

The wonderful comments from Simon Mavi Stewart about Selenium 4.0 alpha release as below:

The Selenium team has not yet announced it, but Selenium 4 Alpha is available to download at the MVN Repository. The below dependency should be added to pom.xml to get the alpha version.

From the word Alpha, we have come to know that there is a high chance it might not be stable enough. The current Selenium 4 is in an Alpha version, so it is not recommended to use for testing. We can start to use once it changes from Alpha to Beta.

Selenium 4 Alpha has undergone many significant changes, but it won’t impact your existing automation scripts.

 

Selenium 4.0 Alpha version Insights

 

  • The W3C recommendation document for Selenium WebDriver is now available. Click here for more information, which provides a crystal clear picture of how Selenium API’s are working.
  • Added driver.switchTo().parentFrame() method to switch directly to the parent frame.
  • Add pollTimeout argument to the wait() method. The default value is 200ms.
  • Replaced WebElement.getSize() and WebElement.getLocation() with a single method WebElement.getRect().
  • Basic support for using Docker containers with the new Grid Server.
  • Removed timeouts() method in driver.manage(). Suggest using getTimeouts() and setTimeouts() methods instead.
  • WebDriver implementation for Opera Browser is now removed. They are suggesting Opera users test on Chrome Browser to some extent.
  • Removed support for PhantomJS Headless mode. They are suggesting to use Chrome and Firefox Browsers in headless mode instead.
  • The Options class for every browser is now extending the Capabilities class.

 

Changes to Builder class
  • Added setChromeService, setEdgeService, & setFirefoxService
  • Removed setEnableNativeEvents
  • Removed setScrollBehavior
Changes to chrome.Driver
  • Added sendDevToolsCommand
  • Added setDownloadPath
Changes to firefox.Driver
  • Added installAddon(path)
  • Added uninstallAddon(id)
Changes to firefox.Options
  • Removed setLoggingPreferences (was a no-op)
  • setProfile now only accepts a path to an existing profile
  • Added addExtensions
  • Added setPreference
Changes to lib/webdriver.WebElement
  • Replaced getSize & getLocation with getRect
Changes to lib/webdriver.Alert
  • Removed authenticateAs
Changes to lib/webdriver.Options (driver.manage())
  • Removed timeouts (use get/setTimeouts)
Changes to lib/webdriver.Window (driver.manage().window()) Added

  • getRect
  • setRect
  • Fullscreen
  • minimize

Removed (use the getRect/setRect methods)

  • getPosition
  • setPosition
  • getSize
  • setSize

 

There are a lot of new changes coming up. Let’s stay tuned for further official updates from the Selenium team.

 

Reference:

https://github.com/SeleniumHQ/selenium/blob/master/javascript/node/selenium-webdriver/CHANGES.md
https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-remote-driver/4.0.0-alpha-1




Ready to Write an Interesting blog in QA Touch?


If you have an interesting blog post you would want to share with the Testing Community, please forward it to info@qatouch.com along with your picture and a short bio. Our editorial team will review and publish it.

Subscribe to our blog

Kannathasan

Kannathasan

Kannathasan is a Certified Tester (Foundation level ). He loves testing eCommerce applications and ferreting out hidden bugs. Likes solving challenging puzzles during his free time.

2
Leave a Reply

avatar
1 Comment threads
1 Thread replies
0 Followers
 
Most reacted comment
Hottest comment thread
2 Comment authors
KannathasanKalpana Recent comment authors
Kalpana
Guest
Kalpana

Very Good Blog.