Author: objectiser
Date: 2009-11-25 06:00:37 -0500 (Wed, 25 Nov 2009)
New Revision: 325
Added:
trunk/integration-tests/src/test/java/org/jboss/soa/bpel/tests/testcases/
trunk/integration-tests/src/test/java/org/jboss/soa/bpel/tests/testcases/RiftSaw118TestCase.java
trunk/integration-tests/src/test/resources/testcases/
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcess.bpel
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcessArtifacts.wsdl
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/bpel-deploy.xml
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/build.xml
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_request1.xml
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_response1.xml
Modified:
trunk/integration-tests/build.xml
Log:
Integration test to support RIFTSAW-118 - doclit support for WS integration.
Modified: trunk/integration-tests/build.xml
===================================================================
--- trunk/integration-tests/build.xml 2009-11-25 08:27:24 UTC (rev 324)
+++ trunk/integration-tests/build.xml 2009-11-25 11:00:37 UTC (rev 325)
@@ -127,5 +127,8 @@
<ant
antfile="src/test/resources/samples/Quickstart_esb_bpel_hello_world/build.xml"
/>
<ant
antfile="src/test/resources/samples/Quickstart_esb_bpel_loan_fault/build.xml"
/>
+
+ <ant antfile="src/test/resources/testcases/RiftSaw_118/build.xml" />
+
</target>
</project>
Added:
trunk/integration-tests/src/test/java/org/jboss/soa/bpel/tests/testcases/RiftSaw118TestCase.java
===================================================================
---
trunk/integration-tests/src/test/java/org/jboss/soa/bpel/tests/testcases/RiftSaw118TestCase.java
(rev 0)
+++
trunk/integration-tests/src/test/java/org/jboss/soa/bpel/tests/testcases/RiftSaw118TestCase.java 2009-11-25
11:00:37 UTC (rev 325)
@@ -0,0 +1,52 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.soa.bpel.tests.testcases;
+
+import org.jboss.soa.bpel.tests.RiftSawTest;
+import org.jboss.soa.bpel.tests.RiftSawTestSetup;
+
+import junit.framework.Test;
+
+/**
+ * Test case for running the RiftSaw_10_doclit testcase.
+ */
+public class RiftSaw118TestCase extends RiftSawTest {
+
+ private static final String TEST_NAME = "RiftSaw_118";
+
+ public RiftSaw118TestCase() {
+ super(TEST_NAME);
+ }
+
+ public static Test suite() {
+ return(new RiftSawTestSetup(RiftSaw118TestCase.class,
+ TEST_NAME, "RiftSaw_118-1.jar"));
+ }
+
+ public void testSendHello() throws Exception {
+ String result=sendSOAPMessage("hello_request1.xml",
+ "http://localhost:8080/RiftSaw_118WS");
+
+ // Comment out until RIFTSAW-118 is fixed
+ assertMessageFromFile(result, "hello_response1.xml");
+ }
+}
Added:
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcess.bpel
===================================================================
---
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcess.bpel
(rev 0)
+++
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcess.bpel 2009-11-25
11:00:37 UTC (rev 325)
@@ -0,0 +1,114 @@
+<bpel:process name="TestOrchestrationProcess"
+
targetNamespace="http://www.jboss.org/riftsaw/acs"
+ suppressJoinFailure="yes"
+
xmlns:tns="http://www.jboss.org/riftsaw/acs"
+
xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable...
+ >
+
+ <!-- Import the client WSDL -->
+ <bpel:import location="TestOrchestrationProcessArtifacts.wsdl"
namespace="http://www.jboss.org/riftsaw/acs"
+
importType="http://schemas.xmlsoap.org/wsdl/" />
+
+ <!-- ================================================================= -->
+ <!-- PARTNERLINKS -->
+ <!-- List of services participating in this BPEL process -->
+ <!-- ================================================================= -->
+ <bpel:partnerLinks>
+ <!-- The 'client' role represents the requester of this service.
-->
+ <bpel:partnerLink name="client"
+ partnerLinkType="tns:TestOrchestrationProcess"
+ myRole="TestOrchestrationProcessProvider"
+ />
+ </bpel:partnerLinks>
+
+ <!-- ================================================================= -->
+ <!-- VARIABLES -->
+ <!-- List of messages and XML documents used within this BPEL process -->
+ <!-- ================================================================= -->
+ <bpel:variables>
+ <!-- Reference to the message passed as input during initiation -->
+ <bpel:variable name="input"
+
messageType="tns:TestOrchestrationProcessRequestMessage"/>
+
+ <!--
+ Reference to the message that will be returned to the requester
+ -->
+ <bpel:variable name="output"
+
messageType="tns:TestOrchestrationProcessResponseMessage"/>
+
+ </bpel:variables>
+
+ <!-- ================================================================= -->
+ <!-- ORCHESTRATION LOGIC -->
+ <!-- Set of activities coordinating the flow of messages across the -->
+ <!-- services integrated within this business process -->
+ <!-- ================================================================= -->
+ <bpel:sequence name="Sequence">
+
+ <!-- Receive input from requester.
+ Note: This maps to operation defined in TestOrchestrationProcess.wsdl
+ -->
+ <bpel:receive name="start" partnerLink="client"
+ portType="tns:TestOrchestrationProcess"
+ operation="process" createInstance="yes"
variable="input"/>
+
+ <!-- Generate reply to synchronous request -->
+ <bpel:assign validate="no" name="assignHelloMesg">
+ <bpel:copy>
+ <bpel:from>
+ <bpel:literal xml:space="preserve">
+ <tns:TestOrchestrationProcessRequest
xmlns:tns="http://www.jboss.org/riftsaw/acs"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+ <tns:input></tns:input>
+ </tns:TestOrchestrationProcessRequest>
+ </bpel:literal>
+ </bpel:from>
+
+ <bpel:to variable="input"
part="payload"></bpel:to>
+ </bpel:copy>
+
+ <bpel:copy>
+ <bpel:from>
+ <bpel:literal xml:space="preserve">
+ <tns:TestOrchestrationProcessResponse
xmlns:tns="http://www.jboss.org/riftsaw/acs"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
+ <tns:result></tns:result>
+ </tns:TestOrchestrationProcessResponse>
+ </bpel:literal>
+ </bpel:from>
+ <bpel:to variable="output"
part="payload"></bpel:to>
+ </bpel:copy>
+
+ <bpel:copy>
+ <bpel:from part="payload" variable="input">
+ <bpel:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+ <![CDATA[tns:input]]>
+ </bpel:query>
+ </bpel:from>
+ <bpel:to part="payload" variable="output">
+ <bpel:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+ <![CDATA[tns:result]]>
+ </bpel:query>
+ </bpel:to>
+ </bpel:copy>
+
+ <bpel:copy>
+ <bpel:from>
+
+ <![CDATA[concat($output.payload,' World')]]>
+ </bpel:from>
+ <bpel:to part="payload" variable="output">
+ <bpel:query
queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0">
+ <![CDATA[tns:result]]>
+ </bpel:query>
+ </bpel:to>
+ </bpel:copy>
+
+ </bpel:assign>
+ <bpel:reply name="end"
+ partnerLink="client"
+ portType="tns:TestOrchestrationProcess"
+ operation="process"
+ variable="output"
+ />
+ </bpel:sequence>
+</bpel:process>
+
Added:
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcessArtifacts.wsdl
===================================================================
---
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcessArtifacts.wsdl
(rev 0)
+++
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/TestOrchestrationProcessArtifacts.wsdl 2009-11-25
11:00:37 UTC (rev 325)
@@ -0,0 +1,91 @@
+<?xml version="1.0"?>
+<definitions name="TestOrchestrationProcess"
+
targetNamespace="http://www.jboss.org/riftsaw/acs"
+
xmlns:tns="http://www.jboss.org/riftsaw/acs"
+
xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
+
xmlns="http://schemas.xmlsoap.org/wsdl/"
+
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ TYPE DEFINITION - List of types participating in this BPEL process
+ The BPEL Designer will generate default request and response types
+ but you can define or import any XML Schema type and use them as part
+ of the message types.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <types>
+ <schema attributeFormDefault="unqualified"
elementFormDefault="qualified"
+
targetNamespace="http://www.jboss.org/riftsaw/acs"
+
xmlns="http://www.w3.org/2001/XMLSchema">
+
+ <element name="TestOrchestrationProcessRequest">
+ <complexType>
+ <sequence>
+ <element name="input" type="string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="TestOrchestrationProcessResponse">
+ <complexType>
+ <sequence>
+ <element name="result" type="string"/>
+ </sequence>
+ </complexType>
+ </element>
+ </schema>
+ </types>
+
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ MESSAGE TYPE DEFINITION - Definition of the message types used as
+ part of the port type defintions
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <message name="TestOrchestrationProcessRequestMessage">
+ <part name="payload"
element="tns:TestOrchestrationProcessRequest"/>
+ </message>
+ <message name="TestOrchestrationProcessResponseMessage">
+ <part name="payload"
element="tns:TestOrchestrationProcessResponse"/>
+ </message>
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ PORT TYPE DEFINITION - A port type groups a set of operations into
+ a logical service unit.
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+
+ <!-- portType implemented by the TestOrchestrationProcess BPEL process -->
+ <portType name="TestOrchestrationProcess">
+ <operation name="process">
+ <input message="tns:TestOrchestrationProcessRequestMessage"
/>
+ <output
message="tns:TestOrchestrationProcessResponseMessage"/>
+ </operation>
+ </portType>
+
+
+<!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ PARTNER LINK TYPE DEFINITION
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
+ <plnk:partnerLinkType name="TestOrchestrationProcess">
+ <plnk:role name="TestOrchestrationProcessProvider"
portType="tns:TestOrchestrationProcess"/>
+ </plnk:partnerLinkType>
+
+ <binding name="HelloSoapBinding"
+ type="tns:TestOrchestrationProcess">
+ <soap:binding style="document"
+
transport="http://schemas.xmlsoap.org/soap/http" />
+ <operation name="process">
+ <soap:operation
+
soapAction="http://www.jboss.org/riftsaw/acs/process" />
+ <input>
+ <soap:body use="literal" />
+ </input>
+ <output>
+ <soap:body use="literal" />
+ </output>
+ </operation>
+ </binding>
+ <service name="HelloService">
+ <port name="HelloPort" binding="tns:HelloSoapBinding">
+ <soap:address location="http://localhost:8080/RiftSaw_118WS" />
+ </port>
+ </service>
+</definitions>
Added:
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/bpel-deploy.xml
===================================================================
--- trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/bpel-deploy.xml
(rev 0)
+++
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/bpel/bpel-deploy.xml 2009-11-25
11:00:37 UTC (rev 325)
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<deploy
xmlns="http://www.apache.org/ode/schemas/dd/2007/03"
xmlns:acs="http://www.jboss.org/riftsaw/acs">
+ <process name="acs:TestOrchestrationProcess">
+ <process-events generate="all"/>
+ <provide partnerLink="client">
+ <service name="acs:HelloService" port="HelloPort"/>
+ </provide>
+ </process>
+
+
+</deploy>
Added: trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/build.xml
===================================================================
--- trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/build.xml
(rev 0)
+++ trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/build.xml 2009-11-25
11:00:37 UTC (rev 325)
@@ -0,0 +1,30 @@
+<project name="RiftSaw_118" default="deploy"
basedir=".">
+
+ <description>
+ ${ant.project.name}
+ ${line.separator}
+ </description>
+
+ <property name="version" value="1" />
+
+ <property name="deploy.dir" value="${basedir}/target/tests"/>
+ <property name="test.dir"
value="${basedir}/src/test/resources/testcases/${ant.project.name}" />
+
+ <property name="jar.name"
value="${ant.project.name}-${version}.jar" />
+
+ <target name="deploy">
+ <echo>Deploy ${ant.project.name}</echo>
+ <mkdir dir="${deploy.dir}/${ant.project.name}" />
+ <jar basedir="${test.dir}/bpel"
destfile="${deploy.dir}/${ant.project.name}/${jar.name}" />
+
+ <copy todir="${deploy.dir}/${ant.project.name}">
+ <fileset dir="${test.dir}/messages"/>
+ </copy>
+ </target>
+
+ <target name="undeploy">
+ <echo>Undeploy ${ant.project.name}</echo>
+ <delete file="${deploy.dir}/${jar.name}" />
+ </target>
+
+</project>
Added:
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_request1.xml
===================================================================
---
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_request1.xml
(rev 0)
+++
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_request1.xml 2009-11-25
11:00:37 UTC (rev 325)
@@ -0,0 +1,8 @@
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:acs="http://www.jboss.org/riftsaw/acs">
+ <soapenv:Header/>
+ <soapenv:Body>
+ <acs:TestOrchestrationProcessRequest>
+ <acs:input>HELLO</acs:input>
+ </acs:TestOrchestrationProcessRequest>
+ </soapenv:Body>
+</soapenv:Envelope>
\ No newline at end of file
Added:
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_response1.xml
===================================================================
---
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_response1.xml
(rev 0)
+++
trunk/integration-tests/src/test/resources/testcases/RiftSaw_118/messages/hello_response1.xml 2009-11-25
11:00:37 UTC (rev 325)
@@ -0,0 +1,7 @@
+<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
+ <soapenv:Body>
+ <TestOrchestrationProcessResponse
xmlns="http://www.jboss.org/riftsaw/acs">
+ <result
xmlns:tns="http://www.jboss.org/riftsaw/acs">World</resul...
+ </TestOrchestrationProcessResponse>
+ </soapenv:Body>
+</soapenv:Envelope>
\ No newline at end of file