There doesn't appear to be a way to access the latest HTTP Response? I've had to create a REGEXP extractor as a bean postprocessor to HTTP requests in order to store the LAST_RESPONSE then extract it from the vars as needs be?
I feel like I've missed something fundamental along the line wrt to the context/scope of the response...
I understand it's a load testing tool but I've found it to be fairly useful for automation jobs as well.
thanks, Mark.
According to the How to Extract Data From Files With JMeter you might want to add ^
character to represent line start so regular expression would look like:
(?s)(^.*)
If you want to go the Beanshell PostProcessor you can achieve the same with the following code:
vars.put("LAST_RESPONSE", new String(data));
where:
vars
- shortcut to JMeterVariables class instance which gives read/write access to all JMeter Variables in scopedata
- byte array which contains parent sampler responseIn both cases you will get ${LAST_RESPONSE}
JMeter Variable which will be holding parent sampler response data.