Author: lwaterman
Date: Mon Oct 16 20:13:19 2006
New Revision: 464780

URL: http://svn.apache.org/viewvc?view=rev&rev=464780
Log:
Add new service fault test

Added:
    incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/FaultService/
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.bpel
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.wsdl
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/data17_1.txt
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/deploy.xml
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/test.properties
Removed:
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestSimpleVariableType/data14_1.txt
Modified:
    
incubator/ode/trunk/bpel-test/src/main/java/org/apache/ode/test/MessageExchangeContextImpl.java
    
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BPELTest.java
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl

Modified: 
incubator/ode/trunk/bpel-test/src/main/java/org/apache/ode/test/MessageExchangeContextImpl.java
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/main/java/org/apache/ode/test/MessageExchangeContextImpl.java?view=diff&rev=464780&r1=464779&r2=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/main/java/org/apache/ode/test/MessageExchangeContextImpl.java
 (original)
+++ 
incubator/ode/trunk/bpel-test/src/main/java/org/apache/ode/test/MessageExchangeContextImpl.java
 Mon Oct 16 20:13:19 2006
@@ -38,6 +38,8 @@
 
 package org.apache.ode.test;
 
+import java.io.IOException;
+
 import org.apache.ode.bpel.iapi.BpelEngineException;
 import org.apache.ode.bpel.iapi.ContextException;
 import org.apache.ode.bpel.iapi.Message;
@@ -47,6 +49,7 @@
 import org.apache.ode.bpel.iapi.MessageExchange.Status;
 import org.apache.ode.utils.DOMUtils;
 import org.w3c.dom.Element;
+import org.xml.sax.SAXException;
 
 import javax.xml.namespace.QName;
 
@@ -58,9 +61,14 @@
  *
  */
 public class MessageExchangeContextImpl implements MessageExchangeContext {
+       
+       private static final String PROBE_NS = 
"http://ode/bpel/unit-test/ProbeService.wsdl";;
+       private static final String FAULT_NS = 
"http://ode/bpel/unit-test/FaultService.wsdl";;
 
        // Probe Service is a simple concatination service
-       private QName probePT = new 
QName("http://ode/bpel/unit-test/ProbeService.wsdl","probeMessagePT";);
+       private static final QName probePT = new 
QName(PROBE_NS,"probeMessagePT");
+       private static final QName faultPT = new 
QName(FAULT_NS,"faultMessagePT");
+       
        private Message currentResponse;
        
        public void invokePartner(PartnerRoleMessageExchange mex)
@@ -71,6 +79,9 @@
                        invokeProbeService(mex);
                }
                
+               if (calledPT.equals(faultPT)) {
+                       invokeFaultService(mex);
+               }
 
        }
 
@@ -108,8 +119,54 @@
             response.setMessage(msg.getMessage());
                        prmx.reply(response);
                }
+       }
+       
+       private void invokeFaultService(PartnerRoleMessageExchange prmx) {
+               QName errorMsgType = new QName(FAULT_NS,"errorMessage");
+               QName responseMsgType = new QName(FAULT_NS,"faultMessage");
+               Message faultMsg = prmx.createMessage(errorMsgType);
+               Message responseMsg = prmx.createMessage(responseMsgType);
+
+               String ind1 = 
prmx.getRequest().getPart("faultIndicator1").getTextContent();
+               String ind2 = 
prmx.getRequest().getPart("faultIndicator2").getTextContent();
+               String inputData = 
prmx.getRequest().getPart("faultData").getTextContent();
+               
+               StringBuffer faultData = new 
StringBuffer("<message><errorID>FA-1</errorID><errorText>");
+               faultData.append(inputData);
+               faultData.append("</errorText></message>");
+               
+               StringBuffer responseData = new 
StringBuffer("<message><faultName>FA-NoFault</faultName><faultData>");
+               responseData.append(inputData);
+               responseData.append("</faultData></message>");
+               
+               
+               Element faultResponse = null;
+               Element response = null;
+               try {
+                       faultResponse = 
DOMUtils.stringToDOM(faultData.toString());
+                       response = 
DOMUtils.stringToDOM(responseData.toString());
+               } catch (SAXException e) {
+                       // TODO Auto-generated catch block
+                       e.printStackTrace();
+               } catch (IOException e) {
+                       // TODO Auto-generated catch block
+                       e.printStackTrace();
+               }
                
                
+               // TODO: Question - how does one set parts that are of a simple 
xsd type?
+               faultMsg.setMessage(faultResponse);
+               responseMsg.setMessage(response);
+               
+               if ( ind1.equals("yes")){
+                       prmx.replyWithFault("FaultMessage1", faultMsg);
+               } else {
+                       if ( ind2.equals("yes")){
+                               prmx.replyWithFault("FaultMessage2", faultMsg);
+                       } else {
+                               prmx.reply(responseMsg);
+                       }
+               }
 
        }
        

Modified: 
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BPELTest.java
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BPELTest.java?view=diff&rev=464780&r1=464779&r2=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BPELTest.java 
(original)
+++ 
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BPELTest.java 
Mon Oct 16 20:13:19 2006
@@ -219,7 +219,18 @@
     }
     public void testDynamicPick() throws Exception {
        go("target/test-classes/bpel/2.0/TestDynamicPick");
-    }  
+    }
+    public void testSimpleTypeParts() throws Exception {
+       go("target/test-classes/bpel/2.0/TestSimpleTypeParts");
+    }
+    public void testSimpleVariableType() throws Exception {
+       go("target/test-classes/bpel/2.0/TestSimpleVariableType");
+    }
+    public void testFaultWithVariable() throws Exception {
+       go("target/test-classes/bpel/2.0/TestFaultWithVariable");
+    }
+    
+    
          public void testNegativeCorrelation() throws Exception {
                /**
                 * This test contains invalid BPEL. There is an instantiating

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl?view=auto&rev=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl
 (added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/FaultService/faultService.wsdl
 Mon Oct 16 20:13:19 2006
@@ -0,0 +1,47 @@
+<!--
+   ~ Licensed to the Apache Software Foundation (ASF) under one
+   ~ or more contributor license agreements.  See the NOTICE file
+   ~ distributed with this work for additional information
+   ~ regarding copyright ownership.  The ASF licenses this file
+   ~ to you under the Apache License, Version 2.0 (the
+   ~ "License"); you may not use this file except in compliance
+   ~ with the License.  You may obtain a copy of the License at
+   ~
+   ~    http://www.apache.org/licenses/LICENSE-2.0
+   ~
+   ~ Unless required by applicable law or agreed to in writing,
+   ~ software distributed under the License is distributed on an
+   ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   ~ KIND, either express or implied.  See the License for the
+   ~ specific language governing permissions and limitations
+   ~ under the License.
+-->
+
+<wsdl:definitions targetNamespace="http://ode/bpel/unit-test/FaultService.wsdl";
+   xmlns="http://ode/bpel/unit-test/FaultService.wsdl";
+   xmlns:tns="http://ode/bpel/unit-test/FaultService.wsdl";
+   xmlns:xsd="http://www.w3.org/2001/XMLSchema";
+   xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";>
+
+   <wsdl:message name="faultMessage">
+      <wsdl:part name="faultName" type="xsd:string"/>
+      <wsdl:part name="faultData" type="xsd:string"/>
+      <wsdl:part name="faultIndicator1" type="xsd:string"/>
+      <wsdl:part name="faultIndicator2" type="xsd:string"/>
+   </wsdl:message>
+   <wsdl:message name="errorMessage">
+      <wsdl:part name="errorID" type="xsd:string"/>
+      <wsdl:part name="errorText" type="xsd:string"/>
+   </wsdl:message>
+
+    <wsdl:portType name="faultMessagePT">
+      <wsdl:operation name="throwFault">
+         <wsdl:input name="FaultInputMessage" message="tns:faultMessage"/>
+         <wsdl:output name="FaultOutputMessage" message="tns:faultMessage"/>
+         <wsdl:fault name="FaultMessage1" message="tns:errorMessage"/>
+         <wsdl:fault name="FaultMessage2" message="tns:errorMessage"/>
+      </wsdl:operation>
+   </wsdl:portType>
+
+</wsdl:definitions>
+

Modified: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl?view=diff&rev=464780&r1=464779&r2=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl
 (original)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/ProbeService/probeService.wsdl
 Mon Oct 16 20:13:19 2006
@@ -1,18 +1,28 @@
-<?xml version="1.0" ?>
-
-<!-- The probe service is a simple extension that concatenates two strings -->
-<!-- The probeName part is concatenated to the end of the probeData part -->
-<!-- and the probeData part is returned as output. -->
-<!-- The service is used to facilitate chicken track debugging of BPEL -->
+<!--
+   ~ Licensed to the Apache Software Foundation (ASF) under one
+   ~ or more contributor license agreements.  See the NOTICE file
+   ~ distributed with this work for additional information
+   ~ regarding copyright ownership.  The ASF licenses this file
+   ~ to you under the Apache License, Version 2.0 (the
+   ~ "License"); you may not use this file except in compliance
+   ~ with the License.  You may obtain a copy of the License at
+   ~
+   ~    http://www.apache.org/licenses/LICENSE-2.0
+   ~
+   ~ Unless required by applicable law or agreed to in writing,
+   ~ software distributed under the License is distributed on an
+   ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+   ~ KIND, either express or implied.  See the License for the
+   ~ specific language governing permissions and limitations
+   ~ under the License.
+-->
 
 <wsdl:definitions targetNamespace="http://ode/bpel/unit-test/ProbeService.wsdl";
    xmlns:tns="http://ode/bpel/unit-test/ProbeService.wsdl";
              xmlns:xsd="http://www.w3.org/2001/XMLSchema";
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
-             xmlns="http://schemas.xmlsoap.org/wsdl/";>
-
+   xmlns="http://ode/bpel/unit-test/ProbeService.wsdl";>
 
-  <!-- message declns -->
 
   <wsdl:message name="probeMessage">
      <wsdl:part name="probeName" type="xsd:string"/>
@@ -20,13 +30,11 @@
   </wsdl:message>
 
 
-  <!-- port type declns -->
    <wsdl:portType name="probeMessagePT">
       <wsdl:operation name="probe">
          <wsdl:input name="ProbeInputMessage" message="tns:probeMessage"/>
          <wsdl:output name="ProbeOutputMessage" message="tns:probeMessage"/>
       </wsdl:operation>
-
    </wsdl:portType>
 
 </wsdl:definitions>

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.bpel
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.bpel?view=auto&rev=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.bpel
 (added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.bpel
 Mon Oct 16 20:13:19 2006
@@ -0,0 +1,169 @@
+<process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+ xsi:schemaLocation="http://schemas.xmlsoap.org/ws/2004/03/business-process/ 
../../../../../../../bpel-schemas/src/main/resources/wsbpel_main-draft-Apr-29-2006.xsd"
+ xmlns:tns="http://ode/bpel/unit-test/TestFaultWithVariable";
+       targetNamespace="http://ode/bpel/unit-test/TestFaultWithVariable";
+ xmlns:wns="http://ode/bpel/unit-test/TestFaultWithVariable.wsdl";
+       xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl";
+       xmlns:flt="http://ode/bpel/unit-test/FaultService.wsdl";
+       xmlns="http://schemas.xmlsoap.org/ws/2004/03/business-process/";
+       name="TestFaultWithVariable"
+       queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+       expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"
+       suppressJoinFailure="yes">
+       
+       <!-- Unit test external fault handlers with variable input -->
+       <!--    throw                                   -->
+       <!--    catch                                   -->
+
+       <import location="TestFaultWithVariable.wsdl"
+               namespace="http://ode/bpel/unit-test/TestFaultWithVariable.wsdl";
+               importType="http://schemas.xmlsoap.org/wsdl/"; />
+       <import location="../ProbeService/probeService.wsdl"
+               namespace="http://ode/bpel/unit-test/ProbeService.wsdl";
+               importType="http://schemas.xmlsoap.org/wsdl/"/>
+       <import location="../FaultService/faultService.wsdl"
+               namespace="http://ode/bpel/unit-test/FaultService.wsdl";
+               importType="http://schemas.xmlsoap.org/wsdl/"/>
+       
+
+       <partnerLinks>
+               <partnerLink name="request" 
partnerLinkType="wns:TestFaultWithVariableRequest" 
myRole="TestFaultWithVariableService"/>
+               <partnerLink name="probe" partnerLinkType="wns:probeRequest" 
partnerRole="probeService" initializePartnerRole="yes"/>
+               <partnerLink name="fault" partnerLinkType="wns:faultRequest" 
partnerRole="faultService" initializePartnerRole="yes"/>
+       </partnerLinks>
+       <variables>
+               <variable name="request" messageType="wns:requestMessage"/>
+               <variable name="probeInput" messageType="prb:probeMessage"/>
+               <variable name="reply" messageType="wns:replyMessage"/>
+               <variable name="fault" messageType="flt:faultMessage"/>
+               <variable name="faultResponse" messageType="flt:faultMessage"/>
+       </variables>
+       <faultHandlers>
+               <catchAll>
+                       <sequence>
+                               <assign>
+                                       <copy>
+                                               <from>
+                                                       
<literal><![CDATA[caught fault with catchAll]]></literal>
+                                               </from>
+                                               <to variable="probeInput" 
part="probeName"/>
+                                       </copy>
+                               </assign>
+                               <invoke name="allFaultProbe" 
partnerLink="probe" portType="prb:probeMessagePT" operation="probe" 
inputVariable="probeInput" outputVariable="probeInput"/>
+                               <!-- copy internal accumulators to the reply 
message -->
+                               <assign name="allFaultAssign">
+                                       <copy>
+                                               <from variable="probeInput" 
part="probeName"/>
+                                               <to variable="reply" 
part="replyID"/>
+                                       </copy>
+                                       <copy>
+                                               <from variable="probeInput" 
part="probeData"/>
+                                               <to variable="reply" 
part="replyText"/>
+                                       </copy>
+                               </assign>
+                               <reply name="allFaultReply" 
partnerLink="request" portType="wns:TestFaultWithVariablePT" 
operation="request" variable="reply"/>
+                       </sequence>
+               </catchAll>
+       </faultHandlers>
+       <sequence>
+               <receive name="receive1" partnerLink="request" 
portType="wns:TestFaultWithVariablePT" operation="request" variable="request" 
createInstance="yes"/>
+               <!-- Copy input variables to internal accumulators -->
+               <assign name="assign1">
+                       <copy>
+                               <from variable="request" part="requestID"/>
+                               <to variable="probeInput" part="probeName"/>
+                       </copy>
+                       <copy>
+                               <from variable="request" part="requestText"/>
+                               <to variable="probeInput" part="probeData"/>
+                       </copy>
+               </assign>
+               <scope name="scopeOne">
+                       <faultHandlers>
+                               <catch faultName="flt:FaultMessage1" 
faultVariable="testError" faultMessageType="flt:errorMessage">
+                                       <sequence>
+                                               <assign>
+                                                       <copy>
+                                                               <from>
+                                                                       
<literal><![CDATA[caught FaultMessage1]]></literal>
+                                                               </from>
+                                                               <to 
variable="probeInput" part="probeName"/>
+                                                       </copy>
+                                               </assign>
+                                               <invoke name="testFaultProbe" 
partnerLink="probe" portType="prb:probeMessagePT" operation="probe" 
inputVariable="probeInput" outputVariable="probeInput"/>
+                                               <assign>
+                                                       <copy>
+                                                               <from 
variable="testError" part="errorText"/>
+                                                               <to 
variable="probeInput" part="probeName"/>
+                                                       </copy>
+                                               </assign>
+                                               <invoke 
name="faultMessageProbe" partnerLink="probe" portType="prb:probeMessagePT" 
operation="probe" inputVariable="probeInput" outputVariable="probeInput"/>
+                                       </sequence>
+                               </catch>
+                               <catch faultName="flt:FaultMessage2" 
faultVariable="testError" faultMessageType="flt:errorMessage">
+                                       <sequence>
+                                               <assign>
+                                                       <copy>
+                                                               <from>
+                                                                       
<literal><![CDATA[caught FaultMessage2]]></literal>
+                                                               </from>
+                                                               <to 
variable="probeInput" part="probeName"/>
+                                                       </copy>
+                                               </assign>
+                                               <invoke name="testFaultProbe" 
partnerLink="probe" portType="prb:probeMessagePT" operation="probe" 
inputVariable="probeInput" outputVariable="probeInput"/>
+                                               <assign>
+                                                       <copy>
+                                                               <from 
variable="testError" part="errorText"/>
+                                                               <to 
variable="probeInput" part="probeName"/>
+                                                       </copy>
+                                               </assign>
+                                               <invoke 
name="faultMessageProbe" partnerLink="probe" portType="prb:probeMessagePT" 
operation="probe" inputVariable="probeInput" outputVariable="probeInput"/>
+                                       </sequence>
+                               </catch>
+                       </faultHandlers>
+                       <sequence>
+                               <assign>
+                                       <copy>
+                                               <from>$request.requestID</from>
+                                               <to variable="fault" 
part="faultName"/>
+                                       </copy>
+                                       <copy>
+                                               
<from>$request.requestText</from>
+                                               <to variable="fault" 
part="faultData"/>
+                                       </copy>
+                                       <copy>
+                                               
<from>$request.faultIndicator1</from>
+                                               <to>$fault.faultIndicator1</to>
+                                       </copy>
+                                       <copy>
+                                               
<from>$request.faultIndicator2</from>
+                                               <to>$fault.faultIndicator2</to>
+                                       </copy>
+                               </assign>
+                               <invoke name="throwTestFault" 
partnerLink="fault" portType="flt:faultMessagePT" operation="throwFault" 
inputVariable="fault" outputVariable="faultResponse"/>
+                       </sequence>
+
+               </scope>
+               <assign>
+                       <copy>
+                               <from>
+                                       <literal><![CDATA[process 
complete]]></literal>
+                               </from>
+                               <to variable="probeInput" part="probeName"/>
+                       </copy>
+               </assign>
+               <invoke name="probe2" partnerLink="probe" 
portType="prb:probeMessagePT" operation="probe" inputVariable="probeInput" 
outputVariable="probeInput"/>
+               <!-- copy internal accumulators to the reply message -->
+               <assign name="assign2">
+                       <copy>
+                               <from variable="probeInput" part="probeName"/>
+                               <to variable="reply" part="replyID"/>
+                       </copy>
+                       <copy>
+                               <from variable="probeInput" part="probeData"/>
+                               <to variable="reply" part="replyText"/>
+                       </copy>
+               </assign>
+               <reply name="reply" partnerLink="request" 
portType="wns:TestFaultWithVariablePT" operation="request" variable="reply"/>
+       </sequence>
+</process>

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.wsdl
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.wsdl?view=auto&rev=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.wsdl
 (added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/TestFaultWithVariable.wsdl
 Mon Oct 16 20:13:19 2006
@@ -0,0 +1,65 @@
+<!--
+       ~ Licensed to the Apache Software Foundation (ASF) under one
+       ~ or more contributor license agreements.  See the NOTICE file
+       ~ distributed with this work for additional information
+       ~ regarding copyright ownership.  The ASF licenses this file
+       ~ to you under the Apache License, Version 2.0 (the
+       ~ "License"); you may not use this file except in compliance
+       ~ with the License.  You may obtain a copy of the License at
+       ~
+       ~    http://www.apache.org/licenses/LICENSE-2.0
+       ~
+       ~ Unless required by applicable law or agreed to in writing,
+       ~ software distributed under the License is distributed on an
+       ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+       ~ KIND, either express or implied.  See the License for the
+       ~ specific language governing permissions and limitations
+       ~ under the License.
+-->
+
+<wsdl:definitions 
targetNamespace="http://ode/bpel/unit-test/TestFaultWithVariable.wsdl";
+       xmlns:tns="http://ode/bpel/unit-test/TestFaultWithVariable.wsdl";
+       
xmlns:typens="http://ode/bpel/unit-test/TestFaultWithVariable.wsdl.types";
+       xmlns="http://ode/bpel/unit-test/TestFaultWithVariable.wsdl";
+       xmlns:plnk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/";      
+       xmlns:xsd="http://www.w3.org/2001/XMLSchema";
+       xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl";
+       xmlns:flt="http://ode/bpel/unit-test/FaultService.wsdl";
+       xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";>
+       
+       <wsdl:message name="requestMessage">
+               <wsdl:part name="requestID" type="xsd:string"/>
+               <wsdl:part name="requestText" type="xsd:string"/>
+               <wsdl:part name="faultIndicator1" type="xsd:string"/>
+               <wsdl:part name="faultIndicator2" type="xsd:string"/>
+       </wsdl:message>
+       <wsdl:message name="replyMessage">
+               <wsdl:part name="replyID" type="xsd:string"/>
+               <wsdl:part name="replyText" type="xsd:string"/>
+       </wsdl:message>
+
+       <wsdl:portType name="TestFaultWithVariablePT">
+               <wsdl:operation name="request">
+                       <wsdl:input message="requestMessage"/>
+                       <wsdl:output message="replyMessage"/>
+               </wsdl:operation>
+       </wsdl:portType>
+       <wsdl:binding name="TestFaultWithVariableBinding" 
type="tns:TestFaultWithVariablePT">
+               <wsdl:operation name="request">
+               </wsdl:operation>
+       </wsdl:binding>
+       <wsdl:service name="TestFaultWithVariableService">
+               <wsdl:port name="TestFaultWithVariablePort" 
binding="tns:TestFaultWithVariableBinding">
+               </wsdl:port>
+       </wsdl:service> 
+       
+       <plnk:partnerLinkType name="TestFaultWithVariableRequest">
+               <plnk:role name="TestFaultWithVariableService" 
portType="TestFaultWithVariablePT"/>
+       </plnk:partnerLinkType>
+       <plnk:partnerLinkType name="probeRequest">
+               <plnk:role name="probeService" portType="prb:probeMessagePT"/>
+       </plnk:partnerLinkType>
+       <plnk:partnerLinkType name="faultRequest">
+               <plnk:role name="faultService" portType="flt:faultMessagePT"/>
+       </plnk:partnerLinkType>
+</wsdl:definitions>

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/data17_1.txt
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/data17_1.txt?view=auto&rev=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/data17_1.txt
 (added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/data17_1.txt
 Mon Oct 16 20:13:19 2006
@@ -0,0 +1,19 @@
+# Test BPEL fault handlers with a faultVariable
+# Expected result = Event Start Test17.1 -> caught FaultMessage -> fault text 
one -> process complete
+
+# Note the prefix on the part name identifies the message type ( xml = xml 
data; str = string data )
+
+target.name.space=urn:sybase:bpel:test17Processing
+port.type=test17PT
+operation=request
+
+part1=str.requestID
+part2=str.requestText
+part3=str.faultIndicator1
+part4=str.faultIndicator2
+
+str.requestID=Start Test17.1
+str.requestText=Event Start Test17.1
+str.faultIndicator1=no
+str.faultIndicator2=no
+

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/deploy.xml
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/deploy.xml?view=auto&rev=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/deploy.xml
 (added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/deploy.xml
 Mon Oct 16 20:13:19 2006
@@ -0,0 +1,31 @@
+<!--
+       ~ Licensed to the Apache Software Foundation (ASF) under one
+       ~ or more contributor license agreements.  See the NOTICE file
+       ~ distributed with this work for additional information
+       ~ regarding copyright ownership.  The ASF licenses this file
+       ~ to you under the Apache License, Version 2.0 (the
+       ~ "License"); you may not use this file except in compliance
+       ~ with the License.  You may obtain a copy of the License at
+       ~
+       ~    http://www.apache.org/licenses/LICENSE-2.0
+       ~
+       ~ Unless required by applicable law or agreed to in writing,
+       ~ software distributed under the License is distributed on an
+       ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+       ~ KIND, either express or implied.  See the License for the
+       ~ specific language governing permissions and limitations
+       ~ under the License.
+-->
+
+<deploy xmlns="http://ode.fivesight.com/schemas/2006/06/27/dd"; 
+       xmlns:pns="http://ode/bpel/unit-test/TestFaultWithVariable"; 
+       xmlns:wns="http://ode/bpel/unit-test/TestFaultWithVariable.wsdl";>
+
+
+       <process name="pns:TestFaultWithVariable">
+               <active>true</active>
+               <provide partnerLink="request">
+                       <service name="wns:TestFaultWithVariableService" 
port="wns:TestFaultWithVariablePort"/>
+               </provide>
+       </process>
+</deploy>

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/test.properties
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/test.properties?view=auto&rev=464780
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/test.properties
 (added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestFaultWithVariable/test.properties
 Mon Oct 16 20:13:19 2006
@@ -0,0 +1,7 @@
+namespace=http://ode/bpel/unit-test/TestFaultWithVariable.wsdl
+service=TestFaultWithVariableService
+operation=request
+request1=<message><requestID>Start 
TestFaultWithVariable1</requestID><requestText>Event 
TestFaultWithVariable1</requestText><faultIndicator1>yes</faultIndicator1><faultIndicator2>no</faultIndicator2></message>
+response1=.*Event TestFaultWithVariable1 -&gt; caught FaultMessage1 -&gt; 
Event TestFaultWithVariable1 -&gt; process complete.*
+request2=<message><requestID>Start 
TestFaultWithVariable2</requestID><requestText>Event 
TestFaultWithVariable2</requestText><faultIndicator1>no</faultIndicator1><faultIndicator2>yes</faultIndicator2></message>
+response2=.*Event TestFaultWithVariable2 -&gt; caught FaultMessage2 -&gt; 
Event TestFaultWithVariable2 -&gt; process complete.*


Reply via email to