How to put a variable in a Jmeter Beanshell function
772
I have a problem with JMeter's Beanshell and it is that I want to put it inside a function that I call but the problem is that it can't detect it instead if I put a number if:
And the error:
Someone who can help me since I've been looking and there isn't much information on the internet.
In your Beanshell preprocessor use
vars.put("randomNumSum",Integer.toString(Integer.valueOf(num)+2));instead ofvars.put("randomNumSum",(Integer.valueOf(num)+2));
For more information about beanshell, you can go to the following link:
In your Beanshell preprocessor use
vars.put("randomNumSum",Integer.toString(Integer.valueOf(num)+2));
instead ofvars.put("randomNumSum",(Integer.valueOf(num)+2));
For more information about beanshell, you can go to the following link:
Complex logic test with beanshell