当我运行猴子跑步者时,我收到 swt 错误

发布于 2024-12-17 05:24:00 字数 793 浏览 0 评论 0原文

我创建了以下脚本并将其保存为 lib 文件夹中的 (test.mr) 并从命令提示符运行 C:\Android_Stuff\android-sdk-windows\tools\lib\monkeyrunner test.mr

@Importing monkeyrunner    
from com.android.monkeyrunner import MonkeyRunner, MonkeyDevice

@waiting for the device connection
device = MonkeyRunner.waitForConnection()

@Installing my app.
device.installPackage('C:/Android_Stuff/android-sdk-windows/tools/lib/purchase.apk')

@starting my demo page
device.startActivity(component='com.mobilemoneynetwork.purchase/.demo')

@selecting the Menu Button.
device.press('KEYCODE_MENU','DOWN_AND_UP')

我得到

Unable to access jarfile ..\framework\archquery.jar
SWT folder '' does not exist.
Please set ANDROID_SWT to point to the folder containing swt.jar for your platform.

I have created the below script and saved it as (test.mr) in the lib folder and running from the command prompt C:\Android_Stuff\android-sdk-windows\tools\lib\monkeyrunner test.mr

@Importing monkeyrunner    
from com.android.monkeyrunner import MonkeyRunner, MonkeyDevice

@waiting for the device connection
device = MonkeyRunner.waitForConnection()

@Installing my app.
device.installPackage('C:/Android_Stuff/android-sdk-windows/tools/lib/purchase.apk')

@starting my demo page
device.startActivity(component='com.mobilemoneynetwork.purchase/.demo')

@selecting the Menu Button.
device.press('KEYCODE_MENU','DOWN_AND_UP')

I am getting

Unable to access jarfile ..\framework\archquery.jar
SWT folder '' does not exist.
Please set ANDROID_SWT to point to the folder containing swt.jar for your platform.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

挥剑断情 2024-12-24 05:24:00

在环境变量中设置 ANDROID_SWT 路径,它应该是“您的路径”​​\Android\Sdk\tools\lib\x86_64

Set ANDROID_SWT path in environment variable it should be "your path"\Android\Sdk\tools\lib\x86_64

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文