This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Howdy, sorry if this question has been asked before ... but i've been searching around and havent been able to find a direct answer for finding method names in testNG.
We've recently switched from Junit to TestNG for parallel testing (explored both options in parallel and have found testNG is a tad more suited to our needs.)
For logging purpouses we get the test method that has invoked startSession() name in JUnit with the command getName(), however there doesnt seem to be an equivalent command in testNG.
i've found another way to get the test name, by using testName=Thread.currentThread().getStackTrace().getMethodName(); however i really doubt the reliability of this command.
Is there a way to find a test method that has invoked another method in testNG?