tests.xml revision 4978
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! CDDL HEADER START
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! The contents of this file are subject to the terms of the
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! Common Development and Distribution License, Version 1.0 only
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! (the "License"). You may not use this file except in compliance
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! with the License.
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! You can obtain a copy of the license at
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! trunk/opends/resource/legal-notices/OpenDS.LICENSE
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! or https://OpenDS.dev.java.net/OpenDS.LICENSE.
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! See the License for the specific language governing permissions
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! and limitations under the License.
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! When distributing Covered Code, include this CDDL HEADER in each
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! file and include the License file at
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable,
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! add the following below this CDDL HEADER, with the fields enclosed
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! by brackets "[]" replaced with your own identifying information:
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! Portions Copyright [yyyy] [name of copyright owner]
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! CDDL HEADER END
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher ! Copyright 2008-2009 Sun Microsystems, Inc.
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher Execute the tests.
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher </description>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <javac srcdir="${shared.dir}/java/parsingtool"
749cfb5d3270b5daf389d51a0dbd3fd2aec6e05dJakub Hrozek debug="true"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher debuglevel="lines,vars,source"
9aa117a93e315f790a1922d9ac7bd484878b621eJakub Hrozek <delete dir="${logs.dir}/specs" failonerror="false"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <java classpath="${shared.dir}/java/parsingtool"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher classname="GenerateOpenDSTestSpecs" fork="true">
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <!-- uncomment "agentlib" if need debugger waiting for you
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <jvmarg value="-agentlib:jdwp=transport=dt_socket,suspend=y,server=y,address=7778"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <format property="tests.run.time" pattern="yyyy.MM.dd-HH.mm.ss"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <!-- clean up tmp dir -->
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${tests.mode}" arg2="local"/>
9aa117a93e315f790a1922d9ac7bd484878b621eJakub Hrozek <!-- make all the necessary directories for this test run -->
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <mkdir dir="${tests.run.dir}/${tests.run.time}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <mkdir dir="${tests.run.dir}/${tests.run.time}/config"/>
ca344fdecdf127c80ad1074047aeba21e1165313Jakub Hrozek <!-- these will serve for after-the-fact archiving the logs -->
ca344fdecdf127c80ad1074047aeba21e1165313Jakub Hrozek <mkdir dir="${tests.run.dir}/${tests.run.time}/staf-logs"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${test.plan.custom}" arg2=""/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <var name="test.plan.custom" value="${test.plan.default}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <!-- generate the config file that will be used for this run -->
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher tofile="${tests.run.dir}/${tests.run.time}/config/${tests.config.file}">
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <expandproperties/>
749cfb5d3270b5daf389d51a0dbd3fd2aec6e05dJakub Hrozek </filterchain>
749cfb5d3270b5daf389d51a0dbd3fd2aec6e05dJakub Hrozek <!-- generate the topology files that will be used for this run -->
749cfb5d3270b5daf389d51a0dbd3fd2aec6e05dJakub Hrozek <copy todir="${tests.run.dir}/${tests.run.time}/config">
ca344fdecdf127c80ad1074047aeba21e1165313Jakub Hrozek <filterchain>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <expandproperties/>
9aa117a93e315f790a1922d9ac7bd484878b621eJakub Hrozek </filterchain>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <!-- this is a windows-specific measure to replace the windows file
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher separator by a forward slash. Staf otherwise fails to find the files. -->
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <replace file="${tests.run.dir}/${tests.run.time}/config/${tests.config.file}" token="\" value="/"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="tests.request" value="EXECUTE FILE ${tests.xml} JOBNAME OpenDS_${tests.type} SCRIPTFILE ${tests.run.dir}/${tests.run.time}/config/${tests.config.file} WAIT CLEARLOGS"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <echo>While the tests are running you may tail the job logs at</echo>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <echo>${staf.install.dir}/${staf.name}/logs/MACHINE/${host.name}</echo>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <echo>Running tests. This will take more than a while.</echo>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="CLASSPATH" value="${staf.lib.dir}/JSTAF.jar:."/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <env key="CLASSPATH" path="${staf.lib.dir}/JSTAF.jar:."/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <env key="LD_LIBRARY_PATH" value="${staf.lib.dir}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <env key="STAFCONVDIR" value="${staf.install.dir}/${staf.name}/codepage"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <symlink link="${tests.run.dir}/latest" resource="${tests.run.time}" overwrite="true"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Run the tests on the local machine or on a remote machine?"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="local"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher validargs="local,remote"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${local.hostname}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${tests.mode.input}" arg2="remote"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue=""
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <!-- Tests-defined values -->
a3c8390d19593b1e5277d95bfb4ab206d4785150Nikolai Kondrashov <available file="${basedir}/${tests.type}-${local.hostname.input}-${remote.hostname.input}.properties"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <var file="${basedir}/${tests.type}-${local.hostname.input}-${remote.hostname.input}.properties"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="remote.hostname.input" value="${local.hostname.input}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <!-- Tests-defined values -->
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <available file="${basedir}/${tests.type}-${local.hostname.input}.properties"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <var file="${basedir}/${tests.type}-${local.hostname.input}.properties"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${tests.type}" arg2="stress-tests"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${client.hostname}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter ldclt path (on client machine):"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${ldclt.dir}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="client.hostname.input" value="${client.hostname}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="ldclt.dir.input" value="${ldclt.dir}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter path to logs directory:"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${logs.dir}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter path to OpenDS archive:"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${opends.dir}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${opends.name}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${local.javahome}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${tests.mode.input}" arg2="remote" />
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter java home (on remote machine):"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${remote.javahome}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="remote.javahome.input" value="${local.javahome.input}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${tests.mode.input}" arg2="remote" />
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter directory instance directory (on remote machine):"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${tests.tmp.dir}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter directory instance directory:"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${tests.tmp.dir}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter OpenDMK lib directory:"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher addproperty="snmp.opendmk.lib.dir.input"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Use default directory instance?"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${tests.default}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher validargs="true,false"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${tests.default.input}" arg2="false"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${opends.port.ldap}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter OpenDS admin port:"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${opends.port.admin}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter OpenDS secure ldap port:"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${opends.port.ldaps}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter OpenDS admin DN (also called root DN):"
ca344fdecdf127c80ad1074047aeba21e1165313Jakub Hrozek defaultvalue="${opends.admin.dn}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Enter OpenDS admin password:"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${opends.admin.pwd}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="opends.port.ldap.input" value="${opends.port.ldap}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="opends.port.admin.input" value="${opends.port.admin}"/>
ca344fdecdf127c80ad1074047aeba21e1165313Jakub Hrozek <property name="opends.port.ldaps.input" value="${opends.port.ldaps}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="opends.admin.dn.input" value="${opends.admin.dn}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <property name="opends.admin.pwd.input" value="${opends.admin.pwd}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Run tests using verbose mode?"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="${verbose.mode}"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher validargs="true,false"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${test.plan.custom}" arg2=""/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <echo> No previous customized test plan found.</echo>
4fcc50e133f90cd4c5931a3ac48c84cb628b16fcMichal Zidek <echo> A previously customized test plan was detected:</echo>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Do you want to change the list of suites to run?"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher validargs="y,n"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="n"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher addproperty="prompt"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <input message=" Do you want to execute all the tests?"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher validargs="y,n"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher defaultvalue="y"
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher addproperty="answer"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <equals arg1="${tests.type}" arg2="functional-tests"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <var name="test.plan.custom" value="${test.plan.functional.default}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher <var name="test.plan.custom" value="${test.plan.stress.default}"/>
796463906a54e259bd5b582ce84af4297a58eafcStephen Gallagher excludes="quickstart,sample">
<property name="property.file" value="${tests.type}-${local.hostname.input}-${remote.hostname.input}.properties"/>
wc.type=tomcat
dest="${tests.tmp.dir}/coverage-instr"/>
tofile="${tests.tmp.dir}/coverage-instr/${opends.name}/lib/emma.jar"/>
<jvmarg value="-Demma.metadata.out.file=${tests.tmp.dir}/coverage-instr/${opends.name}/coverage.em" />
<arg value="${tests.tmp.dir}/coverage-instr/${opends.name}/lib/OpenDS.jar:${tests.tmp.dir}/coverage-instr/${opends.name}/lib/extensions/snmp-mib2605.jar" />
tofile="${tests.run.dir}/${tests.run.time}/coverage/coverage.em"/>
includes="${opends.name}/setup,${opends.name}/uninstall,${opends.name}/upgrade,${opends.name}/bin/*,${opends.name}/lib/*.sh"
<!-- <delete dir="${tests.tmp.dir}/coverage-instr"/> -->