(转载)测试工具monkey
2013-12-23 22:48
246 查看
转自http://www.418log.org/post-32.html
1)进入shell
在桌面点开始--运行 输入cmd 点确定 或打开 cmd.exe 进入sdk tools目录如:
查看本机已经启动的模拟器
进入shell命令行
adb shell
后显示为# 如果显示为$ 输入su
exit 退出
在 adb shell 命令前运行 adb remount
(2)进入shell后
ls
cd data
下面还有个data,进入后下面是程序的包
可以直接输入monkey -p com.jd.customer -v 50,后会自动切换界面
也可以退出shell,在命令行输入,
adb shell monkey -p com.jd.customer -v 50 --hprof 生成报告
.hprof 文件会自动保存在SD卡上,然后把.hprof 文件拷贝到PC上的
\ android-sdk-windows\tools目录下。
这个由DDMS生成的文件不能直接在MAT打开,需要转换。运行cmd打开命令行,
cd到\ android-sdk-windows\tools所在目录,并输入命令
hprof-conv xxxxx.hprof yyyyy.hprof,其中xxxxx.hprof为原始文件,
yyyyy.hprof为转换过后的文件。
转换过后的文件自动放在android-sdk-windows\tools 目录下。
OK,到此为止,.hprof文件处理完毕,可以用来分析内存泄露情况了。
1)进入shell
在桌面点开始--运行 输入cmd 点确定 或打开 cmd.exe 进入sdk tools目录如:
1 | C:\Users\Administrator>d: |
2 | C:\Users\Administrator>cd D:\Program Files\android-sdk\platform-tools> |
1 | D:\Program Files\android-sdk\platform-tools>adb devices |
2 | List of devices attached |
3 | emulator- 5554 device |
adb shell
后显示为# 如果显示为$ 输入su
exit 退出
在 adb shell 命令前运行 adb remount
(2)进入shell后
ls
cd data
下面还有个data,进入后下面是程序的包
可以直接输入monkey -p com.jd.customer -v 50,后会自动切换界面
也可以退出shell,在命令行输入,
adb shell monkey -p com.jd.customer -v 50 --hprof 生成报告
.hprof 文件会自动保存在SD卡上,然后把.hprof 文件拷贝到PC上的
\ android-sdk-windows\tools目录下。
这个由DDMS生成的文件不能直接在MAT打开,需要转换。运行cmd打开命令行,
cd到\ android-sdk-windows\tools所在目录,并输入命令
hprof-conv xxxxx.hprof yyyyy.hprof,其中xxxxx.hprof为原始文件,
yyyyy.hprof为转换过后的文件。
转换过后的文件自动放在android-sdk-windows\tools 目录下。
OK,到此为止,.hprof文件处理完毕,可以用来分析内存泄露情况了。
相关文章推荐
- [转载]测试工具之FoneMonkey安装
- 转载_Linux平台代码覆盖率测试工具GCOV的前端工具LCOV简介
- Android APP压力测试(一) 之Monkey工具介绍
- Android 测试 Appium、Robotium、monkey等框架或者工具对比
- Android 4.3 Monkey自动化测试工具被killed的原因分析
- android的测试工具CTS(转载)
- Android自动化测试工具——Monkey
- Android 测试工具Monkey & Monkeyrunner 使用方法
- 10款常用Java测试工具[转载]
- 【金阳光测试】--深入Monkey工具和使用--Android系列(3)2014年八月八号
- 转载 - 5个在线的网站测试和验证工具
- monkey测试工具的使用
- android 自动化测试工具 Monkey
- 转载一个很经典的--C# Socket TCP和UDP报文及端口测试工具的开发(提供源码)
- zz:Android 测试工具Monkey & Monkeyrunner 使用方法
- (转载)Web网站的性能测试工具