Richard Kearney
Richard Kearney

Reputation: 1

Jmeter how to test different assertion for each users

Say I am using the csv data set config to add user simultaneously. Now I add my steps for each users it will assert different info. For example the my info screen for each user will be different and I want to verify that for each users logging in that the my info screen show the correct user info? Could anyone recommend how I could do this using jmeter? Hope this makes sense

Upvotes: 0

Views: 189

Answers (1)

Dmitri T
Dmitri T

Reputation: 168217

You can parameterize Assertions the same way you parameterize Samplers.

For example if you expect info screen to contain text Welcome, Joe where Joe will be different for any user you can use the following Response Assertion configuration:

JMeter Response Assertion

Where ${username} is the variable from the CSV file.

See How to Use JMeter Assertions in Three Easy Steps article for more information on conditionally marking JMeter sample results as passed or failed.

Upvotes: 0

Related Questions