synapse-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@apache.org
Subject svn commit: r571070 [1/2] - in /webservices/synapse/trunk/java: ./ modules/core/src/main/java/org/apache/synapse/ modules/core/src/test/java/org/apache/synapse/config/xml/ modules/extensions/src/test/java/org/apache/synapse/mediators/ modules/samples/ ...
Date Thu, 30 Aug 2007 08:35:48 GMT
Author: ruwan
Date: Thu Aug 30 01:35:45 2007
New Revision: 571070

URL: http://svn.apache.org/viewvc?rev=571070&view=rev
Log:
Adding samples as integration tests to the samples module. There are some failures that needs to be addressed. These integration tests will not run in the normal install. U need to specify the property "integration" for these to run.

ie. "mvn clean install -Dintegration"

Added:
    webservices/synapse/trunk/java/modules/samples/src/test/
    webservices/synapse/trunk/java/modules/samples/src/test/java/
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/AbstractAutomationTestCase.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_0_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_100_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_101_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_102_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_103_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_104_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_10_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_110_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_111_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_112_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_113_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_114_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_11_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_1_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_2_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_3_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_4_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_500_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_501_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_502_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_503_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_50_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_510_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_51_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_52_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_53_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_54_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_55_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_56_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_57_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_5_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_600_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_60_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_6_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_7_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_8_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_9_Integration.java
    webservices/synapse/trunk/java/modules/samples/src/test/resources/
Modified:
    webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/ServerManager.java
    webservices/synapse/trunk/java/modules/core/src/test/java/org/apache/synapse/config/xml/AbstractTestCase.java
    webservices/synapse/trunk/java/modules/extensions/src/test/java/org/apache/synapse/mediators/AbstractTestCase.java
    webservices/synapse/trunk/java/modules/samples/pom.xml
    webservices/synapse/trunk/java/modules/samples/src/main/java/samples/userguide/MTOMSwAClient.java
    webservices/synapse/trunk/java/pom.xml

Modified: webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/ServerManager.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/ServerManager.java?rev=571070&r1=571069&r2=571070&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/ServerManager.java (original)
+++ webservices/synapse/trunk/java/modules/core/src/main/java/org/apache/synapse/ServerManager.java Thu Aug 30 01:35:45 2007
@@ -103,6 +103,7 @@
     public void stop() {
         try {
             if (listenerManager != null) {
+                listenerManager.stop();
                 listenerManager.destroy();
             }
             //we need to call this method to clean the team fils we created.

Modified: webservices/synapse/trunk/java/modules/core/src/test/java/org/apache/synapse/config/xml/AbstractTestCase.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/core/src/test/java/org/apache/synapse/config/xml/AbstractTestCase.java?rev=571070&r1=571069&r2=571070&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/core/src/test/java/org/apache/synapse/config/xml/AbstractTestCase.java (original)
+++ webservices/synapse/trunk/java/modules/core/src/test/java/org/apache/synapse/config/xml/AbstractTestCase.java Thu Aug 30 01:35:45 2007
@@ -80,8 +80,6 @@
             log.error(e);
         } catch (IOException e) {
             log.error(e);
-        } catch (ParserConfigurationException e) {
-            log.error(e);
         }
         return false;
     }
@@ -97,8 +95,6 @@
             log.error(e);
         } catch (IOException e) {
             log.error(e);
-        } catch (ParserConfigurationException e) {
-            log.error(e);
         }
         return false;
     }
@@ -116,8 +112,6 @@
         } catch (SAXException e) {
             log.error(e);
         } catch (IOException e) {
-            log.error(e);
-        } catch (ParserConfigurationException e) {
             log.error(e);
         }
         return false;

Modified: webservices/synapse/trunk/java/modules/extensions/src/test/java/org/apache/synapse/mediators/AbstractTestCase.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/extensions/src/test/java/org/apache/synapse/mediators/AbstractTestCase.java?rev=571070&r1=571069&r2=571070&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/extensions/src/test/java/org/apache/synapse/mediators/AbstractTestCase.java (original)
+++ webservices/synapse/trunk/java/modules/extensions/src/test/java/org/apache/synapse/mediators/AbstractTestCase.java Thu Aug 30 01:35:45 2007
@@ -83,8 +83,6 @@
             log.error(e);
         } catch (IOException e) {
             log.error(e);
-        } catch (ParserConfigurationException e) {
-            log.error(e);
         }
         return false;
     }
@@ -100,8 +98,6 @@
             log.error(e);
         } catch (IOException e) {
             log.error(e);
-        } catch (ParserConfigurationException e) {
-            log.error(e);
         }
         return false;
     }
@@ -118,8 +114,6 @@
         } catch (SAXException e) {
             log.error(e);
         } catch (IOException e) {
-            log.error(e);
-        } catch (ParserConfigurationException e) {
             log.error(e);
         }
         return false;

Modified: webservices/synapse/trunk/java/modules/samples/pom.xml
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/pom.xml?rev=571070&r1=571069&r2=571070&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/pom.xml (original)
+++ webservices/synapse/trunk/java/modules/samples/pom.xml Thu Aug 30 01:35:45 2007
@@ -19,9 +19,9 @@
   -->
 
 <project
-    xmlns="http://maven.apache.org/POM/4.0.0"
-    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+        xmlns="http://maven.apache.org/POM/4.0.0"
+        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+        xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
     <modelVersion>4.0.0</modelVersion>
     <parent>
         <groupId>org.apache.synapse</groupId>
@@ -36,13 +36,313 @@
     <description>Apache Synapse - Samples</description>
     <packaging>jar</packaging>
 
-    <build>
-    </build>
+    <profiles>
+        <profile>
+            <id>integration</id>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-antrun-plugin</artifactId>
+                        <version>1.1</version>
+                        <executions>
+                            <execution>
+                                <id>create_repo</id>
+                                <phase>generate-test-resources</phase>
+                                <configuration>
+                                    <tasks>
+                                        <echo message="*** Creating a sample n2n testing repository ***"/>
+
+                                        <mkdir dir="target/test_repos"/>
+                                        <mkdir dir="target/test_repos/axis2Server"/>
+                                        <mkdir dir="target/test_repos/axis2Client"/>
+                                        <mkdir dir="target/test_repos/synapse"/>
+                                        <mkdir dir="target/test_repos/synapse"/>
+                                        <mkdir dir="target/test_repos/synapse/modules"/>
+                                        <mkdir dir="target/test_repos/synapse/conf"/>
+                                        <mkdir dir="target/test_repos/axis2Server/services"/>
+                                        <mkdir dir="target/test_repos/axis2Server/modules"/>
+                                        <mkdir dir="target/test_repos/axis2Server/conf"/>
+                                        <mkdir dir="target/test_repos/axis2Client/modules"/>
+                                        <mkdir dir="target/test_repos/axis2Client/conf"/>
+
+                                        <copy file="../../repository/conf/sample/resources/misc/server/axis2.xml"
+                                              tofile="target/test_repos/axis2Server/conf/axis2.xml"/>
+                                        <copy file="../../repository/conf/sample/resources/misc/client/axis2.xml"
+                                              tofile="target/test_repos/axis2Client/conf/axis2.xml"/>
+                                        <copy file="../../repository/conf/axis2.xml"
+                                              tofile="target/test_repos/synapse/conf/axis2.xml"/>
+                                        <copy file="../core/src/main/resources/synapseIdentity.jks"
+                                              tofile="target/test_repos/synapse/conf/synapseIdentity.jks"/>
+                                        <copy file="../core/src/main/resources/axis2Identity.jks"
+                                              tofile="target/test_repos/synapse/conf/axis2Identity.jks"/>
+                                        <copy file="../core/src/main/resources/axis2Trust.jks"
+                                              tofile="target/test_repos/synapse/conf/axis2Trust.jks"/>
+                                        <copy file="../core/src/main/resources/synapseTrust.jks"
+                                              tofile="target/test_repos/synapse/conf/synapseTrust.jks"/>
+                                        <copy file="../core/src/test/resources/keystore.jks"
+                                              tofile="target/test_repos/synapse/conf/keystore.jks"/>
+
+                                        <property name="temp.dir" value="target/temp"/>
+                                        <property name="classes" value="${temp.dir}/classes"/>
+                                        <property name="services"
+                                                  value="target/test_repos/axis2Server/services"/>
+
+                                        <property name="src"
+                                                  value="services/SimpleStockQuoteService/src"/>
+
+                                        <mkdir dir="${temp.dir}"/>
+                                        <mkdir dir="${classes}"/>
+
+                                        <javac debug="on" destdir="${classes}" fork="true">
+                                            <src path="${src}"/>
+                                            <classpath refid="maven.compile.classpath"/>
+                                        </javac>
+
+                                        <property name="SSQ.dir"
+                                                  value="${temp.dir}/SimpleStockQuote"/>
+                                        <mkdir dir="${SSQ.dir}"/>
+
+                                        <mkdir dir="${SSQ.dir}/META-INF"/>
+                                        <copy file="${src}/../conf/services.xml"
+                                              tofile="${SSQ.dir}/META-INF/services.xml"/>
+                                        <copy file="${src}/../wsdl/SimpleStockQuoteService.wsdl"
+                                              tofile="${SSQ.dir}/META-INF/service.wsdl"/>
+                                        <copy toDir="${SSQ.dir}">
+                                            <fileset dir="${classes}">
+                                                <include name="**/*.class"/>
+                                            </fileset>
+                                        </copy>
+
+                                        <jar destfile="${services}/SimpleStockQuoteService.aar">
+                                            <fileset dir="${SSQ.dir}"/>
+                                        </jar>
+
+                                        <property name="src2"
+                                                  value="services/SecureStockQuoteService/src"/>
+                                        <delete dir="${temp.dir}"/>
+                                        <mkdir dir="${temp.dir}"/>
+                                        <mkdir dir="${classes}"/>
+                                        <javac debug="on" destdir="${classes}" fork="true">
+                                            <src path="${src2}"/>
+                                            <classpath refid="maven.compile.classpath"/>
+                                        </javac>
+                                        <property name="SSQ2.dir"
+                                                  value="${temp.dir}/SecureStockQuoteService"/>
+                                        <mkdir dir="${SSQ2.dir}"/>
+                                        <mkdir dir="${SSQ2.dir}/META-INF"/>
+                                        <copy file="${src2}/../conf/services.xml"
+                                              tofile="${SSQ2.dir}/META-INF/services.xml"/>
+                                        <copy file="${src2}/../wsdl/SimpleStockQuoteService.wsdl"
+                                              tofile="${SSQ2.dir}/META-INF/service.wsdl"/>
+                                        <copy file="${src2}/../store.jks"
+                                              tofile="${SSQ2.dir}/store.jks"/>
+                                        <copy toDir="${SSQ2.dir}">
+                                            <fileset dir="${classes}">
+                                                <include name="**/*.class"/>
+                                            </fileset>
+                                        </copy>
+                                        <jar destfile="${services}/SecureStockQuoteService.aar">
+                                            <fileset dir="${SSQ2.dir}"/>
+                                        </jar>
+
+                                        <property name="src3"
+                                                  value="services/MTOMSwASampleService/src"/>
+                                        <delete dir="${temp.dir}"/>
+                                        <mkdir dir="${temp.dir}"/>
+                                        <mkdir dir="${classes}"/>
+                                        <javac debug="on" destdir="${classes}" fork="true">
+                                            <src path="${src3}"/>
+                                            <classpath refid="maven.compile.classpath"/>
+                                        </javac>
+                                        <property name="SSQ3.dir"
+                                                  value="${temp.dir}/MTOMSwASampleService"/>
+                                        <mkdir dir="${SSQ3.dir}"/>
+                                        <mkdir dir="${SSQ3.dir}/META-INF"/>
+                                        <copy file="${src3}/../conf/services.xml"
+                                              tofile="${SSQ3.dir}/META-INF/services.xml"/>
+                                        <copy toDir="${SSQ3.dir}">
+                                            <fileset dir="${classes}">
+                                                <include name="**/*.class"/>
+                                            </fileset>
+                                        </copy>
+                                        <jar destfile="${services}/MTOMSwASampleService.aar">
+                                            <fileset dir="${SSQ3.dir}"/>
+                                        </jar>
+
+                                        <property name="src4"
+                                                  value="services/ReliableStockQuoteService/src"/>
+                                        <delete dir="${temp.dir}"/>
+                                        <mkdir dir="${temp.dir}"/>
+                                        <mkdir dir="${classes}"/>
+                                        <javac debug="on" destdir="${classes}" fork="true">
+                                            <src path="${src4}"/>
+                                            <classpath refid="maven.compile.classpath"/>
+                                        </javac>
+                                        <property name="RSQ.dir"
+                                                  value="${temp.dir}/ReliableStockQuoteService"/>
+                                        <mkdir dir="${RSQ.dir}"/>
+
+                                        <mkdir dir="${RSQ.dir}/META-INF"/>
+                                        <copy file="${src4}/../conf/services.xml"
+                                              tofile="${RSQ.dir}/META-INF/services.xml"/>
+                                        <copy file="${src4}/../wsdl/ReliableStockQuoteService.wsdl"
+                                              tofile="${RSQ.dir}/META-INF/service.wsdl"/>
+                                        <copy toDir="${RSQ.dir}">
+                                            <fileset dir="${classes}">
+                                                <include name="**/*.class"/>
+                                            </fileset>
+                                        </copy>
+
+                                        <jar destfile="${services}/ReliableStockQuoteService.aar">
+                                            <fileset dir="${RSQ.dir}"/>
+                                        </jar>
+
+                                    </tasks>
+                                </configuration>
+                                <goals>
+                                    <goal>run</goal>
+                                </goals>
+                            </execution>
+                        </executions>
+                    </plugin>
+
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-dependency-plugin</artifactId>
+                        <version>2.0-alpha-1</version>
+                        <executions>
+                            <execution>
+                                <id>copy</id>
+                                <phase>generate-test-resources</phase>
+                                <goals>
+                                    <goal>copy</goal>
+                                </goals>
+                                <configuration>
+                                    <artifactItems>
+                                        <artifactItem>
+                                            <groupId>org.apache.axis2</groupId>
+                                            <artifactId>addressing</artifactId>
+                                            <version>${addressing.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/axis2Server/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.apache.axis2</groupId>
+                                            <artifactId>addressing</artifactId>
+                                            <version>${addressing.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/axis2Client/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.apache.rampart</groupId>
+                                            <artifactId>rampart</artifactId>
+                                            <version>${rampart.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/axis2Client/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.apache.rampart</groupId>
+                                            <artifactId>rampart</artifactId>
+                                            <version>${rampart.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/axis2Server/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.apache.sandesha2</groupId>
+                                            <artifactId>sandesha2</artifactId>
+                                            <version>${sandesha2.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/axis2Server/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+
+
+                                        <artifactItem>
+                                            <groupId>org.apache.axis2</groupId>
+                                            <artifactId>addressing</artifactId>
+                                            <version>${addressing.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/synapse/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.apache.rampart</groupId>
+                                            <artifactId>rampart</artifactId>
+                                            <version>${rampart.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/synapse/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.apache.sandesha2</groupId>
+                                            <artifactId>sandesha2</artifactId>
+                                            <version>${sandesha2.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/synapse/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                        <artifactItem>
+                                            <groupId>org.apache.synapse</groupId>
+                                            <artifactId>synapse</artifactId>
+                                            <version>${synapse.version}</version>
+                                            <type>mar</type>
+                                            <overWrite>true</overWrite>
+                                            <outputDirectory>target/test_repos/synapse/modules
+                                            </outputDirectory>
+                                        </artifactItem>
+                                    </artifactItems>
+                                </configuration>
+                            </execution>
+                        </executions>
+                    </plugin>
+
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-surefire-plugin</artifactId>
+                        <version>2.3</version>
+                        <configuration>
+                            <forkMode>pertest</forkMode>
+                            <includes>
+                                <!--<include>**/*TestSuite.java</include>-->
+                                <include>**/*Integration.java</include>
+                            </includes>
+                            <redirectTestOutputToFile>true</redirectTestOutputToFile>
+                            <workingDirectory>../..</workingDirectory>
+                            <childDelegation>false</childDelegation>
+                        </configuration>
+                    </plugin>
+
+                </plugins>
+            </build>
+            <activation>
+                <property>
+                    <name>integration</name>
+                </property>
+            </activation>
+        </profile>
+    </profiles>
 
     <dependencies>
         <dependency>
             <groupId>org.apache.synapse</groupId>
             <artifactId>synapse-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.synapse</groupId>
+            <artifactId>synapse-extensions</artifactId>
         </dependency>
     </dependencies>
 

Modified: webservices/synapse/trunk/java/modules/samples/src/main/java/samples/userguide/MTOMSwAClient.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/main/java/samples/userguide/MTOMSwAClient.java?rev=571070&r1=571069&r2=571070&view=diff
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/main/java/samples/userguide/MTOMSwAClient.java (original)
+++ webservices/synapse/trunk/java/modules/samples/src/main/java/samples/userguide/MTOMSwAClient.java Thu Aug 30 01:35:45 2007
@@ -52,12 +52,12 @@
     public static void main(String[] args) throws Exception {
 
         String targetEPR = getProperty("opt_url", "http://localhost:8080/soap/MTOMSwASampleService");
-        String fileName  = getProperty("opt_file", "./../../repository/conf/sample/resources/mtom/asf-logo.gif");
-        String mode      = getProperty("opt_mode", "mtom");
+        String fileName = getProperty("opt_file", "./../../repository/conf/sample/resources/mtom/asf-logo.gif");
+        String mode = getProperty("opt_mode", "mtom");
 
-        if (args.length > 0) mode      = args[0];
+        if (args.length > 0) mode = args[0];
         if (args.length > 1) targetEPR = args[1];
-        if (args.length > 2) fileName  = args[2];
+        if (args.length > 2) fileName = args[2];
 
         if ("mtom".equals(mode)) {
             sendUsingMTOM(fileName, targetEPR);
@@ -66,7 +66,7 @@
         }
     }
 
-    private static void sendUsingSwA(String fileName, String targetEPR) throws IOException {
+    public static MessageContext sendUsingSwA(String fileName, String targetEPR) throws IOException {
 
         Options options = new Options();
         options.setTo(new EndpointReference(targetEPR));
@@ -86,11 +86,11 @@
 
 
         SOAPFactory factory = OMAbstractFactory.getSOAP11Factory();
-        SOAPEnvelope env    = factory.getDefaultEnvelope();
-        OMNamespace ns      = factory.createOMNamespace("http://www.apache-synapse.org/test", "m0");
-        OMElement payload   = factory.createOMElement("uploadFileUsingSwA", ns);
-        OMElement request   = factory.createOMElement("request", ns);
-        OMElement imageId   = factory.createOMElement("imageId", ns);
+        SOAPEnvelope env = factory.getDefaultEnvelope();
+        OMNamespace ns = factory.createOMNamespace("http://www.apache-synapse.org/test", "m0");
+        OMElement payload = factory.createOMElement("uploadFileUsingSwA", ns);
+        OMElement request = factory.createOMElement("request", ns);
+        OMElement imageId = factory.createOMElement("imageId", ns);
         imageId.setText(attachmentID);
         request.addChild(imageId);
         payload.addChild(request);
@@ -103,28 +103,30 @@
 
         SOAPBody body = response.getEnvelope().getBody();
         String imageContentId = body.
-            getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "uploadFileUsingSwAResponse")).
-            getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "response")).
-            getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "imageId")).
-            getText();
+                getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "uploadFileUsingSwAResponse")).
+                getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "response")).
+                getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "imageId")).
+                getText();
 
-        Attachments attachment  = response.getAttachmentMap();
+        Attachments attachment = response.getAttachmentMap();
         dataHandler = attachment.getDataHandler(imageContentId);
         File tempFile = File.createTempFile("swa-", ".gif");
         FileOutputStream fos = new FileOutputStream(tempFile);
         dataHandler.writeTo(fos);
-		fos.flush();
-		fos.close();
+        fos.flush();
+        fos.close();
 
         System.out.println("Saved response to file : " + tempFile.getAbsolutePath());
+
+        return response;
     }
 
-    private static void sendUsingMTOM(String fileName, String targetEPR) throws IOException {
+    public static OMElement sendUsingMTOM(String fileName, String targetEPR) throws IOException {
         OMFactory factory = OMAbstractFactory.getOMFactory();
         OMNamespace ns = factory.createOMNamespace("http://www.apache-synapse.org/test", "m0");
         OMElement payload = factory.createOMElement("uploadFileUsingMTOM", ns);
         OMElement request = factory.createOMElement("request", ns);
-        OMElement image   = factory.createOMElement("image", ns);
+        OMElement image = factory.createOMElement("image", ns);
 
         System.out.println("Sending file : " + fileName + " as MTOM");
         FileDataSource fileDataSource = new FileDataSource(new File(fileName));
@@ -144,9 +146,9 @@
         OMElement response = serviceClient.sendReceive(payload);
 
         OMText binaryNode = (OMText) response.
-            getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "response")).
-            getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "image")).
-            getFirstOMChild();
+                getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "response")).
+                getFirstChildWithName(new QName("http://www.apache-synapse.org/test", "image")).
+                getFirstOMChild();
         dataHandler = (DataHandler) binaryNode.getDataHandler();
         InputStream is = dataHandler.getInputStream();
 
@@ -163,5 +165,6 @@
         dest.flush();
         dest.close();
         System.out.println("Saved response to file : " + tempFile.getAbsolutePath());
+        return response;
     }
 }

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/AbstractAutomationTestCase.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/AbstractAutomationTestCase.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/AbstractAutomationTestCase.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/AbstractAutomationTestCase.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,80 @@
+/*
+ *  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.
+ */
+
+package org.apache.synapse.samples.n2n;
+
+import org.apache.axiom.om.OMElement;
+import org.apache.synapse.ServerManager;
+import org.custommonkey.xmlunit.NamespaceContext;
+import org.custommonkey.xmlunit.SimpleNamespaceContext;
+import org.custommonkey.xmlunit.XMLTestCase;
+import org.custommonkey.xmlunit.XMLUnit;
+import samples.util.SampleAxis2Server;
+
+import java.io.ByteArrayOutputStream;
+import java.io.OutputStream;
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ *
+ */
+public abstract class AbstractAutomationTestCase extends XMLTestCase {
+
+    protected void setUp() throws java.lang.Exception {
+        super.setUp();
+        SampleAxis2Server.main(new String[]{"-repo", "modules/samples/target/test_repos/axis2Server/",
+                    "-conf", "modules/samples/target/test_repos/axis2Server/conf/axis2.xml"});
+        System.setProperty("repository", "modules/samples/target/test_repos/axis2Client");
+        setUpSynapseEnv();
+        setUpNSContext();
+    }
+
+    protected void setUpSynapseEnv() {
+        System.setProperty("port", "8080");
+        System.setProperty("org.apache.xerces.xni.parser.XMLParserConfiguration",
+                "org.apache.xerces.parsers.XMLGrammarCachingConfiguration");
+        System.setProperty("axis2.xml", "modules/samples/target/test_repos/synapse/conf/axis2.xml");
+        ServerManager.axis2Repolocation = SYNAPSE_REPO;
+        ServerManager.getInstance().start();
+    }
+
+    protected void setUpNSContext() {
+        Map m = new HashMap();
+        m.put("ms", "http://www.apache-synapse.org/test");
+        m.put("ns", "http://services.samples/xsd");
+        NamespaceContext nsCtx = new SimpleNamespaceContext(m);
+        XMLUnit.setXpathNamespaceContext(nsCtx);
+    }
+
+    protected String getStringResultOfTest(OMElement elem) throws Exception {
+        OutputStream os = new ByteArrayOutputStream();
+        elem.serialize(os);
+        return os.toString();
+    }
+
+    protected void tearDown() throws Exception {
+        ServerManager.getInstance().stop();
+        super.tearDown();
+    }
+
+    protected final String SYNAPSE_REPO = "modules/samples/target/test_repos/synapse";
+    protected final String SAMPLE_CONFIG_ROOT_PATH = "repository/conf/sample/";
+    protected final String SYNAPSE_BASE_URL = "http://localhost:8080/";
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_0_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_0_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_0_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_0_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,51 @@
+/*
+ *  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.
+ */
+
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_0_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_0.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+
+        if(System.getProperties().containsKey("trpurl")) {
+            System.getProperties().remove("trpurl");
+        }
+        
+        System.setProperty("prxurl", SYNAPSE_BASE_URL);
+        resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_100_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_100_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_100_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_100_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,22 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_100_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_100.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_101_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_101_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_101_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_101_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,27 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_101_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_101.xml");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy1");
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+
+        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy2");
+        resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_102_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_102_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_102_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_102_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,31 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import org.apache.axis2.AxisFault;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_102_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_102.xml");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        System.setProperty("trpurl", "http://localhost:8080/soap/StockQuoteProxy");
+        try {
+            getStringResultOfTest(StockQuoteClient.executeTestClient());
+        } catch (AxisFault f) {
+            assertEquals("The service cannot be found for the endpoint reference (EPR) " +
+                    "/soap/StockQuoteProxy", f.getReason());
+        }
+
+        System.setProperty("trpurl", "https://localhost:8443/soap/StockQuoteProxy");
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_103_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_103_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_103_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_103_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,23 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_103_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_102.xml");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy");
+        System.setProperty("policy", "./../../repository/conf/sample/resources/policy/client_policy_3.xml");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_104_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_104_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_104_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_104_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,25 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_104_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_104.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy");
+        System.setProperty("symbol", "IBM");
+        System.setProperty("mode", "quote");
+        System.setProperty("wsrm", "true");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_10_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_10_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_10_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_10_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,25 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_10_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_10.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+
+        // todo: how can we automate the registry change
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_110_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_110_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_110_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_110_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,23 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+
+/**
+ *
+ */
+public class SynapseSample_110_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_110.xml");
+//        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy");
+//        System.setProperty("symbol", "IBM");
+        // todo : setup the JMS
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+//        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+//        assertXpathExists("ns:getQuoteResponse", resultString);
+//        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_111_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_111_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_111_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_111_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,22 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+
+/**
+ *
+ */
+public class SynapseSample_111_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_111.xml");
+//        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy");
+        // todo : setup the JMS
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+//        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+//        assertXpathExists("ns:getQuoteResponse", resultString);
+//        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_112_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_112_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_112_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_112_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,22 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_112_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_1.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("mode", "placeorder");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        StockQuoteClient.executeTestClient();
+        // todo: how to test this (fire and forget)
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_113_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_113_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_113_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_113_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,22 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+
+/**
+ *
+ */
+public class SynapseSample_113_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_113.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy");
+        // todo: JMS setting up
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+//        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+//        assertXpathExists("ns:getQuoteResponse", resultString);
+//        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_114_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_114_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_114_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_114_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,22 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+
+/**
+ *
+ */
+public class SynapseSample_114_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_114.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL + "soap/StockQuoteProxy");
+        // todo: JMS setting up
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+//        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+//        assertXpathExists("ns:getQuoteResponse", resultString);
+//        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_11_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_11_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_11_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_11_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,23 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_11_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_11.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_1_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_1_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_1_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_1_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,42 @@
+/*
+ *  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.
+ */
+
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_1_Integration extends AbstractAutomationTestCase {
+
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_1.xml");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL + "soap/StockQuote");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_2_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_2_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_2_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_2_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,43 @@
+/*
+ *  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.
+ */
+
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ * 
+ */
+public class SynapseSample_2_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_2.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        System.setProperty("symbol", "IBM");
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_3_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_3_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_3_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_3_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,42 @@
+/*
+ *  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.
+ */
+
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_3_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_3.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_4_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_4_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_4_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_4_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,50 @@
+/*
+ *  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.
+ */
+
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_4_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_4.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        System.setProperty("symbol", "MSFT");
+        try {
+            // todo: need to fix this test - how can we test this?
+            getStringResultOfTest(StockQuoteClient.executeTestClient());
+        } catch (Exception e) {
+        }
+
+//        System.setProperty("symbol", "SUN");
+//        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+//        assertXpathExists("ns:getQuoteResponse", resultString);
+//        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_500_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_500_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_500_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_500_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_500_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_500.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        System.setProperty("mode", "customquote");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_501_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_501_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_501_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_501_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_501_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_501.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        System.setProperty("mode", "customquote");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_502_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_502_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_502_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_502_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,23 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_502_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_502.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_503_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_503_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_503_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_503_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_503_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_503.xml");
+        System.setProperty("addurl", "http://localhost:9000/soap/SimpleStockQuoteService");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        System.setProperty("mode", "customquote");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_50_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_50_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_50_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_50_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,22 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_50_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_50.xml");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL);
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_510_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_510_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_510_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_510_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_510_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_510.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL);
+        System.setProperty("mode", "quote");
+        System.setProperty("symbol", "IBM");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_51_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_51_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_51_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_51_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import org.apache.axiom.om.OMElement;
+import samples.userguide.MTOMSwAClient;
+
+/**
+ *
+ */
+public class SynapseSample_51_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_51.xml");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        System.setProperty("opt_mode", "mtom");
+        OMElement response = MTOMSwAClient.sendUsingMTOM(
+                "./../../repository/conf/sample/resources/mtom/asf-logo.gif", "http://localhost:8080/soap/MTOMSwASampleService");
+//        assertXpathExists("ns:getQuoteResponse", resultString);
+//        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_52_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_52_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_52_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_52_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,23 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_52_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_52.xml");
+        System.setProperty("trpurl", SYNAPSE_BASE_URL + "soap/StockQuote");
+        System.setProperty("rest", "true");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_53_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_53_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_53_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_53_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_53_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_53.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL);
+        System.setProperty("symbol", "IBM");
+        System.setProperty("mode", "quote");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_54_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_54_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_54_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_54_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_54_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_54.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL);
+        System.setProperty("symbol", "IBM");
+        System.setProperty("mode", "quote");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}

Added: webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_55_Integration.java
URL: http://svn.apache.org/viewvc/webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_55_Integration.java?rev=571070&view=auto
==============================================================================
--- webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_55_Integration.java (added)
+++ webservices/synapse/trunk/java/modules/samples/src/test/java/org/apache/synapse/samples/n2n/SynapseSample_55_Integration.java Thu Aug 30 01:35:45 2007
@@ -0,0 +1,24 @@
+package org.apache.synapse.samples.n2n;
+
+import org.apache.synapse.Constants;
+import samples.userguide.StockQuoteClient;
+
+/**
+ *
+ */
+public class SynapseSample_55_Integration extends AbstractAutomationTestCase {
+
+    protected void setUp() throws Exception {
+        System.setProperty(Constants.SYNAPSE_XML, SAMPLE_CONFIG_ROOT_PATH + "synapse_sample_54.xml");
+        System.setProperty("addurl", SYNAPSE_BASE_URL);
+        System.setProperty("symbol", "IBM");
+        System.setProperty("mode", "quote");
+        super.setUp();
+    }
+
+    public void testSample() throws Exception {
+        String resultString = getStringResultOfTest(StockQuoteClient.executeTestClient());
+        assertXpathExists("ns:getQuoteResponse", resultString);
+        assertXpathExists("ns:getQuoteResponse/ns:return", resultString);
+    }
+}



---------------------------------------------------------------------
To unsubscribe, e-mail: synapse-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: synapse-dev-help@ws.apache.org


Mime
View raw message