def read_screen_heirarchy():
''' Read the XML string of the device's GUI and return it '''
sModuleInfo = inspect.stack()[0][3] + " : " + inspect.getmoduleinfo(__file__).name
CommonUtil.ExecLog(sModuleInfo,"Function Start", 0)
try:
data = appium_driver.page_source # Read screen and get xml formatted text
CommonUtil.ExecLog(sModuleInfo,"Read screen heirarchy successfully",1)
if data:
return data
else:
return False
except Exception:
CommonUtil.ExecLog(sModuleInfo,"Read screen heirarchy unsuccessfully",3)
return False
BuiltInFunctions.py 文件源码
python
阅读 25
收藏 0
点赞 0
评论 0
评论列表
文章目录