RhinoScript rs = new RhinoScript("wsdlPortType",
"SCA = { wsdlPortType : 'HelloWorld', wsdlNamespace : 'http://helloworld',};", null,
getClass().getClassLoader());
RhinoSCAConfig scaConfig = new RhinoSCAConfig(rs.getScriptScope());
WSDLDefinitionRegistryImpl wsdlReg = new WSDLDefinitionRegistryImpl();
wsdlReg.setSchemaRegistry(new XMLSchemaRegistryImpl());
wsdlReg.setMonitor(NULL_MONITOR);
URL wsdlURL =
getClass().getClassLoader().getResource("org/apache/tuscany/container/javascript/rhino/helloworld.wsdl");
wsdlReg.loadDefinition("http://helloworld", wsdlURL);
JavaScriptIntrospector introspector =
new JavaScriptIntrospector(wsdlReg, new JavaInterfaceProcessorRegistryImpl());
ComponentType comonentType = introspector.introspectScript(scaConfig, rs.getClassLoader());
assertNotNull(comonentType);