Hi
create a BeanShell Sampler
Sample code below

ResponseCode=200;
ResponseMessage="This is some message"; -->This shows in sampler result tab
IsSuccess=true;
SampleResult.setResponseData("This is some ResponseData"); --> This shows in
Response data tab

http://jakarta.apache.org/jmeter/api/org/apache/jmeter/samplers/SampleResult.html--
for the API

regards
deepak

On Wed, Aug 26, 2009 at 1:12 AM, Andrey Simonov <[email protected]> wrote:

>
> So, how can I output some text into the Tree View?
>
> I understand that "Listeners only show samples and Assertion failures."
>
> So maybe I can create a BeanShell/Java sampler that will output my text?
>
> I'm confused on how to do it :(
>
>
> Andrey Simonov wrote:
> >
> > Solution found:
> >
> > 1. Mentioned above obvious 'dummy sample' method
> > 2. BeanShell Assertion:
> >
> > if (Integer.parseInt(vars.get("AA")) < 30) {
> > Failure=true;
> > }
> >
> > Where AA is a JMeter variable.
> >
> >
> > sebb-2-2 wrote:
> >>
> >> On 17/08/2009, Andrey Simonov <[email protected]> wrote:
> >>>
> >>>  Hello,
> >>>
> >>>  Could you please tell me, how can I output certain messages to Tree
> >>> View
> >>>  Listener?
> >>>
> >>>  I need to do the the following:
> >>>
> >>>  If {variable} is > 5 then Output "Timeout expired"
> >>>
> >>>  Maybe this can be done into another listener, but anyway, how do I
> >>> output
> >>>  message into JMeter?
> >>
> >> Listeners only show samples and Assertion failures.
> >>
> >> So either generate a dummy sample (e.g. using If Controller and Java
> >> Request) or add an Assertion than fails when variable > 5 (e.g. using
> >> BeanShell or BSF Assertion)
> >>
> >>>  Thank you.
> >>>
> >>> --
> >>>  View this message in context:
> >>>
> http://www.nabble.com/Output-to-Tree-View-Listener-tp25002377p25002377.html
> >>>  Sent from the JMeter - User mailing list archive at Nabble.com.
> >>>
> >>>
> >>>  ---------------------------------------------------------------------
> >>>  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]
> >>
> >>
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Output-to-Tree-View-Listener-tp25002377p25148488.html
> Sent from the JMeter - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to