For some reason, Post-Processors are run in reverse order.

This has been fixed in the current code in SVN.

Meanwhile, try swapping them round.

On 13/06/07, Knut Borchart <[EMAIL PROTECTED]> wrote:
Hi,

i was able to use a beanshell post-processor to clean the response:

String sampleResult = new String(prev.getResponseData());
String temp = sampleResult.substring(0,sampleResult.length()-1);
prev.setResponseData(temp.getBytes());

I have added two such beanshell post-processor parts to my test plan,
so all response data should be cleaned before xpath assertion and
extraction are done.

But unfortunately this does only work for the assertion, not for the
xpath extraction. It seems like the extraction is evaluated before the
beanshell post-processor, despite the sort order in the test plan. Is
there anything i can do to circumvent this problem?

Kind regards, knut

2007/6/12, sebb <[EMAIL PROTECTED]>:
> Have you tried the tolerant check-box?
>
> Assertions are processed after Post-Processors:
>
> http://jakarta.apache.org/jmeter/usermanual/test_plan.html#executionorder
>
> so you can use a BeanShell Post-Processor to update the sampleData and
> strip off the garbage.
>
> But really, the server ought to be fixed to return valid XML.
>
> You can use the Save Responses to a file Post-Processor to create a
> copy of the data as evidence ;-).
>
> S.
> On 12/06/07, Knut Borchart <[EMAIL PROTECTED]> wrote:
> > Hi,
> >
> > it seems my problem with xpath (assertion/extraction) i mentioned in
> > another posting was caused by the application server sending a strange
> > character at the end of the response (displayed like a rectangle,
> > cannot paste here)
> >
> > <?xml version="1.0" encoding="UTF-8"?>
> > <CompositeResponse elapsed="0" date="2007-06-08T10:36:21+0100">
> >    <CustomerBalanceResponse balance="400.00"/>
> >    <FOOpenGameResponse gameId="12345678" nextDrawId="0"/>
> > </CompositeResponse>\something
> >
> > How can i clean the response content before applying xpath assertions
> > or extractions? I think i could strip the last character with a
> > regular expression post processor, but how to call the reference so
> > that the response content is overwritten?
> >
> > TIA, peter
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to