blob: cbdcbc9e5791fb027459296c36dbd1c4116e8ba4 [file] [log] [blame]
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE project [
<!--
Copyright (c) 2017, 2018 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
http://www.eclipse.org/legal/epl-2.0.
This Source Code may also be made available under the following Secondary
Licenses when the conditions for such availability set forth in the
Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
version 2 with the GNU Classpath Exception, which is available at
https://www.gnu.org/software/classpath/license.html.
SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
-->
<!ENTITY commonSetup SYSTEM "../../../../config/properties.xml">
<!ENTITY commonBuild SYSTEM "../../../../config/common.xml">
<!ENTITY testproperties SYSTEM "build.properties">
]>
<project name="ejb-stubs-standaloneclient-App" default="usage" basedir=".">
&commonSetup;
&commonBuild;
&testproperties;
<target name="all" depends="build, run_default, run_cosnaming"/>
<target name="clean" depends="init-common">
<antcall target="clean-common"/>
</target>
<target name="build" depends="init-common">
<mkdir dir="${build.classes.dir}"/>
<echo message="common.xml: Compiling test source files" level="verbose"/>
<javac srcdir="client"
destdir="${build.classes.dir}"
classpath="${s1astest.classpath}:${build.classes.dir}"
debug="on"
failonerror="true"/>
</target>
<target name="runclient_nooverride" depends="init-common">
<java fork="on"
failonerror="true"
classpath="${env.S1AS_HOME}/lib/javaee.jar:${env.S1AS_HOME}/lib/gf-client.jar:${build.classes.dir}:${assemble.dir}/ejb-stubs-ejbappAppClient/ejb-stubs-ejbapp-clientClient.jar:${env.APS_HOME}/lib/reporter.jar"
classname="${simple.client}">
<jvmarg value="-Dorg.omg.CORBA.ORBInitialPort=${orb.port}"/>
<jvmarg value="-Dorg.glassfish.gmbal.no.multipleUpperBoundsException=true" />
<arg value="ejb/ejb_stubs_ejbapp_HelloBean"/>
<arg value="${ic.props}"/>
</java>
</target>
<!--This target is used to test that using no-arg InitialContext and
not setting any vm params will still work, assuming the default
port is set to 3700. Don't want to put this in the set of automatic
tests run b/c of the port change possibility. However, if the
default port of 3700 is set, this test should work. -->
<target name="runclient_setnothing" depends="init-common">
<java fork="on"
failonerror="true"
classpath="${env.S1AS_HOME}/lib/javaee.jar:${env.S1AS_HOME}/lib/gf-client.jar:${build.classes.dir}:${assemble.dir}/ejb-stubs-ejbappAppClient.jar:${env.APS_HOME}/lib/reporter.jar"
classname="${simple.client}">
<arg value="ejb/ejb_stubs_ejbapp_HelloBean"/>
</java>
</target>
<target name="run_default" depends="init-common">
<antcall target="runclient_nooverride">
<param name="ic.props"
value=""/>
</antcall>
</target>
<target name="run_serialcontext" depends="init-common">
<antcall target="runclient_nooverride">
<param name="ic.props"
value="jndi.properties.s1as8_default"/>
</antcall>
</target>
<target name="run_cosnaming" depends="init-common">
<antcall target="runclient_nooverride">
<param name="ic.props"
value="jndi.properties.cosnaming"/>
</antcall>
</target>
<target name="runclient_withoverride" depends="init-common">
<java fork="on"
failonerror="true"
classpath="${env.S1AS_HOME}/lib/javaee.jar:${env.S1AS_HOME}/lib/gf-client.jar:${build.classes.dir}:${assemble.dir}/ejb-stubs-ejbappAppClient.jar:${env.APS_HOME}/lib/reporter.jar"
classname="${simple.client}">
<jvmarg value="-Dorg.omg.CORBA.ORBInitialPort=${orb.port}"/>
<jvmarg
value="-Dcom.sun.ejb.portable.jndi.propertyfilename=jndi.properties.s1as8_default"/>
<jvmarg value="${jndi.clash}"/>
<arg value="ejb/ejb_stubs_ejbapp_HelloBean"/>
<arg value="jndi.properties.s1as8_default"/>
</java>
</target>
<target name="run_cosnaming_override" depends="init-common">
<antcall target="runclient_withoverride">
<param name="jndi.clash"
value="-Djava.naming.factory.initial=org.glassfish.jndi.cosnaming.CNCtxFactory"/>
</antcall>
</target>
<target name="run_foo_override" depends="init-common">
<antcall target="runclient_withoverride">
<param name="jndi.clash"
value="-Djava.naming.factory.initial=foo"/>
</antcall>
</target>
<target name="usage">
<antcall target="usage-common"/>
</target>
</project>