July 2019
Intermediate to advanced
536 pages
12h 57m
English
This is an overloaded version of the release() method. Using this, you can actually release the currently held WebElement in the middle of another WebElement. In this way, we don't have to calculate the offset of the target WebElement from the held WebElement.
The API syntax is as follows:
public Actions release(WebElement onElement)
The input parameter for the preceding method is obviously the target WebElement, where the held WebElement should be dropped. The return type is the instance of the Actions class.
Let's modify the preceding code example to use this method:
@Testpublic void shouldClickAndHoldAndReleaseOnElement() { driver.get("http://guidebook.seleniumacademy.com/Sortable.html"); WebElement ...
Read now
Unlock full access