Jmeter- Building a Web test plan(3)
2015-06-09 10:35
483 查看
6. Logging in to a web-site
It's not the case here, but some web-sites require you to login before permitting you to perform certain actions. In a web-browser, the login will be shown as a form for the user name and password, and a button to submit the form. The button generates a POST request, passing the values of the form items as parameters.
To do this in JMeter, add an HTTP Request, and set the method to POST. You will need to know the names of the fields used by the form, and the target page. These can be found out by inspecting the code of the login page. [If this is difficult to do, you can use the JMeter Proxy Recorder to record the login sequence.] Set the path to the target of the submit button. Click the Add button twice and enter the username and password details. Sometimes the login form contains additional hidden fields. These will need to be added as well.
It's not the case here, but some web-sites require you to login before permitting you to perform certain actions. In a web-browser, the login will be shown as a form for the user name and password, and a button to submit the form. The button generates a POST request, passing the values of the form items as parameters.
To do this in JMeter, add an HTTP Request, and set the method to POST. You will need to know the names of the fields used by the form, and the target page. These can be found out by inspecting the code of the login page. [If this is difficult to do, you can use the JMeter Proxy Recorder to record the login sequence.] Set the path to the target of the submit button. Click the Add button twice and enter the username and password details. Sometimes the login form contains additional hidden fields. These will need to be added as well.
相关文章推荐
- int、NSInteger、NSUInteger、NSNumber的区别和联系
- Ueeshop:外贸网站报价,从免费到数十万是怎么回事?
- 第六章:如何对druid.io做成平台化
- UIWindow & UIWindowLevel
- StringBuilder与StringBuffer的区别(转)
- 解决Incorrect string value错误
- iOS蓝牙--CoreBluetooth基本使用
- a questions
- UIImage 切图
- jsp中 response和request区别
- 【Java GUI】文本框和文本区
- Android Studio --> Gradle Build设置自动
- Adeneo Embedded: Building Qt 5.1 for Freescale i.MX6Introduction on LTIB
- Building QT5 for IMX6(all)
- hdu 4027 Can you answer these queries?(线段树)
- UILabel调整字间距
- UITextView的创建/背景图片/边框和颜色/圆角等
- 关于在openstack中创建实例时任务一直卡在Building的现象描述
- Java GUI 使用确认对话框控制循环
- Column count doesn't match value count at row 1解决方法