JMeter treating "${COOKIE_[cookiename]}" as a string -


i have looked @ numerous examples of setting properties cookies, , seem indicate using beanshell postprocessor, should able following, given cookie named 'foo'.

props.put( "foocookie", "${cookie_foo}" ); 

however, when try write value console, see here...

print( props.get( "foocookie" ) ); 

... value string ${cookie_foo} if dollar/curly bracket notation not being parsed.

i feel must missing painfully obvious here, after several hours of fighting this, bringing experts. advice appreciated.

edit: adding bit more detail. layout of test plan

test plan     user defined variables     http cookie manager     http request defaults     login thread (setup)         [page request - login post]             http header manager             beanshell postprocessor         [more page requests] 

and indeed have cookiemanager.save.cookies=true set in jmeter.bat file launching with.

do have http cookie manager in test plan? if not, need have that. need set cookiemanager.save.cookies=true in jmeter.properties file can find in jmeter_home/bin folder.

${cookie_foo} return actual cookie value.


Comments

Popular posts from this blog

html - Styling progress bar with inline style -

java - Oracle Sql developer error: could not install some modules -

How to use autoclose brackets in Jupyter notebook? -