jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: JMeter 2.10 r1533061 - strange variable behavior
Date Fri, 27 Dec 2013 15:41:08 GMT
On 27 December 2013 11:07, Darius Damalakas <darius.damalakas@gmail.com> wrote:
> Hi,
>
> I can not understand why variable that I am extracting with CSS/JQuery
> Extractor is not passed in subsequent POST request.  I've read multiple
> answers, and it seems all should work fine. However, the value passed seems
> to be random. I am clearly missing something.

Most likely the Extractor is not in the correct place in the test plan.
It should be added as a child of the sampler which returns the value.

Remember that Post Processors run after *every* sampler that is in scope.

> Here's my setup:
> 1) HTTP GET to load a login page
> 2) extract anti forgery token value from HTML input field, store that in
> variable 'token'
> 3) do a HTTP POST with username, password, and anti forgery token value that
> i have extracted in previous step.
> Upon inspection, the value I submit is actually a default value ('noToken')
> that i've set.
> I also repeated step 3 multiple times, and the other times variable has a
> value, but not the value which is captured in step 2. I know this because i
> have also debug sampler before step 3, which prints what anti forgery token
> value i have captured.
>
> Attaching my test plan, you can actually run it, and you should get same
> result.   Would appreciate any hints.
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
> For additional commands, e-mail: user-help@jmeter.apache.org

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


Mime
View raw message