2

I have created a list of lists in jsr223 preprocessor and want to run a loop for size of list and print the elements in list in post processor inside the loop. But i am unable to use the count variable in loop controller. enter image description here

enter image description here

enter image description here

The end result i need is in first iteration of loop [1,2,3,4,5] second iteration [6,7,8,9,10]

at present im getting no output because loop controller is not reading count variable.

1 Answer 1

3

JSR223 PreProcessor is being executed before request so by the time your Loop Controller is being kicked off your count variable is not initialized yet.

Convert JSR223 PreProcessor into a JSR223 Sampler and your code should start working as expected.

If you don't want JSR223 Sampler to appear in your test results add the next line to your script:

SampleResult.setIgnore()
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.