如何在robot框架中执行adb connect命令?

问题描述 投票:0回答:1

有什么方法可以在机器人框架中执行这些命令行吗?


adb -s ### 杀死服务器

adb -s ### 启动服务器

adb 连接###

adb -s ### 卸载 io.appium.uiautomator2.server

adb -s ### 卸载 io.appium.uiautomator2.server.test


(###显示设备名称)

机器人框架  Python

图书馆:AppiumLibrary

Appium版本:1.21.0

运行 appium 的桌面操作系统版本:mac 13.6

设备:Galaxy Watch 5

我在执行Android设备测试时遇到了一些错误,我发现这些命令行可以解决问题。但是,每次发生错误时我都必须手动键入这些命令行。 如果有某种方法可以自动解决这个问题,我想知道。

python command-line appium adb robotframework
1个回答
0
投票

https://robotframework.org/robotframework/latest/libraries/Process.html#Run%20Process 允许您运行任何命令,因此您可以运行

adb
as

${result} = Run Process adb -s ### kill-server
最新问题
© www.soinside.com 2019 - 2024. All rights reserved.