ContributionsMost RecentMost LikesSolutionsCalling a testcase from a testcaseIs there a way to tell if a testcase was called by another testcase in groovy? That way I can perform or not perform an action if it is called by another testcase. Thanks!Re: script lib location into testrunner.bat file SmartBear Support wrote: Hi, The test runner should take the argument -t /path/to/settings-file.xml http://www.soapui.org/Test-Automation/f ... tests.html Does that work for you? Henrik SmartBear Software Henrik, I'm not using the testrunner argument. My mistake. I'm trying to do it within soapui itself through groovy script, within the groovy script library directory I have some xsds I want to get too. So If I can get the location of the groovy script library, I can get to those xsds. Thanks, ShiangRe: script lib location into testrunner.bat file SmartBear Support wrote: Hi! You should be able to extract the parameter like this log.info System.properties["soapui.scripting.library"] -- Regards Erik SmartBear Sweden Erik, I need it to get the one set in the Application level (preferences/soapui pro/script library). That System properties above doesn't seem to work, returns null. I will look into that System properties. If it helps you, i'm using 4.5.1.1. Thanks, ShiangRe: script lib location into testrunner.bat fileAny way to do this by groovy script? I want to be able to retrieve the Global Script library location. Thanks ShiangRe: [RESOLVED]Script Assertions custom messageWell at least we know now. Actually the Try/Catch block is working well for me. Thanks McDonaldRe: When calling a test case which dynamically adds a test step throws null pointerCreate isolated copy for each run (Thread-Safe) The default stuff.Re: [RESOLVED]Script Assertions custom messageThat will work. Wish there is an easier way since I have a lot of asserts Re: When calling a test case which dynamically adds a test step throws null pointerI am using 3.5 beta2.When calling a test case which dynamically adds a test step throws null pointerHere is the scenario: I have a test case 'A' that contains a groovy script that creates a test step and deletes it. I have a test case 'B' that calls test case 'A' If I run test case 'A' by itself, it works perfectly. When I run test case 'B' I get a null pointer exception. Line 66 of GetMedia below is: testRunner.testCase.insertTestStep( config, -1 ) Stack: Tue Mar 02 11:07:42 PST 2010:ERROR:java.lang.NullPointerException java.lang.NullPointerException at com.eviware.soapui.model.tree.nodes.TestSuiteTreeNode$InternalTestSuiteListener.testStepAdded(TestSuiteTreeNode.java:131) at com.eviware.soapui.impl.wsdl.WsdlTestSuite.fireTestStepAdded(WsdlTestSuite.java:271) at com.eviware.soapui.impl.wsdl.testcase.WsdlTestCase.insertTestStep(WsdlTestCase.java:500) at com.eviware.soapui.impl.wsdl.testcase.WsdlTestCase.insertTestStep(WsdlTestCase.java:473) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite$PojoCachedMethodSiteNoUnwrapNoCoerce.invoke(PojoMetaMethodSite.java:229) at org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite.call(PojoMetaMethodSite.java:52) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:40) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:117) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:129) at DeviceGateway.RichMedia_GetMedia(DeviceGateway:66) at DeviceGateway$RichMedia_GetMedia.callStatic(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallStatic(CallSiteArray.java:48) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callStatic(AbstractCallSite.java:167) at DeviceGateway.Search_ValidateImagesByRichMedia(DeviceGateway:449) at DeviceGateway$Search_ValidateImagesByRichMedia.call(Unknown Source) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:40) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:117) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:133) at Script1.run(Script1.groovy:1) at com.eviware.soapui.support.scripting.groovy.SoapUIGroovyScriptEngine.run(SoapUIGroovyScriptEngine.java:93) at com.eviware.soapui.support.scripting.groovy.SoapUIProGroovyScriptEngineFactory$SoapUIProGroovyScriptEngine.run(SourceFile:51) at com.eviware.soapui.impl.wsdl.teststeps.WsdlGroovyScriptTestStep.run(WsdlGroovyScriptTestStep.java:148) at com.eviware.soapui.impl.wsdl.testcase.WsdlTestCaseRunner.runTestStep(WsdlTestCaseRunner.java:194) at com.eviware.soapui.impl.wsdl.testcase.WsdlTestCaseRunner.internalRun(WsdlTestCaseRunner.java:125) at com.eviware.soapui.impl.wsdl.testcase.WsdlTestCaseRunner.internalRun(WsdlTestCaseRunner.java:39) at com.eviware.soapui.impl.wsdl.support.AbstractTestRunner.run(AbstractTestRunner.java:138) at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Thanks, S[RESOLVED]Script Assertions custom messageIs there a way to show a custom error message when an assert fails in Script Assertions?