【问题标题】:How to test Android Application;s UI using Monkey如何使用 Monkey 测试 Android 应用程序的 UI
【发布时间】:2012-04-05 08:03:58
【问题描述】:

我正在尝试使用 Monkey 测试我的 Android 应用。他们说使用这个命令,

$ adb shell monkey -p your.package.name -v 500

在我的应用程序中,我的包名是 travelceylon\client,所以如果我给出的命令是:

adb -e shell monkey -p travelceylon\client -v 1000

...它会显示如下错误:

:Monkey: seed=0 count=1000
:AllowPackage: travelceylonclient
:IncludeCategory: android.intent.category.LAUNCHER
:IncludeCategory: android.intent.category.MONKEY
** No activities found to run, monkey aborted.

那么我在这里做错了什么?

【问题讨论】:

  • 你确定你的包名拼写正确吗?

标签: android stress-testing monkey


【解决方案1】:

你应该用点分隔你的包名部分:

adb -e shell monkey -p travelceylon.client -v 1000

正如您在错误中看到的,它省略了包名中的\

AllowPackage: travelceylonclient :IncludeCategory: 
                          ^ ???

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-04-17
    • 2012-03-15
    • 1970-01-01
    • 2016-07-10
    • 1970-01-01
    相关资源
    最近更新 更多