Forum Discussion
Nastya_Khovrina
Alumni
8 years agoHi Jo,
You can get the name and status of individual assertions from the Assertion Test Step with the following Groovy script:
def testStep = testRunner.testCase.getTestStepByName("AssertionTestStepName")
def list = testStep.getAssertionEntryList()
for( assertion in list)
{
//log.info("Assertion: " + assertion)
log.info("Assertion Status: " + assertion.status)
log.info("Assertion Name: " + assertion.getAssertionName() )
}