Skip to main content

Source code file content

Revision: 108

» Project Revision History

» Checkout URL

soatestingutilities / SOAInstallationTester / soa-validator.xml

Size: 57646 bytes, 1 line
<?xml version="1.0" encoding="US-ASCII" ?>
<project default="help" basedir="." name="Validator">

  <property name="windows.browser.location" value="C:\Program Files (x86)\Mozilla Firefox\firefox.exe"/>
  <property file="master.properties"/>
  <!--property file="env.properties"/-->
  <property environment="env"/>
  
  <condition property="soa.home" value="${env.SOA_HOME}">
    <not>
      <isset property="soa.home"/>
    </not>
  </condition>
  <condition property="mds.integration.home" value="${env.MDS_INTEGRATION_HOME}">
    <!-- Ex: /scratch/software/mw_local/olediour/FMWTOOLS_DROP7.APPS_GENERIC_090530.1629.D07B07A/mw_home/jdeveloper -->
    <not>
      <isset property="mds.integration.home"/>
    </not>
  </condition>
  <condition property="mw.home" value="${env.MW_HOME}">
    <not>
      <isset property="mw.home"/>
    </not>
  </condition>
  <condition property="jdev.home" value="${env.JDEV_HOME}">
    <not>
      <isset property="jdev.home"/>
    </not>
  </condition>
  <condition property="soa.install" value="${env.SOA_INSTALL}">
    <not>
      <isset property="soa.install"/>
    </not>
  </condition>

  <!--property name="java.protocol.handler.pkgs" value="oracle.mds.net.protocol"/-->
  
  <property name="serverURL" value="http://${proxy.name}:${soa.port.number}"/>
  <property name="user" value="${admin.user}"/>
  <property name="password" value="${admin.password}"/>

  <property name="oracle.home" value="${mds.integration.home}"/>
  
  <property name="top.dir" value="${basedir}/.."/>

  <!--property name="test.output.type" value="plain"/-->
  <property name="test.output.type" value="xml"/>

  <property file="build.properties"/>
  <path id="library.Junit-4.5.jar">
    <pathelement location="libs/junit-4.5.jar"/>
  </path>
  <path id="library.Oracle.XML.Parser.v2">
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.xdk_11.1.0/xmlparserv2.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.xdk_11.1.0/xml.jar"/>
  </path>
  <path id="library.SOA.Runtime">
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.fabric_11.1.1/fabric-runtime.jar"/>
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.mgmt_11.1.1/soa-infra-mgmt.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.fabriccommon_11.1.1/fabric-common.jar"/>
  </path>
  <path id="library.BPM.Workflow">
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.workflow_11.1.1/bpm-services.jar"/>
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.fabric_11.1.1/bpm-infra.jar"/>
    <!--pathelement location="${oracle.home}/integration/lib/orabpel.jar"/-->
    <!--pathelement location="${oracle.home}/lib/xml.jar"/>
    <pathelement location="${oracle.home}/lib/xmlparserv2.jar"/-->
  </path>
  <path id="library.WebLogic.10.3.Remote-Client">
    <pathelement location="${jdev.home}/wlserver_10.3/server/lib/weblogic.jar"/>
  </path>
  <path id="library.Oracle.JAX-WS.Client">
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wsclient.jar"/>
  </path>
  <path id="library.Java.EE.1.5">
    <pathelement location="${jdev.home}/modules/javax.activation_1.1.0.0_1-1.jar"/>
    <pathelement location="${jdev.home}/modules/javax.ejb_3.0.1.jar"/>
    <pathelement location="${jdev.home}/modules/javax.jms_1.1.1.jar"/>
    <pathelement location="${jdev.home}/modules/javax.transaction_1.0.0.0_1-1.jar"/>
    <pathelement location="${jdev.home}/modules/javax.mail_1.1.0.0_1-4-1.jar"/>
    <pathelement location="${jdev.home}/modules/javax.servlet_1.0.0.0_2-5.jar"/>
    <pathelement location="${jdev.home}/modules/javax.jsp_1.2.0.0_2-1.jar"/>
    <pathelement location="${jdev.home}/modules/javax.xml.rpc_1.2.1.jar"/>
    <!--pathelement location="${jdev.home}/modules/com.oracle.ws.http_client_1.3.0.0.jar"/-->
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wsclient.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wsserver.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wssecurity.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/orasaaj.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/orawsrm.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/orawsrel.jar"/>
    <pathelement location="${jdev.home}/modules/javax.management.j2ee_1.0.jar"/>
    <pathelement location="${jdev.home}/modules/com.bea.core.weblogic.saaj_1.6.0.0.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/xsdlib.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wsif.jar"/>
    <pathelement location="${jdev.home}/modules/javax.xml.stream_1.0.0.0.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/oc4j-schemas.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.odl_11.1.1/ojdl.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.odl_11.1.1/ojdl2.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_wss.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_xmlsec.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_core.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_cert.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_saml.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_saml2.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/org.jaxen_1.1.1.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.iau_11.1.1/fmw_audit.jar"/>
    <pathelement location="${jdev.home}/modules/javax.management.remote_1.0.1.3.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jmx_11.1.1/jmxframework.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jmx_11.1.1/jmxspi.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.dms_11.1.1/dms.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.fabriccommon_11.1.1/fabric-common.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.nlsrtl_11.1.0/orai18n.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/org.apache.commons.digester_1.8.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/org.springframework_2.5.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.javatools_11.1.1/javamodel-rt.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.javatools_11.1.1/javatools-nodeps.jar"/>
    <pathelement location="${jdev.home}/modules/org.eclipse.persistence_1.1.0.0_2-1.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/commonj.sdo_2.1.0.jar"/>
    <pathelement location="${jdev.home}/modules/javax.mail_1.4.jar"/>
  </path>
  <path id="library.test.util">
    <pathelement location="../ConsolidatedTestEnv/lib/xmlunit-1.3.jar"/>
    <pathelement location="../ConsolidatedTestEnv/deploy/ConsolidatedTestEnv.jar"/>
  </path>
  <path id="library.JAX-RPC.Client">
    <pathelement location="${oracle.home}/webservices/lib/jaxrpc-api-10.1.3.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/wsclient-10.1.3.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wsserver.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wssecurity.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/wsdl.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/orasaaj.jar"/>
    <pathelement location="${jdev.home}/modules/com.bea.core.weblogic.saaj_1.6.0.0.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/orawsdl.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/orawsrm.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/orawsrel.jar"/>
    <pathelement location="${jdev.home}/modules/javax.xml.registry_1.0.0.0_1-0.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/orajaxr.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/xsdlib.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/mdds.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/wsif.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.fabriccommon_11.1.1/fabric-common.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/org.jaxen_1.1.1.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.pki_11.1.1/oraclepki.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/ojpse.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_core.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_cert.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_xmlsec.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_wss.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_saml.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_saml2.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.ldap_11.1.1/ojmisc.jar"/>
    <!--pathelement location="${jdev.home}/modules/com.oracle.ws.http_client_1.3.0.0.jar"/-->
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.xdb_11.1.0.jar"/>
    <pathelement location="${jdev.home}/modules/javax.management.j2ee_1.0.jar"/>
    <pathelement location="${jdev.home}/modules/javax.management_1.2.1.jar"/>
    <pathelement location="${jdev.home}/modules/javax.xml.stream_1.0.0.0.jar"/>
    <pathelement location="${jdev.home}/modules/glassfish.jaxb_1.0.0.0_2-1-12.jar"/>
    <pathelement location="${jdev.home}/modules/glassfish.jaxb.xjc_1.0.0.0_2-1-12.jar"/>
    <pathelement location="${oracle.home}/webservices/lib/oc4j-schemas.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.odl_11.1.1/ojdl.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.odl_11.1.1/ojdl2.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.iau_11.1.1/fmw_audit.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jmx_11.1.1/jmxframework.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jmx_11.1.1/jmxspi.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.dms_11.1.1/dms.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.nlsrtl_11.1.0/orai18n.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/org.apache.commons.digester_1.8.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/org.springframework_2.5.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.wsm.common_11.1.1/wsm-policy-core.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.wsm.common_11.1.1/wsm-pmlib.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.wsm.agent.common_11.1.1/wsm-pap.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.wsm.agent.common_11.1.1/wsm-agent.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.wsm.common_11.1.1/wsm-secpol.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.javatools_11.1.1/javamodel-rt.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.javatools_11.1.1/javatools-nodeps.jar"/>
    <pathelement location="${jdev.home}/modules/javax.mail_1.4.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.xdk_11.1.0/xmlparserv2.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.webservices_11.1.1/lwdom.jar"/>
    <pathelement location="${jdev.home}/modules/com.bea.core.woodstox_1.0.0.0_4-0-5.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-api.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-common.jar"/>
  </path>
  <path id="library.BC4J.Security">
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.ldap_11.1.1/ldapjclnt11.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-api.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-common.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-ee.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-internal.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-unsupported-api.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jps-manifest.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.jps_11.1.1/jacc-spi.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.pki_11.1.1/oraclepki.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_core.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_cert.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_xmlsec.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.osdt_11.1.1/osdt_ws_sx.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.iau_11.1.1/fmw_audit.jar"/>
    <pathelement location="${jdev.home}/modules/javax.security.jacc_1.0.0.0_1-1.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.idm_11.1.1/identitystore.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.adf.share_11.1.1/adf-share-support.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.adf.share.ca_11.1.1/adf-share-ca.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.adf.share.ca_11.1.1/adf-share-base.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.adf.security_11.1.1/adf-share-security.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.xdk_11.1.0/xmlparserv2.jar"/>
    <pathelement location="${jdev.home}/modules/javax.activation_1.1.0.0_1-1.jar"/>
  </path>
  <path id="library.SOA.Workflow">
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.workflow_11.1.1/bpm-services.jar"/>
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.bpel_11.1.1/orabpel-common.jar"/>
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.bpel_11.1.1/orabpel.jar"/>
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.fabric_11.1.1/bpm-infra.jar"/>
    <pathelement location="${oracle.home}/soa/modules/oracle.soa.fabric_11.1.1/fabric-runtime.jar"/>
  </path>
  <path id="library.Wsclient_extended.jar">
    <pathelement location="${jdev.home}/oracle_common/webservices/wsclient_extended.jar"/>
  </path>
  <path id="classpath">
    <pathelement location="./classes"/>
    <!--pathelement location="${jdev.home}/oracle_common/modules/oracle.xdk_11.1.0/xmlparserv2.jar"/>
    <pathelement location="${jdev.home}/oracle_common/modules/oracle.xdk_11.1.0/xml.jar"/-->
    <path refid="library.Junit-4.5.jar"/>
    <path refid="library.Oracle.XML.Parser.v2"/>
    <path refid="library.SOA.Runtime"/>
    <path refid="library.BPM.Workflow"/>
    <path refid="library.WebLogic.10.3.Remote-Client"/>
    <path refid="library.Oracle.JAX-WS.Client"/>
    <path refid="library.Java.EE.1.5"/>
    <path refid="library.test.util"/>
    <path refid="library.JAX-RPC.Client"/>
    <path refid="library.BC4J.Security"/>
    <path refid="library.SOA.Workflow"/>
    <path refid="library.Wsclient_extended.jar"/>
  </path>

  <path id="classpath.2">
    <path refid="library.test.util"/>
    <path refid="classpath"/>
  </path>
  
  <taskdef name="resolve.classpath" 
           classname="testing.util.ClasspathTask" 
           classpathref="classpath"/>

  <target name="all" 
          depends="init, make, deploy.all, unit.test, undeploy.all, report" 
          description="Deploy the required composites, runs the unit tests, and undeploy.">
    <echo message="Done!"/>
  </target>
  
  <target name="init">
    <tstamp>
      <format property="now" pattern="dd-MMM-yyyy HH:mm"/>
    </tstamp>
    <echo message="Several variables are required for the deployment steps."/>
    <echo message="Java Runtime Environment version: ${java.version}"/>
    <echo message="Java Home: ${java.home}"/>
    <!--echo message="Classpath: ${java.class.path}"/-->

    <fail message="MW_HOME is not set. It must contain a user_projects, utils, wlserver_10.3, directories, among others.">
      <condition>
        <and>
          <not><isset property="env.MW_HOME"/></not>
          <not><isset property="mw.home"/></not>
        </and>
      </condition>
    </fail>

    <fail message="SOA_HOME is not set. It must contain a bin directory with the ant-sca.*.xml scripts in it.">
      <condition>
        <and>
          <not><isset property="env.SOA_HOME"/></not>
          <not><isset property="soa.home"/></not>
        </and>
      </condition>
    </fail>
    
    <!-- Ex: /scratch/software/mw_local/olediour/FMWTOOLS_DROP7.APPS_GENERIC_090530.1629.D07B07A/mw_home/jdeveloper -->
    <fail message="MDS_INTEGRATION_HOME is not set. It must contain an integration directory with seed/soa/shared/ sub-directories in it. Typically something like /scratch/software/mw_local/your-name/FMWTOOLS_DROP7.APPS_GENERIC_090530.1629.D07B07A/mw_home/jdeveloper">
      <condition>
        <and>
          <not><isset property="env.MDS_INTEGRATION_HOME"/></not>
          <not><isset property="mds.integration.home"/></not>
        </and>
      </condition>
    </fail>
    
    <fail message="serverURL is not set!">
      <condition>
        <not><isset property="serverURL"/></not>
      </condition>
    </fail>
    <fail message="user is not set!">
      <condition>
        <not><isset property="user"/></not>
      </condition>
    </fail>
    <fail message="password is not set!">
      <condition>
        <not><isset property="password"/></not>
      </condition>
    </fail>
    <available property="sca.package.exists" type="file" file="${soa.home}/bin/ant-sca-package.xml"/>
    <fail message="ant-sca-package.xml not found where expected, at ${soa.home}/bin/ant-sca-package.xml">
      <condition>
        <not><istrue value="${sca.package.exists}"/></not>
      </condition>
    </fail>    
    <available property="sca.deploy.exists" type="file" file="${soa.home}/bin/ant-sca-deploy.xml"/>
    <fail message="ant-sca-deploy.xml not found where expected, at ${soa.home}/bin/ant-sca-deploy.xml">
      <condition>
        <not><istrue value="${sca.deploy.exists}"/></not>
      </condition>
    </fail>
    <echo message="...required variables are set, moving on."/>
    <mkdir dir="${output.dir}"/>
    <!-- Checking classpath -->
    <resolve.classpath verbose="false" 
                       haltonfailure="yes" 
                       failureproperty="classpath.fails">
      <path refid="classpath"/>                       
    </resolve.classpath>                       
  </target>
  
  <target name="make" description="Build the project" depends="compile,copy"/>
  
  <target name="clean" depends="clean.classes, clean.composites" description="Clean the project, composites and classes"/>
  
  <target name="clean.classes">
    <delete includeemptydirs="true" quiet="false">
      <fileset dir="${output.dir}" includes="**/*"/>
    </delete>
  </target>


  <target name="clean.composites">
    <delete includeemptydirs="true" quiet="false">
      <fileset dir="${top.dir}" includes="**/deploy/sca*.jar"/>
    </delete>
  </target>

  <target name="compile" depends="init">
    <javac destdir="${output.dir}" classpathref="classpath"
           debug="${javac.debug}" nowarn="${javac.nowarn}"
           deprecation="${javac.deprecation}" encoding="ASCII" source="1.6"
           target="1.6" verbose="no">
      <compilerarg value="-Xlint:unchecked"/>
      <!-- For the oramds: protocol ... -->
      <!--compilerarg compiler="java.protocol.handler.pkgs" value="oracle.mds.net.protocol"/-->     
      <src path="src"/>
      <exclude name="**/.ade_path/"/>
    </javac>
  </target>
  <target name="copy"
          depends="init">
    <patternset id="copy.patterns">
      <include name="**/*.gif"/>
      <include name="**/*.GIF"/>
      <include name="**/*.jpg"/>
      <include name="**/*.JPG"/>
      <include name="**/*.jpeg"/>
      <include name="**/*.JPEG"/>
      <include name="**/*.png"/>
      <include name="**/*.PNG"/>
      <include name="**/*.properties"/>
      <include name="**/*.xml"/>
      <include name="**/*-apf.xml"/>
      <include name="**/*.ejx"/>
      <include name="**/*.xcfg"/>
      <include name="**/*.cpx"/>
      <include name="**/*.dcx"/>
      <include name="**/*.sva"/>
      <include name="**/*.wsdl"/>
      <include name="**/*.ini"/>
      <include name="**/*.tld"/>
      <include name="**/*.tag"/>
      <include name="**/*.xlf"/>
      <include name="**/*.xsl"/>
      <include name="**/*.xsd"/>
    </patternset>
    <copy todir="${output.dir}">
      <fileset dir="src">
        <patternset refid="copy.patterns"/>
      </fileset>
    </copy>
  </target>
  
  <target name="package.one" unless="jar.one.exists">
    <echo message="Packaging Composite EventTriggeredComposite"/>
    <ant antfile="${soa.home}/bin/ant-sca-package.xml" dir="${soa.home}/bin" inheritall="false">
      <property name="oracle.home" value="${oracle.home}"/>
      <property name="scac.application.home" value="${top.dir}"/>
      <property name="compositeDir" value="${top.dir}/EventTriggeredComposite"/>
      <property name="compositeName" value="EventTriggeredComposite"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="package.two" unless="jar.two.exists">
    <echo message="Packaging Composite EventGeneratorComposite"/>
    <ant antfile="${soa.home}/bin/ant-sca-package.xml" dir="${soa.home}/bin" inheritall="false">
      <property name="oracle.home" value="${oracle.home}"/>
      <property name="scac.application.home" value="${top.dir}"/>
      <property name="compositeDir" value="${top.dir}/EventGeneratorComposite"/>
      <property name="compositeName" value="EventGeneratorComposite"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="package.three" unless="jar.three.exists">
    <echo message="Packaging Composite CompositeWithRules"/>
    <ant antfile="${soa.home}/bin/ant-sca-package.xml" dir="${soa.home}/bin" inheritall="false">
      <property name="oracle.home" value="${oracle.home}"/>
      <property name="scac.application.home" value="${top.dir}"/>
      <property name="compositeDir" value="${top.dir}/CompositeWithRules"/>
      <property name="compositeName" value="CompositeWithRules"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="package.four" unless="jar.four.exists">
    <echo message="Packaging Composite HumanTaskComposite"/>
    <echo message="${top.dir}/HumanTaskComposite" />
    <ant antfile="${soa.home}/bin/ant-sca-package.xml" dir="${soa.home}/bin" inheritall="false">
      <property name="oracle.home" value="${oracle.home}"/>
      <property name="scac.application.home" value="${top.dir}"/>
      <property name="compositeDir" value="${top.dir}/HumanTaskComposite"/>
      <property name="compositeName" value="HumanTaskComposite"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="package.five" unless="jar.five.exists">
    <echo message="Packaging Composite SOACompositeForInstallationTests"/>
    <ant antfile="${soa.home}/bin/ant-sca-package.xml" dir="${soa.home}/bin" inheritall="false">
      <property name="oracle.home" value="${oracle.home}"/>
      <property name="scac.application.home" value="${top.dir}"/>
      <property name="compositeDir" value="${top.dir}/SOACompositeForInstallationTests"/>
      <property name="compositeName" value="SOACompositeForInstallationTests"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="package.six" unless="jar.six.exists">
    <echo message="Packaging Composite FlowNSample"/>
    <ant antfile="${soa.home}/bin/ant-sca-package.xml" dir="${soa.home}/bin" inheritall="false">
      <property name="oracle.home" value="${oracle.home}"/>
      <property name="scac.application.home" value="${top.dir}"/>
      <property name="compositeDir" value="${top.dir}/FlowNSample"/>
      <property name="compositeName" value="FlowNSample.2"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="package.seven" unless="jar.seven.exists">
    <echo message="Packaging Composite ASync.with.EDN"/>
    <ant antfile="${soa.home}/bin/ant-sca-package.xml" dir="${soa.home}/bin" inheritall="false">
      <property name="oracle.home" value="${oracle.home}"/>
      <property name="scac.application.home" value="${top.dir}"/>
      <property name="compositeDir" value="${top.dir}/ASync.with.EDN"/>
      <property name="compositeName" value="ASync.with.EDN"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="deploy.one" depends="init">
    <property name="sar.file.one" value="../EventTriggeredComposite/deploy/sca_EventTriggeredComposite_rev1.0.jar"/>
    <available property="jar.one.exists" type="file" file="${sar.file.one}"/>
    <antcall target="package.one"/>
    <echo>
      ==========================
       Step 1
       Deploying Composite EventTriggeredComposite
      ==========================
      on ${serverURL}, oracle.home=${oracle.home}
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="true" target="deploy">
      <property name="sarLocation" value="${sar.file.one}"/>
      <property name="overwrite" value="true"/>
      <!--property name="sysPropFile" value="sys-prop.properties"/-->
    </ant>
  </target>
  
  <target name="deploy.two" depends="init, deploy.one">
    <property name="sar.file.two" value="../EventGeneratorComposite/deploy/sca_EventGeneratorComposite_rev1.0.jar"/>
    <available property="jar.two.exists" type="file" file="${sar.file.two}"/>
    <antcall target="package.two"/>
    <echo>
      ==========================
       Step 2
       Deploying Composite EventGeneratorComposite
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="true" target="deploy">
      <property name="sarLocation" value="${sar.file.two}"/>
      <property name="overwrite" value="true"/>
    </ant>
  </target>
  
  <target name="deploy.three" depends="init">
    <property name="sar.file.three" value="../CompositeWithRules/deploy/sca_CompositeWithRules_rev1.0.jar"/>
    <available property="jar.three.exists" type="file" file="${sar.file.three}"/>
    <antcall target="package.three"/>
    <echo>
      ==========================
       Step 3
       Deploying Composite CompositeWithRules
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" target="deploy">
      <property name="sarLocation" value="${sar.file.three}"/>
      <property name="overwrite" value="true"/>
    </ant>
  </target>
  
  <target name="test.ldap" depends="compile">
    <echo message="Testing LDAP: is targeted user [${hwf.user}] available?"/>
    <echo message="outputfile: ldap.txt"/>
    <junit printsummary="yes" fork="yes" failureproperty="ldap.failure">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="ldap.testing.LDAPAccessUnitTest" haltonfailure="no" outfile="ldap"/>
    </junit>
    <antcall target="in.case.ldap.fails"/>
  </target>

  <target name="in.case.ldap.fails" if="ldap.failure">
    <echo>
      User [${hwf.user}] was not found in ldap...
      Maybe it does not exsit, or maybe the password you provided is not right...
      Moving on anyway...
      This may impact the Human Workflow Tests, that depend on this user.
      Task assigned to him/her might not behave nicely!
      (Check out ldap.txt for details on the problem).
    </echo>
  </target>  
  
  <!--target name="deploy.four" depends="init, test.ldap"-->
  <target name="deploy.four" depends="init">
    <property name="sar.file.four" value="../HumanTaskComposite/deploy/sca_HumanTaskComposite_rev1.0.jar"/>
    <available property="jar.four.exists" type="file" file="${sar.file.four}"/>
    <antcall target="package.four"/>
    <echo>
      ==========================
       Step 4
       Deploying Composite HumanTaskComposite
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" target="deploy">
      <property name="sarLocation" value="${sar.file.four}"/>
      <property name="overwrite" value="true"/>
    </ant>
  </target>
  
  <target name="deploy.five" depends="init">
    <property name="sar.file.five" value="../SOACompositeForInstallationTests/deploy/sca_SOACompositeForInstallationTests_rev1.0.jar"/>
    <available property="jar.five.exists" type="file" file="${sar.file.five}"/>
    <antcall target="package.five"/>
    <echo>
      ==========================
       Step 5
       Deploying Composite SOACompositeForInstallationTests
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" target="deploy">
      <property name="sarLocation" value="${sar.file.five}"/>
      <property name="overwrite" value="true"/>
    </ant>
  </target>
  
  <target name="deploy.six" depends="init">
    <property name="sar.file.six" value="../FlowNSample/deploy/sca_FlowNSample.2_rev1.0.jar"/>
    <available property="jar.six.exists" type="file" file="${sar.file.six}"/>
    <antcall target="package.six"/>
    <echo>
      ==========================
       Step 6
       Deploying Composite FlowNSample
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" target="deploy">
      <property name="sarLocation" value="${sar.file.six}"/>
      <property name="overwrite" value="true"/>
    </ant>
  </target>
  
  <target name="deploy.seven" depends="init">
    <property name="sar.file.seven" value="../ASync.with.EDN/deploy/sca_ASync.with.EDN_rev1.0.jar"/>
    <available property="jar.seven.exists" type="file" file="${sar.file.seven}"/>
    <antcall target="package.seven"/>
    <echo>
      ==========================
       Step 7
       Deploying Composite ASync.with.EDN
      ==========================
    </echo>
    <echo>
      Patching config plan...
    </echo>
    <antcall target="search.replace">
      <param name="from"    value="../ASync.with.EDN/ASync.with.EDN_cfgplan.xml"/>
      <param name="to"      value="../ASync.with.EDN/ASync.with.EDN_cfgplan.patched.xml"/>
      <param name="search"  value="130.35.95.19:7001"/>
      <param name="replace" value="${proxy.name}:${soa.port.number}"/>
    </antcall>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" target="deploy">
      <property name="sarLocation" value="${sar.file.seven}"/>
      <property name="configplan"  value="../ASync.with.EDN/ASync.with.EDN_cfgplan.patched.xml"/>
      <property name="overwrite"   value="true"/>
    </ant>
  </target>
  
  <target name="undeploy.one" depends="init">
    <echo>
      ==========================
       Step 1bis
       Undeploying Composite EventTriggeredComposite
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="false" target="undeploy">
      <property name="serverURL" value="${serverURL}"/>
      <property name="user" value="${user}"/>
      <property name="password" value="${password}"/>
      <property name="compositeName" value="EventTriggeredComposite"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="undeploy.two" depends="init">
    <echo>
      ==========================
       Step 2bis
       Undeploying Composite EventGeneratorComposite
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="false" target="undeploy">
      <property name="serverURL" value="${serverURL}"/>
      <property name="user" value="${user}"/>
      <property name="password" value="${password}"/>
      <property name="compositeName" value="EventGeneratorComposite"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="undeploy.three" depends="init">
    <echo>
      ==========================
       Step 3bis
       Undeploying Composite CompositeWithRules
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="false" target="undeploy">
      <property name="serverURL" value="${serverURL}"/>
      <property name="user" value="${user}"/>
      <property name="password" value="${password}"/>
      <property name="compositeName" value="CompositeWithRules"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="undeploy.four" depends="init">
    <echo>
      ==========================
       Step 4bis
       Undeploying Composite HumanTaskComposite
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="false" target="undeploy">
      <property name="serverURL" value="${serverURL}"/>
      <property name="user" value="${user}"/>
      <property name="password" value="${password}"/>
      <property name="compositeName" value="HumanTaskComposite"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="undeploy.five" depends="init">
    <echo>
      ==========================
       Step 5bis
       Undeploying Composite SOACompositeForInstallationTests
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="false" target="undeploy">
      <property name="serverURL" value="${serverURL}"/>
      <property name="user" value="${user}"/>
      <property name="password" value="${password}"/>
      <property name="compositeName" value="SOACompositeForInstallationTests"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="undeploy.six" depends="init">
    <echo>
      ==========================
       Step 6bis
       Undeploying Composite SampleFlowN
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="false" target="undeploy">
      <property name="serverURL" value="${serverURL}"/>
      <property name="user" value="${user}"/>
      <property name="password" value="${password}"/>
      <property name="compositeName" value="SampleFlowN.2"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <target name="undeploy.seven" depends="init">
    <echo>
      ==========================
       Step 7bis
       Undeploying Composite ASync.with.EDN
      ==========================
    </echo>
    <ant antfile="${soa.home}/bin/ant-sca-deploy.xml" inheritall="false" target="undeploy">
      <property name="serverURL" value="${serverURL}"/>
      <property name="user" value="${user}"/>
      <property name="password" value="${password}"/>
      <property name="compositeName" value="ASync.with.EDN"/>
      <property name="revision" value="1.0"/>
    </ant>
  </target>
  
  <!--
   !  Main targets
   +-->
  <target name="deploy.all" 
          depends="init, deploy.one, deploy.two, deploy.three, deploy.four, deploy.five, deploy.six, deploy.seven"
          description="Deploy all the composites to test later on."/>
  
  <target name="unit.test" 
          depends="make, unit.test.one, unit.test.two, unit.test.three, unit.test.four, unit.test.five, unit.test.six, unit.test.seven, unit.test.eight, report"
          description="Unit tests on the deployed composites."/>
  
  <target name="undeploy.all" 
          depends="init, undeploy.one, undeploy.two, undeploy.three, undeploy.four, undeploy.five, undeploy.six, undeploy.seven"
          description="Undeploy all the composites tested before."/>
  
  <!--
   !  Unitary targets
   +-->
  <target name="all.for.events" depends="deploy.one,make,unit.test.one,undeploy.one"/>
  <target name="all.for.synchronous" depends="deploy.five,make,unit.test.two,undeploy.five"/>
  <target name="all.for.asynchronous.1" depends="deploy.five,make, unit.test.three,undeploy.five"/>
  <target name="all.for.asynchronous.2" depends="deploy.five,make, unit.test.four,undeploy.five"/>
  <target name="all.for.asynchronous.2.time.out" depends="deploy.five,make,unit.test.seven,undeploy.five"/>
  <target name="all.for.rules" depends="deploy.three,make,unit.test.five,undeploy.three"/>
  <target name="all.for.hwf" depends="deploy.four,make,unit.test.six,undeploy.four"/>   
  <!-- More... --> 
  <target name="all.for.flow.n" depends="deploy.six,make,unit.test.eight,undeploy.six"/>
  <target name="all.for.async.correlation" depends="deploy.seven,make,unit.test.nine,undeploy.seven"/>
  <!-- End of Unitary targets --> 
  
  <target name="unit.test.one" depends="make">
    <echo>
    =========================================
    Testing Business Event Raising (SOA Side)
    =========================================
    outputfile: event.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="event.fails">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="event.unit.testing.EventUnitTest" haltonfailure="no" outfile="event"/>        
    </junit>    
    <antcall target="in.case.event.fails"/>
  </target>
  
  <target name="in.case.event.fails" if="event.fails">
    <echo>
      ===================================================================================
      The Business Event test failed.
      The reason could be the Data Sources used to raise it, the name of the server,...
      Make sure Remote JDBC is enabled on the server.
      in $MW_HOME/user_projects/domains/&lt;your domain&gt;/setDomainEnv.sh
      you need WLS_JDBC_REMOTE_ENABLED="-Dweblogic.jdbc.remoteEnabled=true"
      Here is the output of the test:
      ===================================================================================
    </echo>
    
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg value="event.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg value="event.txt"/>
    </exec-->
    <fail message="Business Event Test failed...">
      <condition>
        <equals arg1="${keep.testing}" arg2="false"/>
      </condition>
    </fail>
    <echo message="Moving on..."/>
  </target>
  
  <target name="unit.test.two" depends="make">
    <echo>
    ===========================
    Testing Synchronous service
    ===========================
    outputfile: synchronous.txt
    </echo>
    <!--java classpathref="classpath" classname="test.Hello" fork="yes"/-->
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="synchronous.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <!--sysproperty key="oracle.security.jps.config" value="../security/config/jps-config.xml"/-->
      <test name="service.unit.testing.SynchronousUnitTest" haltonfailure="no" outfile="synchronous"/>
    </junit>    
    <antcall target="in.case.synchronous.fails"/>
  </target>
  
  <target name="in.case.synchronous.fails" if="synchronous.fail">
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg line="synchronous.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg line="synchronous.txt"/>
    </exec-->
    <fail message="Synchronous Test stopped the process">
      <condition>
        <equals arg1="${keep.testing}" arg2="false"/>
      </condition>
    </fail>
    <echo message="Moving on..."/>
  </target>
  
  <target name="unit.test.three" depends="make">
    <echo>
    ====================================
    Testing Asynchronous One Way Service
    ====================================
    outputfile: asynchronous.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="asynchronous.1.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.ASyncOneWayUnitTest" haltonfailure="no" outfile="asynchronous"/>
    </junit>    
    <antcall target="in.case.asynchronous.1.fails"/>
  </target>

  <target name="in.case.asynchronous.1.fails" if="asynchronous.1.fail">
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg line="asynchronous.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg line="asynchronous.txt"/>
    </exec-->
    <fail message="ASynchronous Test stopped the process">
      <condition>
        <equals arg1="${keep.testing}" arg2="false"/>
      </condition>
    </fail>
    <echo message="Moving on..."/>
  </target>

  <target name="unit.test.four" depends="make">
    <echo>
    =====================================
    Testing Asynchronous Two Ways Service
    =====================================
    outputfile: asynchronous2.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="asynchronous.2.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.ASyncTwoWayUnitTest" haltonfailure="no" outfile="asynchronous2"/>
    </junit>    
    <antcall target="in.case.asynchronous.2.fails"/>
  </target>
  
  <target name="in.case.asynchronous.2.fails" if="asynchronous.2.fail">
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg line="asynchronous2.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg line="asynchronous2.txt"/>
    </exec-->
    <fail message="ASynchronous 2-way Test stopped the process">
      <condition>
        <equals arg1="${keep.testing}" arg2="false"/>
      </condition>
    </fail>
    <echo message="Moving on..."/>
  </target>

  <target name="unit.test.five" depends="make">
    <echo>
    ============================
    Testing Composite with Rules
    ============================
    outputfile: rules.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="rules.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.RulesCompositeUnitTest" haltonfailure="no" outfile="rules"/>
    </junit>    
    <antcall target="in.case.rules.fails"/>
  </target>
  
  <target name="in.case.rules.fails" if="rules.fail">
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg line="rules.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg line="rules.txt"/>
    </exec-->
    <fail message="Rules Test stopped the process">
      <condition>
        <equals arg1="${keep.testing}" arg2="false"/>
      </condition>
    </fail>
    <echo message="Moving on..."/>
  </target>

  <target name="unit.test.six" depends="make">
    <echo>
    ======================================
    Testing Human Workflow (BPEL for PPEL)
    ======================================
    outputfile: hwf.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="hwf.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.HumanWorkFlowUnitTest" haltonfailure="no" outfile="hwf"/>
    </junit>    
    <antcall target="in.case.hwf.fails"/>
  </target>  
  
  <target name="in.case.hwf.fails" if="hwf.fail">
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg line="hwf.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg line="hwf.txt"/>
    </exec-->
    <fail message="Human Workflow Test stopped the process">
      <condition>
        <equals arg1="${keep.testing}" arg2="false"/>
      </condition>
    </fail>
    <echo message="Moving on..."/>
  </target>

  <target name="unit.test.seven" depends="make">
    <echo>
    ==================================================
    Testing Asynchronous Two Ways Service with Timeout
    ==================================================
    outputfile: asynchronous2to.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="a2to.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.ASyncTwoWayWithTimeoutUnitTest" haltonfailure="no" outfile="asynchronous2to"/>
    </junit>  
    <antcall target="in.case.async.timeout.fails"/>
  </target>

  <target name="in.case.async.timeout.fails" if="a2to.fail">
    <echo>
      Asynchronous 2-ways with timeout test failed.
      Might not be a major issue, specially if the timeout expired.
      Check the output to know about that
    </echo>
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg line="asynchronous2to.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg line="asynchronous2to.txt"/>
    </exec-->
    <echo message="**********************"/>
  </target>
  
  <target name="unit.test.eight" depends="make">
    <echo>
    ==================================================
    Testing Flow N
    ==================================================
    outputfile: flow.n.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="flow.n.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.FlowNUnitTest" haltonfailure="no" outfile="flow.n"/>
    </junit>    
    <!--antcall target="in.case.flow.n.fails"/-->
  </target>

  <target name="unit.test.nine" depends="make">
    <echo>
    ==================================================
    Testing ASync with Correlation and EDN
    ==================================================
    outputfile: async.edn.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes" failureproperty="async.edn.fail">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.ASyncEDNTest" haltonfailure="no" outfile="async.edn"/>
    </junit>    
    <antcall target="in.case.async.edn.fails"/>
  </target>

  <target name="in.case.async.edn.fails" if="async.edn.fail">
    <!--exec dir="." osfamily="unix" executable="cat">
      <arg line="hwf.txt"/>
    </exec>
    <exec dir="." osfamily="windows" executable=".\dump.bat">
      <arg line="hwf.txt"/>
    </exec-->
    <fail message="ASync EDN correlation Test stopped the process">
      <condition>
        <equals arg1="${keep.testing}" arg2="false"/>
      </condition>
    </fail>
    <echo message="Moving on..."/>
  </target>

  <target name="EDN.load.test" depends="deploy.seven">
    <antcall target="EDN.one.shot.test">
      <param name="patch.string" value="one"/>
      <param name="patch.port"   value="1234"/>
    </antcall>
    <antcall target="EDN.one.shot.test">
      <param name="patch.string" value="two"/>
      <param name="patch.port"   value="2345"/>
    </antcall>
    <antcall target="EDN.one.shot.test">
      <param name="patch.string" value="three"/>
      <param name="patch.port"   value="3456"/>
    </antcall>
  </target>
  
  <target name="EDN.one.shot.test">
    <property name="ASYNC.TWO.WAYS" value="unittests.patterns.services.AsynchronousTwoWayUnitTest"/>
    <echo>
    =====================================
    Testing ASynchronous Two Ways Service
    With EDN Correlation - ${patch.string}
    =====================================
    outputfile: asynchronous.load.test
    </echo>
    <antcall target="search.replace">
      <param name="from"    value="edn-service-test-async-two-way.properties"/>
      <param name="to"      value="edn-service-test-async-two-way.temp.properties"/>
      <param name="search"  value=".template."/>
      <param name="replace" value=".${patch.string}."/>
    </antcall>
    <antcall target="search.replace">
      <param name="from"    value="edn-service-test-async-two-way.temp.properties"/>
      <param name="to"      value="edn-service-test-async-two-way.${patch.string}.properties"/>
      <param name="search"  value="1234"/>
      <param name="replace" value="${patch.port}"/>
    </antcall>
    <antcall target="search.replace">
      <param name="from"    value="generic-async.template.input.xml"/>
      <param name="to"      value="generic-async.${patch.string}.input.xml"/>
      <param name="search"  value="XXXX"/>
      <param name="replace" value="${patch.string}"/>
    </antcall>
    <antcall target="search.replace">
      <param name="from"    value="generic-async.template.output.xml"/>
      <param name="to"      value="generic-async.${patch.string}.output.xml"/>
      <param name="search"  value="XXXX"/>
      <param name="replace" value="${patch.string}"/>
    </antcall>
    <junit forkmode="perBatch" printsummary="yes" fork="yes" showoutput="yes" failureproperty="asynchronous.load.test.fail">
      <classpath refid="classpath.2"/>
      <formatter type="xml"/>
      <sysproperty key="verbose" value="${verbose}"/>
      <sysproperty key="properties.file.name" value="edn-service-test-async-two-way.${patch.string}.properties"/>
      <test name="${ASYNC.TWO.WAYS}" haltonfailure="no" outfile="asynchronous.load.test"/>
    </junit>    
    <!--antcall target="in.case.asynchronous.2.fails"/-->    
  </target>

  <target name="event.generator.test" depends="make,deploy.two">
    <echo>
    ===============================================
    Testing Business Event Raising from a Composite
    ===============================================
    outputfile: event2.txt
    </echo>
    <junit printsummary="yes" fork="yes" showoutput="yes">      
      <classpath refid="classpath"/>
      <formatter type="${test.output.type}"/>
      <test name="service.unit.testing.EventGeneratorService" haltonfailure="yes" outfile="event2"/>        
    </junit>    
  </target>

  <target name="search.replace">
    <java classpathref="classpath" classname="util.javautil.JavaUtilities" fork="yes">
      <arg value="${from}"/>
      <arg value="${to}"/>
      <arg value="${search}"/>
      <arg value="${replace}"/>
    </java>
  </target>
  
  <target name="report" depends="init,compile">
    <java classpathref="classpath" classname="report.Aggregator" fork="yes">
      <arg value="final-report.xml"/>
      <arg value="synchronous.xml"/>
      <arg value="asynchronous.xml"/>
      <arg value="asynchronous2.xml"/>
      <arg value="asynchronous2to.xml"/>
      <arg value="event.xml"/>
      <arg value="rules.xml"/>
      <arg value="flow.n.xml"/>
      <arg value="hwf.xml"/>
    </java>
    <!-- Now transform -->
    <java classpathref="classpath" classname="oracle.xml.parser.v2.oraxsl" fork="yes">
      <arg value="./final-report.xml"/>
      <arg value="report2html.xsl"/>
      <arg value="testreport.html"/>
    </java>    
    <java classpathref="classpath" classname="oracle.xml.parser.v2.oraxsl" fork="yes">
      <arg value="./final-report.xml"/>
      <arg value="report2text.xsl"/>
      <arg value="testreport.txt"/>
    </java>    
    <!-- Then display -->
    <exec dir="." executable="htmlview" osfamily="unix" spawn="yes">
      <arg value="testreport.html"/>
    </exec>
    <exec dir="." executable="${windows.browser.location}" osfamily="windows" spawn="yes">
      <arg value="testreport.html"/>
    </exec>
    <!--exec dir="." executable="cat">
      <arg value="testreport.txt"/>
    </exec-->
  </target>
  
  <target name="usage.help" description="Details of the components used for the various tests">
    <echo encoding="UTF-8">
    Business Event Testing
    ======================
    package.one, deploy.one, undeploy.one are necessary for Event testing.
    Corresponding test is unit.test.one
    
    Asynchronous Services Testing
    =============================
    package.five, deploy.five, undeploy.five are necessary for Asynchronous Service testing.
    Corresponding tests are 
    - unit.test.three (asynschronous one way)
    - unit.test.four (asynchronous two ways)
    - unit.test.seven (asynchronous two ways with timeout)
    
    Synchronous Service Testing
    ===========================
    package.five, deploy.five, undeploy.five are necessary for Synchronous Service testing.
    Corresponding test is unit.test.two
    
    Business Rules
    ==============
    package.three, deploy.three ,undeploy.three are necessary for Business Rules testing.
    Corresponding test is unit.test.five
  
    Human Workflow
    ==============
    package.four, deploy.four, undeploy.four are necessary for Human Workflow testing.   
    Corresponding test is unit.test.six   
  
    Flow N
    ======
    package.six, deploy.six, unit.test.eight, undeploy.six are necessary for FlowN testing.
    Corresponding test is unit.test.eight
    
    For details, use ant -f soa-validator.xml -verbose -projecthelp
    </echo>
  </target>
  
  <target name="help">
    <echo encoding="UTF-8">
      ==========================================================================
      Usage is:
        ant -f soa-validator.xml all
        ant -f soa-validator.xml deploy.all
        ant -f soa-validator.xml unit.test
        ant -f soa-validator.xml undeploy.all
        
      Also: Check out  
        ant -f soa-validator.xml usage.help
      
      Warning!  
      Configuration files to modify before running anything:
      - master.properties          
      
      All the following ones depend on it:
      - ldap.properties. 
      - server.properties
      - service-test-01.properties
      - service-test-02.properties
      - service-test-03.properties
      - service-test-04.properties
      - service-test-05.properties
      - event.properties
      
      Other sub-targets also exist:
      - all.for.events
      - all.for.synchronous
      - all.for.asynchronous.1
      - all.for.asynchronous.2
      - all.for.asynchronous.2.time.out
      - all.for.rules
      - all.for.hwf
      
      ... and more!
      For details, use ant -f soa-validator.xml -verbose -projecthelp
      
      ==========================================================================
      
      Note:
      1. The first time you run that script, keeping an eye on the console of the server 
         you are working on is probably a good idea.
      2. For the HumanWorkflow Task, sometime the test fails because the task has not
         been initialized yet. It happens to take some time for the plumbing to
         get moving...
         If that would be the case, try to re-run the test.
         Keep the sub-targets mentioned above in mind, that can help.                 
      3. Some environment variables need to be set:
         SOA_HOME - Contains the bin directory where the ant-sca-*.xml scripts live
         MW_HOME  - Contains user_projects, utils, wlserver_10.3, among others.
         MDS_INTEGRATION_HOME - Sometimes matches the JDEV_HOME variable.
                                Contains the integration directory where the MDS repositories are.
                                Typically the directory structure under MDS_INTEGRATION_HOME looks like this:
                                
                                MDS_INTEGRATION_HOME
                                 +- integration
                                 |   +- bpel
                                 |   +- bpm
                                 |   +- lib
                                 |   +- seed
                                 |      +- soa
                                 |          +- configuration
                                 |          +- shared
                                 |              +- activityguide
                                 |              +- ...
                                 |              +- workflow
                                 |                  +- *.edl
                                 |                  +- *.wsdl                                                    
                                 +- modules
                                     +- ...
         MDS_INTEGRATION_HOME must match the value of the ${oracle.home} mentionned in the adf-config.xml file,
         in the attribute :
         /adf-config/adf-mds-config/mds-config/persistence-config/metadata-store-usages/metadata-store-usage/metadata-store/property[./@name='metadata-path']/@value
         This file is located under the Composite (Application, Workspace) directory, in .adf/META-INF.
    </echo>
  </target>
  
</project>
 
 
Close
loading
Please Confirm
Close