How to test concurrent logins using JMeter
I am able to do a开发者_如何学编程 login test with a single user. If I want to do this for concurrent logins, I am told to use a CSV Data Config component, so I followed this advice:
- Create a text file containing the user names and passwords, separated by commas. Put this in the same directory as your test plan.
- Add a CSV DataSet configuration element to the test plan. Name the variables USER and PASS.
- Add a path to the filename in that element (I made sure to check the file path).
- Replace the login name with
${USER}
and the password with${PASS}
on the Log in (HTTP Request) Sampler.
Sadly, in my login page, I see ${USER}
and ${PASS}
, instead of the values they represent (those in the CSV file). What am I missing?
Either jmeter is not finding your files or you have a typo somewhere.
In step no2 : be sure that your "user,pass" are exactly like in the file.
If in the file there a space and you dont in jmeter, he won't find the value, if you have a space in jmeter, he wont found the value. I usally go "user,pass" in the file and jmeter and it work fine.
Like this :
in my csv : myuser,mypass
in jmeter
In step no3 : I usally put the csv file in the root of where the jmeter test is, that way it always find it.
精彩评论