当我运行猴子赛跑者时,我得到了swt错误

时间:2011-11-18 12:24:01

标签: monkeyrunner

我创建了以下脚本并将其保存为(test.mr)在lib文件夹中,并从命令提示符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.

1 个答案:

答案 0 :(得分:2)

在环境变量中设置ANDROID_SWT路径应该是"您的路径" \ Android \ Sdk \ tools \ lib \ x86_64