App自动化
sl01224318
这个作者很懒,什么都没留下…
展开
-
xpath的contains使用方法
示例: 1、xpath('//div[contains(@class,"test1") and contains(@class,"test2")]') #它会取class含有有test1和test2的元素 2、xpath('//div[contains(@class,"test1") or contains(@class,"test2")]') #它会取class 含有 test1 或者test2满足时,或者同时满足时的元素 3、//divt[contains(@name,'zhangsan')] 查找原创 2021-11-28 11:56:31 · 6005 阅读 · 0 评论 -
ADB常用命令使用
背景 Android调试桥(adb)是一种功能多样的命令行工具,使用adb可以与设备进行调试、通信,执行各种设备操作(例如安装和调试应用),并提供对 Unix shell(可用来在设备上运行各种命令)的访问权限。 在日常的App测试中,我们也会使用到adb进行设备和apk安装包的调试、安装,通过abd命令的使用,也会大大提高测试、开发效率。 常用命令 1、显示查看设备 adb devices 这个命令是查看当前连接的设备,此时连接到计算机的真机或者模拟器将会显示出来...原创 2021-11-28 11:40:43 · 2516 阅读 · 0 评论 -
Failed to start an Appium session, err was: Error: Requested a new session but one was in progress
问题: 在使用Appiun进行真机调试启动时遇到该错误,这个报错意思是之前的会话没有关闭,然后又运行了用例,会话没有重新覆盖。 解决方法: 1、重启Appium,关闭Appium后重新启动 2、每次运行测试用例后,在用例后面加一个driver.quit(),这样就可以关闭上次的会话,下次用例重新运行的话,就会新建一个会话。 ...原创 2021-11-21 13:58:31 · 535 阅读 · 0 评论 -
INSTALL_FAILED_ALREADY_EXISTS: Attempt to re-install io.appium.settings without first uninstalling
问题: 在使用Appium进行App自动化测试时,使用真机并且启动Appium时,遇到Appium启动失败,失败原因为“error: Failed to start an Appium session, err was:INSTALL_FAILED_ALREADY_EXISTS: Attempt to re-install io.appium.settings without first uninstalling”。 原因: 这个错误的原因是 Appium 在执行脚本之前安装了 2 个移动应用程序即“原创 2021-11-13 13:46:36 · 1145 阅读 · 0 评论 -
Command failed: C:\Windows\system32\cmd.e...adb.exe -s 16fcb2be shell “ps ‘uiautomat解决方法
问题 最近在安装使用Appium进行App自动化测试时,运行Appium时报了这样一个错误“Command failed: C:\Windows\system32\cmd.e...adb.exe -s 16fcb2be shell "ps 'uiautomat”,检查了安装环境发现是没有错误的,后来百度后解决了该问题,先将解决方法分享给大家。 解决方法 1、找到appium的安装目录下的adb.js文件,目录为:Appium\node_modules\appium\node_modul...原创 2021-11-13 13:29:54 · 463 阅读 · 0 评论