当前位置:网站首页>How to use [jmeter regular expression extractor] to solve the problem of returning the value as a parameter
How to use [jmeter regular expression extractor] to solve the problem of returning the value as a parameter
2022-08-10 08:33:00 【software testing】
Table of Contents
Add regular expression extractor step:
Foreword
When we use jmeter for interface testing, we often encounter that the return value of the previous interface will be used as the parameter of the next interface to request.At this time, you need to use jmeter's regular expression extractor.
Add regular expressionExtractor steps:
"Right click on the interface to add the extractor"——add——post processors——regular expression extractor, the specific operation is as follows:

After adding, the configuration is as follows:

Then the next interface call:

Description:
(1) Reference name: The name of the parameter to be referenced in the next request, such as filling in cid, you can use ${cid} to reference it.
(2) Regular expression:
(): The enclosed part is to be extracted.
.: Matches any string.
+: One or more times.
?: Don't be too greedy, stop after the first match is found.
(3) Template: refer to it with $$. If there are multiple regular expressions in the regular expression, it can be $2$$3$, etc., which means the parsed value is given to the title.For example: $1$ represents the first value parsed
(4) Matching numbers: 0 means random value, 1 means all values, usually fill in 0
(5) Default value: If the parameter does not get a value, it will default to a value and let it take it.
One last tip:
Results can be viewed in the result tree and the Debug PostProcessor during debugging to help analyze the results.
Conclusion
This post ends here. Finally, I hope that friends who read this post can gain something.If you want to take testing as a long-term career development goal, you need to keep learning and make yourself competitive. No matter how many years you work now, as long as you take action, you will already have an advantage.I wish everyone a promotion and salary increase in 2022. Those who have not joined the company will get the offer of their favorite company as soon as possible, and everything will go smoothly.
Welcome to leave a message, or follow my column to communicate with me.
边栏推荐
- 编程老手如何在autojs和冰狐智能辅助之间选择?
- PTA Exercise 2.2 Rotate an Array Left
- Rust学习:6.2_复合类型之元组
- 详解构建mock服务最方便的神器——Moco
- Class Notes (7) (1) - #647. Find the root and the child (root)
- 【 WeChat applet 】 read page navigation
- J9 Number Theory: Macro Analysis of DAO Characteristics
- [OAuth2] 20. OAuth2 Extended Protocol PKCE
- JS reduce
- Using the color picker
猜你喜欢

CV+Deep Learning——网络架构Pytorch复现系列——classification(三:MobileNet,ShuffleNet)

【NeRF】原始论文解读

PHP笔记 28 29 30 31

day16--抓包工具Charles的使用

Linux下载安装MySql

颜色选择器的使用

Spotify expresses its architectural design using the C4 model

The implementation of the seemingly useless component (text gradient) in NaiveUI is so simple

进程管理(动态的)

Solve the problem that the win10win7win8 system cannot find the specified module and cannot register the desert plug-in
随机推荐
PTA 习题2.1 简单计算器
qrcode-----生成二维码
NPU architecture and force analysis
mySQL add, delete, modify and check advanced
nrm 使用详解
Rust learning: 6.1_Slices of composite types
90. (cesium house) cesium height monitoring events
本地生活商家如何通过短视频赛道,提升销量曝光量?
速卖通卖家如何抓住产品搜索权重
占位占位1
大佬们,请问一下,oraclecdc报错没有序列化,可是我看源码中的确是没有继承序列化的,是什么原因
VS2013-debug assembly code-generate asm file-structure memory layout-function parameter stack-calling convention
组合数模板
怎么使用【jmeter正则表达式提取器】解决返回值作参数的问题
It is obvious that a unique index is added, why does it still generate duplicate data?
Rust学习:6.3_复合类型之元组
J9数字论:Web3.0+互联网电商会引起怎样的火花?
MySQL的用户临时表与内部临时表
[深入研究4G/5G/6G专题-56]: L3信令控制-5-无线承载管理
DGIOT 30 million meters set pressure reading