Forum Discussion
SunilDevasya
3 years agoNew Contributor
sanathkd ,
These lines are expected to work perfectly,
def project=testRunner.testCase.testSuite.project
def getEnv = project.getEnvironmentByName('test1');
def wsdlInterface = project.getInterfaceAt( 0 ).getName();
def wsdlService = getEnv.getService(wsdlInterface, com.eviware.soapui.config.ServiceConfig.Type.Enum.forString("SOAP"));
log.info wsdlService.name
Can you try looking at :
ToolBar >> Environment Dropdown >> Configure Environments >> Choose your test environment >> Tab "SOAP" and make sure you have atleast one API/Service added there. If there's atleast one service, Since you're trying for index '0' it must give positive result. See image below.
Related Content
Recent Discussions
- 6 days ago
- 11 days ago