当前位置:网站首页>JMeter interface test tool foundation - use badboy to record JMeter script
JMeter interface test tool foundation - use badboy to record JMeter script
2022-06-24 10:29:00 【Test - Eight Precepts】
1、 Use Badboy Recording JMeter Script
open Badboy Tool starts script recording :
(1) When we open Badboy Tool time , By default, it will enter the recording state .
Here's the picture :

Of course, we can also click the record button to switch .
(2) Enter the tested address in the address bar , And access .
Let's take Jingdong as an example :
Enter the Jingdong website in the input field , Click on the little arrow behind , Jump to the address under test .

When you click the arrow , Record one step operation ( It's like creating a sampler ), And display the content of the tested web address in the right view , Here's the picture :

(3) You can directly manipulate the displayed content in the view .
It's the same as we usually visit websites , for example : I click “ Please login. ”, Will jump to the landing page of Jingdong .
At the same time, a step will continue to be added to the script tree .

(4) Stop recording scripts .
If a test process is finished recording , We can click stop recording .
Just click on the little red dot in the toolbar , Here's the picture :

(5) Save recorded script file .
Click on File —> Export to JMeter..., Save the script file to the location you need , Easy to manage ,
(JMeter The default format of the file is .jmx)
(6) stay JMeter Open the script file you just saved in
Click on the file —> open , Find the script file you just saved and open it , Here's the picture :

(7) Add listener
Use Badboy Recorded JMeter Script , They don't have a monitor . Here we need to add a listener manually , Easy to see results .

(8) stay JMeter Start the script in
Click the green start arrow in the toolbar to run the script .
After the script runs , Can be in " Look at the fruit tree " View the results of all requests and responses in the test plan in .

2、 Use Badboy Parametric configuration
Badboy To facilitate automated data flexibility , Provides the function of script parameterization .
There is no input operation in the above example , If I visit Baidu , You need to enter some search keyword information , At this time, you need to configure parametrically .
(1) open Badboy Tools , By default, it will enter the recording state .
(2) Enter the tested address in the address bar , And access .
for example : Visit Jingdong website , Search for the product you need .

(3) Enter search keywords in Baidu search bar “ mobile phone ”, And click search .

Click on the search .

(4) Click the stop recording button , And start to modify .
Expand the script tree added by the previous search product :

Two changes are needed :
1)、 If the input keyword information appears garbled .
Badboy Default to use the system of IE browser , In case of garbled code , take ie Attribute utf8 Change it to gbk. for example , Jingdong website ie The attribute is enc attribute .
double-click enc attribute ( Right click on the attribute and select Properties Options can be ), Make changes in the pop-up window , Here's the picture :

(GBK It can be in both case )
Be careful : What is the default browser on your computer , Just replace it with the corresponding code .
2)、 Configure the input parameter information
for example : On the Jingdong page ,keyword Attributes are keyword information .
Defining variables
double-click keyword attribute ( Right click on the attribute and select Properties Options can be ), modify Value The attribute is ${ Custom variable name }, Click ok .

Then start to configure the parameter information of the variable :

here keyword The value of the property , Has been parameterized .
(5) double-click Step 1, Make changes For each value of vari The value defined by each variable shall prevail ( That is, using parameterization ).

At this point, look at the changes in the script tree .

(6) Save script , And use JMeter Open the script , Can run .
It can also be in Badboy in , Right click on the Test 1 —> Play Whole Test, Execute the recorded script , Check the execution effect .
3、 solve “ There is an error in the script of the current page ” Prompt box
Badboy When you record the script , Always pop up the following pop-up box prompt “ There is an error in the script of the current page ”.

open Badboy —> preferences —> Click on playing —> Check Javascript Error Dialogs, And then again Badboy Just tools .

Check “JavaScript Error Dialogs”, It means automatic processing / Inhibition JavaScript Error dialog .
summary
All of these are Badboy The most basic usage , There are also many functions to learn in the future 、 Accumulate slowly .
a key : Supporting learning materials and video teaching
So here I have carefully prepared the detailed information of the above outline in The link below is as follows


边栏推荐
- np.float32()
- SF Technology Smart logistics Campus Technology Challenge (June 19, 2022) [AK]
- 线程的 sleep() 方法与 wait() 方法的区别
- Role of message queuing
- Flink checkPoint和SavePoint
- 百度网盘下载一直请求中问题解决
- Flink cluster construction and enterprise level yarn cluster construction
- Troubleshooting steps for Oracle pool connection request timeout
- SSM integration
- 126. 单词接龙 II BFS
猜你喜欢

记录一下MySql update会锁定哪些范围的数据

SQL Server AVG function rounding

解决Deprecated: Methods with the same name as their class will not be constructors in报错方案

Uniapp develops wechat official account, and the drop-down box selects the first one in the list by default

283.移动零

2022 the most complete and detailed JMeter interface test tutorial and detailed interface test process in the whole network - JMeter test plan component (thread < user >)

Flink集群搭建以及企业级yarn集群搭建

分布式系统你必须了解的点-CAP

charles抓包工具使用教程

Machine learning - principal component analysis (PCA)
随机推荐
uniapp 开发微信公众号,下拉框默认选中列表第一个
使用swiper左右轮播切换时,Swiper Animate的动画失效,怎么解决?
leetCode-223: 矩形面积
6. package management business development
[IEEE publication] 2022 International Conference on industrial automation, robotics and Control Engineering (iarce 2022)
1.项目环境搭建
2022 International Symposium on intelligent robots and systems (isoirs 2022)
自定义kindeditor编辑器的工具栏,items即去除不必要的工具栏或者保留部分工具栏
Difference between package type and basic type
Hill sorting graphic explanation + code implementation
Safety and food security for teachers and students of the trapped Yingxi middle school
np.float32()
The difference between the sleep () method and the wait () method of a thread
CVPR 2022 oral | NVIDIA proposes an efficient visual transformer network a-vit with adaptive token. The calculation of unimportant tokens can be stopped in advance
包装类型的缓存机制
International Symposium on energy and environmental engineering in 2022 (coeee 2022)
26.删除有序数组的重复项
线程池的执行流程
牛客-TOP101-BM29
SQL Server AVG函数取整问题