Appium执行adb指令

1. appium需要执行adb指令,官网描述

How To Execute Shell Commands On The Remote Device
It is possible to execute any command on the remote Android device or an emulator under test and get the output from it. This action might be potentially insecure and is disabled on the server side by default. One must provide the --relaxed-security command line argument while starting the server in order to enable remote shell commands execution (and other insecure features, which are disabled by default). An exception will be thrown if the relaxed security has not been enabled on the server side and one tries to invoke mobile: shell endpoint on the client side

2. 所以我们只需要在启动appium服务的时候执行:appium --relaxed-security就可以在程序中实行adb指令了

你可能感兴趣的:(Appium执行adb指令)