I am trying to create methods in Utility.groovy class to use that method for all my getCodes.ashx page test Steps, where I can get a TestStep name dynamically during execution. But getting error java.lang.NullPointerException: Cannot get property ‘testCase’ on null object error at line:15 when calling method from GroovyScript step and getting Cannot get property ‘testCase’ on Null object when calling method within test step using ScriptAssertion.
For Groovy Script step I used
def xml = groovyUtils.getXmlHolder( testRunner.testCase.testSteps[TestStepName].testRequest.response.responseContent )
and for ScriptAssertion I used
def xml = groovyUtils.getXmlHolder( messageExchange.responseContent )
Hi,
From where are you calling this script? how is the testCase object defined?
Thanks
Subject | Author | Latest Post |
---|---|---|