I have been tasked to create a script that will load-test a sign-up process. I 
have captured the process and need to alter it to create a new user for each 
thread.

I have two issues, one I think I understand how to do, the other, not so much.

1) The unique email is being handled by a Counter object when the form is 
POSTed. The Counter is referenced as “usercounter” starting at 101, 
incrementing by 1. The username I am posting is:

registration[email] jmeter${usercounter}@bogusemail.com<http://bogusemail.com>

I am 75% sure that this will do what I want, with each thread using an 
incrementing number for its run (the first will sign-up a user named 
“[email protected]<mailto:[email protected]>” and the 10th will 
sign-up a user named 
“[email protected]<mailto:[email protected]>” )



2) The form, however, passes a hidden variable to the browser that has to be 
passed back in the POST. The number is unique and has to match what was handed 
to it.

<input class="hidden form-control" id="registration_enrollment_id" 
name="registration[enrollment_id]" type="hidden" value="2”>

The developer sent me that snippet. The “value=‘2’ ” is unique for this 
registration and I need to be able to extract that data from the page source so 
that I can pass it back through the thread’s POST. At this point, I am LOST! 
Where do I find this in the recorded transactions? It was obviously extracted, 
since the POST that I sent back in the first test included the pair:

registration[enrollment_id] 2

Can anyone provide me a method for pulling the page source information for the 
form so that I can get this unique number? The enrollment fails without it and 
I can’t even test if my ${usercounter} works, either, since I can’t see the 
registration pass with the missing enrollment_id. The registration for the 
first user, the one created during the recording, worked great, since my 
browser handed back the correct number (that time the number was 2214)

I have used jmeter to load-test page loads and form fills, before, but this is 
the first time I have had to manipulate the data. I need help!

-Bob

Reply via email to