
需要的东西:
#手机
#WiFi
#jemter 3.0(下载地址:http://jmeter.apache.org/)

1.找到你安装的文件夹,找到bin文件夹,运行jemter.bat.打开jemter。
**“测试计划”添加线程组(测试计划---添加----线程组)

**“工作台”中添加“HTTP代理服务器”(工作台---添加---非测试原件---http代理服务器)
其中,端口:随意设置;ip:电脑的ip,如下图设置

(PS:不知道自己电脑IP的打开cmd,输入ipconfig)

2.手机WiFi设置代理:
长按WiFi,选择“修改网络”
“代理”---选择“手动”;
“代理服务器主机名”---“192.168.0.145”
“代理服务器端口”----“8888”

3.手机连接刚才配置的wifi;
4.HTTP代理服务器--点击“启动”按钮,启动HTTP代理服务器;

5.启动手机上需要测试的APP,进行业务操作;这个时候可以看到线程组抓到app上发出的请求了
9、业务操作完毕,立即停止jemter上的“HTTP代理服务器”,否则一直抓包,线程组中会有很多无用的请求;
10、在“线程组”删除无关的请求;
11、保存jmx脚本;
12、添加察看结果树;
12、回放。
网友评论