resolver.addModel(definition, context);
definition = resolver.resolveModel(WSDLDefinition.class, definition, context);
PortType portType = definition.getDefinition().getPortType(PORTTYPE_NAME);
WSDLInterface wi = wsdlFactory.createWSDLInterface(portType, definition, resolver, context.getMonitor());
WSDLOperation op = (WSDLOperation) wi.getOperations().get(0);
DataType<List<DataType>> inputType = op.getInputType();
Assert.assertEquals(1, inputType.getLogical().size());
DataType<XMLType> type = inputType.getLogical().get(0);
Assert.assertEquals(new QName("http://example.com/stockquote.xsd", "getLastTradePrice"), type.getLogical().getElementName());
DataType<List<DataType>> outputType = op.getOutputType();
DataType<XMLType> logical = outputType.getLogical().get(0);
Assert.assertEquals(new QName("http://example.com/stockquote.xsd", "getLastTradePriceResponse"),
logical.getLogical().getElementName());
Assert.assertTrue(op.isWrapperStyle());
DataType<List<DataType>> unwrappedInputType = op.getWrapper().getUnwrappedInputType();
List<DataType> childTypes = unwrappedInputType.getLogical();
Assert.assertEquals(1, childTypes.size());
DataType<XMLType> childType = childTypes.get(0);
Assert.assertEquals(new QName(null, "tickerSymbol"), childType.getLogical().getElementName());
DataType<List<DataType>> unwrappedOutputType = op.getWrapper().getUnwrappedOutputType();
childTypes = unwrappedOutputType.getLogical();
Assert.assertEquals(1, childTypes.size());
childType = childTypes.get(0);
Assert.assertEquals(new QName(null, "price"), childType.getLogical().getElementName());
}