Hello, As per: http://jmeter.apache.org/usermanual/component_reference.html#postprocessors
PostProcessors are ran before assertions that's why you're facing this issue. An option is to use a BeanShell PreProcessor in the next sampler and test for "JMeterThread.last_sample_ok" variable which JMeter sets. Besides, you should switch to JSR223 + Groovy instead of Beanshell for performance and maintainability. Regards @ubikloadpack On Thu, Jan 12, 2017 at 4:40 AM, Marcelo Jara <[email protected]> wrote: > I have a response assertion which looks for an error code in the response > data. When found the sampler is correctly marked a failure. I then have a > Beanshell post processor which looks to see if the previous sampler was an > error (!prev.isSuccessfull()). This is not working because the response for > isSuccessfull() is coming back as true even though the sampler failed due > to the assertion. Is there another way in Beanshell to check for the > failure? > > > Thanks, > > > MJ > > -- Regards Ubik Load Pack <http://ubikloadpack.com> Team Follow us on Twitter <http://twitter.com/ubikloadpack> Cordialement L'équipe Ubik Load Pack <http://ubikloadpack.com> Suivez-nous sur Twitter <http://twitter.com/ubikloadpack>
