【发布时间】:2020-06-18 21:35:54
【问题描述】:
我正在为 Android 进行自动化操作,对于一些测试,我需要从代码中禁用/启用位置服务。 我试过这样的命令:
adb shell settings put secure location_providers_allowed -gps
adb shell settings put secure location_mode 0
但在 Android 7...9 上似乎没有任何工作。
有没有办法在一个命令中做到这一点?
谢谢
【问题讨论】:
标签: android automation gps adb adb-shell