Add New keyword "Drag And Drop To Frame" by b-vamsipunnam · Pull Request #1953 · robotframework/SeleniumLibrary

This PR adds a new keyword Drag And Drop To Frame that reliably handles dragging an element from default content to a target inside an iframe.

Background of the issue:

  • Faced this challenge with the Salesforce Service Cloud application while trying to automate the post-deployment manual steps in the setup page. After implementing this keyword, I successfully automated post-deployment manual steps. Saved a significant amount of time and effort for the overall release time for every release.
  • Navigation in SFDC: login --> Setup --> All sites --> builder --> Select Dashboard and drag and drop to the Target Section (Existing two drag and drop keywords are failing due to the target being inside the iframe)--> publish --> Confirm publish
  • The built-in 'Drag And Drop' keyword fails across iframe boundaries due to context switch mid-action (long-standing issue Drag and drop across iframe bounds is problematic #120).
  • Related discussion in Relative Locators, iFrames, ShadowDom, RTL .. oh my! #1813 about iframe handling enhancements.

Changes:

  • Implemented in - src/SeleniumLibrary/keywords/element.py
  • Added acceptance tests in - atest/acceptance/keywords/draganddropframe.robot
  • Test HTML page in - atest/resources/html/frames/draganddrop.html
  • updated the unit test file keyword count to 183 - utest/test/api/test_plugins.py

All acceptance tests pass locally (including new ones).

This is a non-trivial enhancement — please add the acknowledge label to #120 for release notes credit. Thank you!