如何使用Jmeter中具有不同文本的响应断言来断言某些内容

时间:2022-03-04 13:23:31

I'm trying to make SOAP call in Jmeter and using Response assertion to validate the No Error in the response. It is failing all the time because each xml has different text b/w the tags. I see my response is in different string like this No Error & No error.

我正在尝试在Jmeter中进行SOAP调用,并使用Response断言来验证响应中的No Error。它总是失败,因为每个xml在标签上都有不同的文本。我看到我的响应是不同的字符串,如没有错误和没有错误。

Basically I want to assert that there are no errors by extracting No Error. Is there a way that I use some regular expression here regardless of what text is present in the response assertion?

基本上我想通过提取无错误断言没有错误。有没有办法在这里使用一些正则表达式而不管响应断言中有什么文本?

如何使用Jmeter中具有不同文本的响应断言来断言某些内容

Thanks

1 个解决方案

#1


Do you mean case insensitive response assertion?

你的意思是不区分大小写的响应断言吗?

(?i) ignore case

(?i)忽略大小写

Check this:

http://jmeter.apache.org/usermanual/component_reference.html#Response_Assertion

#1


Do you mean case insensitive response assertion?

你的意思是不区分大小写的响应断言吗?

(?i) ignore case

(?i)忽略大小写

Check this:

http://jmeter.apache.org/usermanual/component_reference.html#Response_Assertion