The second groovy script i tried is the following, but when i run it, nothing happens. If i run the whole testCase it returns with FAILED:
TestCase failed [java.lang.NullPointerException:java.lang.NullPointerException], time taken = 148
import groovy.json.JsonSlurper
def props = new java.util.Properties();
props = testRunner.testCase.getTestStepByName("Properties");
def result = testRunner.testCase.testSuite.getTestCaseByName("TestCase1").getTestStepByName("getTransactionTypeList1").run(testRunner, context);
def groovyUtils = new com.eviware.soapui.support.GroovyUtils(context)
//def response = messageExchange.response.responseContent
def response =groovyUtils.getXmlHolder(testRunner.testCase.testSteps["getTransactionTypeList1"].testRequest.response.getContentAsXml());
def slurper = new JsonSlurper()
def json = slurper.parseText response
def propValue = props.setPropertyValue("count", json.size());