RespectBinding feature and not understood required extensibility elements
-------------------------------------------------------------------------

                 Key: CXF-2006
                 URL: https://issues.apache.org/jira/browse/CXF-2006
             Project: CXF
          Issue Type: Sub-task
          Components: JAX-WS Runtime
    Affects Versions: 2.1.3
            Reporter: Alessio Soldano


[ales...@localhost trunk]$ mvn -Ptestsuite,jboss424,hudson 
-Dtest=JBWS2449TestCase test
...
-------------------------------------------------------
 T E S T S
-------------------------------------------------------
Running org.jboss.test.ws.jaxws.jbws2449.JBWS2449TestCase
Tests run: 3, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 7.585 sec <<< 
FAILURE!

Results :

Failed tests: 
  testWithRespectBinding(org.jboss.test.ws.jaxws.jbws2449.JBWS2449TestCase)

Tests run: 3, Failures: 1, Errors: 0, Skipped: 0


The testcase basically deploy an EJB3 webservice endpoint with its own user 
specified wsdl contract. Here is an extract from the wsdl, there's a foo:bar 
required extensibility element:
<binding name='EndpointBinding' type='tns:Endpoint'>
  <soap:binding style='document' 
transport='http://schemas.xmlsoap.org/soap/http'/>
  <foo:bar wsdl:required="true"/>
  <operation name='echo'>
   <soap:operation soapAction=''/>
   <input>
    <soap:body use='literal'/>
   </input>
   <output>
    <soap:body use='literal'/>
   </output>
  </operation>
 </binding>
 <service name='EndpointService'>
  <port binding='tns:EndpointBinding' name='EndpointPort'>
   <soap:address location='http://127.0.0.1:8080/jaxws-jbws2449'/>
  </port>
 </service>

The testcase gets the port specifing a RequestBindingFeature(true) so that it 
expects an error because of the foo:bar unknown ext element.

public void testWithRespectBinding() throws Exception
   {
      URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
      QName serviceName = new QName("http://org.jboss.ws/jbws2449";, 
"EndpointService");
      try
      {
         Service.create(wsdlURL, serviceName).getPort(Endpoint.class, new 
RespectBindingFeature(true));
         fail("Exception expected, the wsdl has a not understood required 
extensibility element!");
      }
      catch (Exception e)
      {
         //NOOP
      }
   }






-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to