You might find a JSR223 Assertion easier to use; if that is placed
after any existing Assertions it should run after them.
However I have not tried this.

Alternatively, use the JSR223 Assertion to both check the condition
and do any further processing.

On 12 January 2017 at 08:04, UBIK LOAD PACK Support
<supp...@ubikloadpack.com> wrote:
> 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 <marceloj...@hotmail.com>
> 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>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@jmeter.apache.org
For additional commands, e-mail: user-h...@jmeter.apache.org

Reply via email to