def _drag_and_drop(self, source, **kwargs):
"""Send values to a particular element,
simulates typing into a element
:Arguments:
1. source = a valid WebElement
2. target = a valid WebElement
"""
status = True
print_info("Simulate a drag and drop")
try:
browser_instance = kwargs.get('browser')
target = self._get_element(browser_instance,
kwargs.get('target_locator'))
if source is not None and target is not None:
ActionChains(browser_instance).drag_and_drop(source,
target).perform()
except Exception as e:
print_error("An Exception Occurred {}".format(e))
status = False
return status
element_operations.py 文件源码
python
阅读 23
收藏 0
点赞 0
评论 0
评论列表
文章目录