This listener is used to display the assertion result. It shows a summary of passed and failed samplers due to not meeting the assertion condition. JMeter Assertion Results listener throws a message in case of failure as given in the below figure:
How to add ‘Assertion Results’?
Follow the below steps:
- Select the appropriate element where you want to add the listener
- Test Plan
- Thread Group
- Controller
- Sampler
- Right-click on the element
- Hover the cursor on ‘Add’
- Hover the cursor on ‘Listener’
- Click ‘Assertion Results’
Scope: Assertion Results Listener can be added at any level that is sampler level, transaction level, thread-level or test plan level. The assertion result will be displayed as per the scope only. If the assertion result listener is added under a sampler then it will show the pass or fail status of that particular sampler only. If it is added under a transaction level then it will show the assertion status of all the samplers under that particular transaction controller.
Use: It is basically used for debug purpose during script creation.
Recommendation: Disable Assertion Results Listener during test execution as it consumes memory to write a log into a file.