https://www.testautomationstudio.com/tutorials/courses/testng/listeners/
TestNG - Listeners | Test Automation Studio TestNG Tutorials
TestNG Listeners - TestNG Listeners listen to the events in your test scripts and modify the behavior. Listeners are used mostly for logging or reporting.
test automation studiotestng listenerstutorials