Ejemplo n.º 1
0
 /**
  * ns4 is declared on Body and is used in faultcode. So making sure it is picked up after copy()
  */
 public void testCopy20() throws Exception {
   String soap18Msg =
       "<S:Envelope xmlns:S='http://schemas.xmlsoap.org/soap/envelope/'>"
           + "<S:Body xmlns:ns4='http://schemas.xmlsoap.org/soap/envelope/'>"
           + "<S:Fault>"
           + "<faultcode>ns4:Server</faultcode>"
           + "<faultstring>com.sun.istack.XMLStreamException2</faultstring>"
           + "</S:Fault>"
           + "</S:Body>"
           + "</S:Envelope>";
   Message message = useStreamCodec(soap18Msg);
   message.copy();
   SOAPFaultBuilder.create(message).createException(null);
 }
Ejemplo n.º 2
0
 public void testCopy16() throws IOException {
   String soap16Msg =
       "<S:Envelope xmlns:S='http://schemas.xmlsoap.org/soap/envelope/'> <S:Body> <a> </a><b> </b> <c/> </S:Body> </S:Envelope>";
   Message message = useStreamCodec(soap16Msg);
   message.copy();
 }
Ejemplo n.º 3
0
 public void testCopyWithSpaces() throws IOException {
   String soap12Msg =
       "<?xml version='1.0'?><S:Envelope xmlns:S='http://schemas.xmlsoap.org/soap/envelope/'> <S:Header> <m:ut xmlns:m='a'> <u xmlns='' id='a'>user</u> </m:ut> <b> hello </b> </S:Header> <S:Body> <ns2:c xmlns:ns2='local'> <clientName>Test</clientName> <ns2:year>2007</ns2:year> </ns2:c> </S:Body> </S:Envelope>";
   Message message = useStreamCodec(soap12Msg);
   message.copy();
 }
Ejemplo n.º 4
0
 public void testCopyStreamMessage1() throws IOException {
   String soap11Msg =
       "<soap:Envelope xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:xsd='http://www.w3.org/2001/XMLSchema'><Header xmlns='http://schemas.xmlsoap.org/soap/envelope/'> <SubscriptionInfo xmlns='http://ws.strikeiron.com'> <LicenseStatusCode>0</LicenseStatusCode> </SubscriptionInfo> </Header> <soap:Body> <GetCountryCodesResponse xmlns='http://www.strikeiron.com'> <GetCountryCodesResult/></GetCountryCodesResponse></soap:Body></soap:Envelope>";
   Message message = useStreamCodec(soap11Msg);
   message.copy();
 }