1.设置代理。浏览器-》设置-》系统和性能-》打开计算机的代理设置。 网络连接-》代理-》手动设置代理. ip: 127.0.0.1, port:8888
或者浏览器-》设置-网络设置-》手动设置代理: ip: 127.0.0.1, port:8888
2. add thread group and add a http cookie manager to it.
3. add HTTP(s) test script recorder, target controller chooses Test plan-> thread Group
4. click start. then open the browser and do the operations we want to record. After all steps, please click stop to stop button the recording.
5. IF we want to check the replay status, please add "summary report" under the thread group
6. click "start" button to replay the script then check result
7. 录制完脚本后需要删除掉多余的请求,只保留能完成该功能的最少请求。 如果不确定哪些请求是否有用,可以先disable它们,执行脚本。如果脚本能执行成功,就删掉这些disable的请求
8. 整理脚本,为请求修改名字(改成符合业务逻辑的名称,名称要简单明了且无歧义),然后为某些变量参数化以满足多用户并发的测试要求。
9. 添加报告,用于了解脚本执行结果及性能统计等