Author: mriou
Date: Thu Feb  8 09:11:26 2007
New Revision: 504968

URL: http://svn.apache.org/viewvc?view=rev&rev=504968
Log:
Adding one more test for if evaluations on XPath 1.0.

Added:
    incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/HelloWorld2.cbp
   (with props)
    incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.bpel
    incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.wsdl
    incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/deploy.xml
    
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/test.properties
Modified:
    
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BasicActivities20Test.java

Modified: 
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BasicActivities20Test.java
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BasicActivities20Test.java?view=diff&rev=504968&r1=504967&r2=504968
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BasicActivities20Test.java
 (original)
+++ 
incubator/ode/trunk/bpel-test/src/test/java/org/apache/ode/test/BasicActivities20Test.java
 Thu Feb  8 09:11:26 2007
@@ -14,7 +14,6 @@
                 * Test for a specific exception message.
                 * 
                 */
-
                go("target/test-classes/bpel/2.0/NegativeTargetNSTest1");
        }
        
@@ -22,5 +21,8 @@
         go("target/test-classes/bpel/2.0/TestTimer");
        }
 
+    public void testIf() throws Throwable {
+        go("target/test-classes/bpel/2.0/TestIf");
+    }
 
 }

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/HelloWorld2.cbp
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/HelloWorld2.cbp?view=auto&rev=504968
==============================================================================
Binary file - no diff available.

Propchange: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/HelloWorld2.cbp
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.bpel
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.bpel?view=auto&rev=504968
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.bpel 
(added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.bpel 
Thu Feb  8 09:11:26 2007
@@ -0,0 +1,68 @@
+<process name="HelloWorld2"
+         targetNamespace="http://ode/bpel/unit-test";
+         xmlns:bpws="http://schemas.xmlsoap.org/ws/2004/03/business-process/";
+         xmlns="http://schemas.xmlsoap.org/ws/2004/03/business-process/";
+         xmlns:tns="http://ode/bpel/unit-test";
+         xmlns:xsd="http://www.w3.org/2001/XMLSchema";
+         xmlns:test="http://ode/bpel/unit-test.wsdl";>
+
+    <import location="TestIf.wsdl"
+            namespace="http://ode/bpel/unit-test.wsdl";
+            importType="http://schemas.xmlsoap.org/wsdl/"; />
+
+    <partnerLinks>
+        <partnerLink name="helloPartnerLink"
+                     partnerLinkType="test:HelloPartnerLinkType"
+                     myRole="me" />
+    </partnerLinks>
+
+    <variables>
+        <variable name="myVar" messageType="test:HelloMessage"/>
+        <variable name="tmpVar" type="xsd:string"/>
+    </variables>
+
+    <sequence>
+        <receive
+                name="start"
+                partnerLink="helloPartnerLink"
+                portType="test:HelloPortType"
+                operation="hello"
+                variable="myVar"
+                createInstance="yes"/>
+
+        <assign name="assign1">
+            <copy>
+                <from variable="myVar" part="TestPart"/>
+                <to variable="tmpVar"/>
+            </copy>
+        </assign>
+        <if>
+            <condition>number($tmpVar)=number(2)</condition>
+            <then>
+                <assign name="assignError">
+                    <copy>
+                        <from>
+                            <literal>Worked</literal>
+                        </from>
+                        <to variable="myVar" part="TestPart"/>
+                    </copy>
+                </assign>
+            </then>
+            <else>
+                <assign name="assignZut">
+                    <copy>
+                        <from>
+                            <literal>Failed</literal>
+                        </from>
+                        <to variable="myVar" part="TestPart"/>
+                    </copy>
+                </assign>
+            </else>
+        </if>
+        <reply name="end"
+               partnerLink="helloPartnerLink"
+               portType="test:HelloPortType"
+               operation="hello"
+               variable="myVar"/>
+    </sequence>
+</process>

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.wsdl
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.wsdl?view=auto&rev=504968
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.wsdl 
(added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/TestIf.wsdl 
Thu Feb  8 09:11:26 2007
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="utf-8" ?>
+
+<wsdl:definitions 
+    targetNamespace="http://ode/bpel/unit-test.wsdl";
+    xmlns="http://schemas.xmlsoap.org/wsdl/";
+    xmlns:tns="http://ode/bpel/unit-test.wsdl";
+    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"; 
+    xmlns:xsd="http://www.w3.org/2001/XMLSchema";
+    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/";
+    xmlns:bpws="http://schemas.xmlsoap.org/ws/2004/03/business-process/";
+    xmlns:plnk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/";>
+    
+    <wsdl:message name="HelloMessage">
+        <wsdl:part name="TestPart" type="xsd:string"/>
+    </wsdl:message>
+    
+    <wsdl:portType name="HelloPortType">
+        <wsdl:operation name="hello">
+            <wsdl:input message="tns:HelloMessage" name="TestIn"/>
+            <wsdl:output message="tns:HelloMessage" name="TestOut"/>
+        </wsdl:operation>    
+    </wsdl:portType>
+    
+     <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType">
+        <soap:binding style="rpc" 
transport="http://schemas.xmlsoap.org/soap/http"/>
+        <wsdl:operation name="hello">
+            <soap:operation soapAction="" style="rpc"/>
+            <wsdl:input>
+                <soap:body
+                    namespace="http://ode/bpel/unit-test.wsdl";
+                    use="literal"/>
+            </wsdl:input>
+            <wsdl:output>
+                <soap:body
+                    namespace="http://ode/bpel/unit-test.wsdl"; 
+                    use="literal"/>
+            </wsdl:output>
+        </wsdl:operation>
+    </wsdl:binding>
+    <wsdl:service name="HelloService">
+               <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding">
+               <soap:address 
location="http://localhost:8080/ode/processes/helloWorld"/>
+               </wsdl:port>
+    </wsdl:service>
+    
+   <plnk:partnerLinkType name="HelloPartnerLinkType">
+       <plnk:role name="me" portType="tns:HelloPortType"/>
+       <plnk:role name="you" portType="tns:HelloPortType"/>
+   </plnk:partnerLinkType>
+</wsdl:definitions>
+

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/deploy.xml
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/deploy.xml?view=auto&rev=504968
==============================================================================
--- incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/deploy.xml 
(added)
+++ incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/deploy.xml 
Thu Feb  8 09:11:26 2007
@@ -0,0 +1,12 @@
+<deploy xmlns="http://ode.fivesight.com/schemas/2006/06/27/dd"; 
+       xmlns:pns="http://ode/bpel/unit-test"; 
+       xmlns:wns="http://ode/bpel/unit-test.wsdl";>
+
+
+       <process name="pns:HelloWorld2">
+               <active>true</active>
+               <provide partnerLink="helloPartnerLink">
+                       <service name="wns:HelloService" port="HelloPort"/>
+               </provide>
+       </process>
+</deploy>

Added: 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/test.properties
URL: 
http://svn.apache.org/viewvc/incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/test.properties?view=auto&rev=504968
==============================================================================
--- 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/test.properties
 (added)
+++ 
incubator/ode/trunk/bpel-test/src/test/resources/bpel/2.0/TestIf/test.properties
 Thu Feb  8 09:11:26 2007
@@ -0,0 +1,6 @@
+namespace=http://ode/bpel/unit-test.wsdl
+service=HelloService
+operation=hello
+request1=<message><TestPart>2.0</TestPart></message>
+response1=.*Worked.*
+


Reply via email to