Grrison
10 years agoOccasional Contributor
how to set SOAP and REST Service Endpoint into Environments from Groovy
Hi All,
We would like to create a set of Environments and fill in SOAP, REST services, Properties from Groovy scripts.
I tried the codes below, but the Endpoint field of Environment cannot be filled in.
ServiceImpl SOAPService = env.addNewService("SOAPService",com.eviware.soapui.config.ServiceConfig.Type.SOAP);
EnvironmentEndpointConfigImpl SOAPepConfigImp = (EnvironmentEndpointConfigImpl)EnvironmentEndpointConfig.Factory.newInstance();
SOAPepConfigImp.setLabel("http://localhost:8080");
EndpointImpl SOAPep = new EndpointImpl( SOAPepConfigImp ,SOAPService);
SOAPService.setEndpoint(SOAPep);
Regards,
Grrison