Selenium Webdriver Tutorials

How to perform Selenium Drag and Drop? Using Actions

Selenium Drag and Drop is one of the common scenarios in Automation testing. Let’s say we have a web application where we need to drag an item from one location to another location. These kinds of complex actions are not available in basic element properties. Thankfully Selenium WebDriver has Advanced User Interactions API (Actions class) to perform this kind of advanced user interactions for rich applications.

Selenium Webdriver Tutorials

Double click event in Selenium Webdriver using Actions class

In earlier post, we learnt how to replicate (or automate) keyboard and mouse actions in Selenium Webdriver. Selenium Webdriver provides an Advanced User Interaction API (including Actions class) which facilitate user actions to be performed in an application, i.e. users can use this API to simulate keyboard and mouse actions in Selenium Webdriver. In this tutorial we will see how to simulate Double click event in Selenium Webdriver using Actions class.

Selenium Webdriver Tutorials

Keyboard and Mouse Actions in Selenium Webdriver

What are the common ways you interact with an application? Yeah! The keyboard and mouse. Almost everything we perform in an application is via keyboard or a mouse – click, double-click, type, drag, mouse hover, right-click, etc. So here comes an obvious question for automation testing – How do you replicate (or automate) keyboard and mouse actions in Selenium Webdriver? As you might have guessed, every automation tool provides a way to script keyboard and mouse events. Selenium Webdriver provides an Advanced User Interaction API (including Actions class) which facilitate user actions to be performed in an application, i.e. users can use this API to simulate keyboard and mouse actions in Selenium Webdriver.