I have a jmeter test plan with if controller, I need to loop the same http request until the if condition become true. if role==3664v then continue otherwise repeat the same http request page
Asked
Active
Viewed 509 times
-1
-
seems like you are asking us to write the code for you. what have you tried ? Please post some code that we can help you with – Sapnesh Naik May 18 '17 at 10:29
-
not like that I am new in jmeter so I shorten the question to avoid complication. – Parthan P Vasu May 23 '17 at 04:27
1 Answers
0
I believe you should place your sampler under the While Controller and use the following condition (assumes __javaScript() function) :
${__javaScript("${role}" != "3664v",)}
You will need to extract this ${role}
variable from the HTTP Request sampler response using Regular Expression Extractor or any other matching Post Processor
Assuming this setup JMeter will loop the HTTP Request until ${role}
variable value is not equal to 3664v
. When the role
becomes 3664v
it will continue.
See Using the While Controller in JMeter for more detailed information on implementing the "while loop" concept in JMeter tests.

Dmitri T
- 159,985
- 5
- 83
- 133