Forum Discussion
richie
6 years agoCommunity Hero
Hey socaltester,
Have you tried the script? Easiest way to find out if it works is to try it on a small dummy testsuite surely?
Then if it doesnt work you can post any error response you get to assist the diagnosis?
Just a suggestion....whenever im passing anything to qnt variables, u always add logging to ensure its working and to assist diagnosis if it doesnt
Ta
Rich
Have you tried the script? Easiest way to find out if it works is to try it on a small dummy testsuite surely?
Then if it doesnt work you can post any error response you get to assist the diagnosis?
Just a suggestion....whenever im passing anything to qnt variables, u always add logging to ensure its working and to assist diagnosis if it doesnt
Ta
Rich
socaltester
6 years agoContributor
Example Result:
def slaveTestStep = testRunner.testCase.testSuite.project.getTestSuiteByName("AdminTestSuite").getTestCaseByName("Authenticate")
testRunner.testCase.testSuite.project.getTestSuiteByName("AdminTestSuite").getTestCaseByName("AppBundles(addBundle)").cloneTestStepByName(slaveTestStep,"Authenticate")Tags (0) authenticationException thrown
groovy.lang.MissingPropertyException: No such property: testRunner for class: cloneAuthenticateStep
at cloneAuthenticateStep.run(cloneAuthenticateStep.groovy:1)
Note: I'm attempting to use the GroovyConsole tool withing SoapUI Pro
I'm hoping this might help: https://community.smartbear.com/t5/SoapUI-Pro/SoapUI3-5-No-such-property-testRunner-for-clases-Script1/m-p/16055#M7123
"...the assertion script does not have access to the testRunner variable..."
def testCase = messageExchange.modelItem.testCase
def ResponseMessage = testCase.testSteps["Step1"].testRequest.response.contentAsString
log.debug 'response is :::: ' + ResponseMessage