| <?xml version="1.0" encoding="utf-8"?> |
| <!-- |
| * 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. |
| --> |
| <project name="testxsl" default="jar" basedir="."> |
| <description> |
| build.xml:$Revision$ |
| Ant 1.4.1+ build script for compiling and running Xalan-J tests. |
| |
| Note that this is a slightly unusual Ant build.xml file, since we |
| support both compiling/packaging the Xalan-J tests themselves, as |
| well as a number of targets designed to execute the tests once |
| they're built. |
| |
| In general the compilation targets (i.e. ones that compile the |
| test classes themselves) do list their dependencies explicitly. |
| Targets that serve to execute tests do not normally list any |
| dependencies - users must manually 'build jar' first. |
| |
| @author shane_curcuru@lotus.com |
| @see build.bat |
| |
| </description> |
| |
| <!-- Note: A number of property names may seem a little odd. I've |
| explicitly tried to reduce property name collisions between |
| this file and xml-xalan/java/build.xml to try to simplify |
| maintenance (or at least to separate the dev stuff from the |
| testing stuff). Suggestions for improvements (along with |
| maintenance strategies) accepted. |
| --> |
| |
| <!-- ================================================================== --> |
| <!-- Initialize: define various properties about locations, jars, etc. --> |
| <!-- ================================================================== --> |
| <!-- First, read in the user's own default properties, if they exist --> |
| <property name="local.properties" value="my.test.properties"/> |
| <property file="${local.properties}" /> |
| <!-- Then, read in the default checked-in properties --> |
| <property file="test.properties" /> |
| |
| <property name="compiler.target" value="1.3"/> |
| <property name="compiler.source" value="1.3"/> |
| |
| <property name="smoketest.conf.excludes" value="${smoketest.conf.normal.excludes};${smoketest.conf.supplemental.excludes}"/> |
| <property name="smoketest.xsltc.conf.excludes" value="${smoketest.xsltc.conf.normal.excludes};${smoketest.xsltc.conf.supplemental.excludes}"/> |
| <!-- Also provide environment properties with a special prefix which |
| allows us to detect if JARDIR is set. |
| --> |
| <property environment="ENV" /> |
| |
| <property name="year" value="2000-2014"/> |
| <!-- Properties related to compiling the tests --> |
| <property name="build.compiler" value="classic"/> |
| <property name="compiler" value="${build.compiler}"/> |
| <property name="debug" value="on"/> |
| |
| <!-- Specific locations related to building test code/docs --> |
| <property name="test.src.dir" value="java/src"/> |
| <property name="test.root" value="org/apache/qetest/"/> |
| <property name="test.dir" value="${test.src.dir}/${test.root}"/> |
| <property name="test.tools.dir" value="./tools"/> |
| <property name="test.build.dir" value="java/build"/> |
| <property name="test.build.docs" value="${test.build.dir}/docs"/> |
| <property name="test.build.apidocs" value="${test.build.docs}/apidocs"/> |
| <property name="tests.bugzilla.dir" value="tests/bugzilla"/> |
| <property name="tests.bugzilla.build.dir" value="tests/bugzilla/build"/> |
| <property name="tests.extensions.dir" value="${extensions.inputDir}/java"/> |
| <property name="tests.extensions.build.dir" value="${extensions.inputDir}/java/build"/> |
| |
| |
| <!-- Names/locations of .jar files we build --> |
| <property name="testxsl.jar.name" value="testxsl.jar"/> |
| <property name="qetest.jar.name" value="qetest.jar"/> |
| <property name="testxsl.jar" value="${test.build.dir}/${testxsl.jar.name}"/> |
| <property name="qetest.jar" value="${test.build.dir}/${qetest.jar.name}"/> |
| |
| <!-- Specific locations related to Xalan code, which should be in a sister tree to us --> |
| <property name="xalan.relpath" value="../java"/> |
| <property name="xalan.lib.dir" value="${xalan.relpath}/lib"/> |
| <property name="xalan.endorsed.dir" value="${xalan.lib.dir}/endorsed"/> |
| <property name="xalan.tools.dir" value="${xalan.relpath}/tools"/> |
| <property name="xalan.build.dir" value="${xalan.relpath}/build"/> |
| <property name="xalan.xdocs.dir" value="${xalan.relpath}/xdocs"/> |
| <property name="xalan.generator.styletargz" value="${xalan.xdocs.dir}/xml-site-style.tar.gz"/> |
| |
| <!-- Various names/locations of dependent jars --> |
| <property name="xalan.jar" value="${xalan.build.dir}/xalan.jar"/> |
| <property name="xalan.unbundled.jar" |
| value="${xalan.build.dir}/xalan-unbundled.jar"/> |
| <property name="xsltc.jar" value="${xalan.build.dir}/xsltc.jar"/> |
| <property name="ser.jar" value="${xalan.build.dir}/serializer.jar"/> |
| <property name="xml-apis.jar" value="${xalan.endorsed.dir}/xml-apis.jar"/> |
| <property name="parserjar" value="${xalan.endorsed.dir}/xercesImpl.jar"/> |
| <property name="bcel.jar" value="${xalan.lib.dir}/BCEL.jar"/> |
| |
| <!-- JTidy is used by the XSLTC comparator --> |
| <property name="jtidy.jar" value="${test.tools.dir}/Tidy.jar"/> |
| |
| <!-- The js.jar is for Javascript extensions tests; you must get this .jar yourself. |
| Feel free to reset the location. --> |
| <property name="js.jar" value="../../js.jar"/> |
| |
| <!-- The Bean Scripting Framework is required for extensions written in languages |
| other than Java. Xalan Java will attempt to use the Jakarta BSF implementation |
| by default (see the "extensions" target). |
| bsf.jar is no longer distributed with Xalan Java; you must get this .jar yourself. |
| For more information, see the Apache Jakarta project, http://jakarta.apache.org/ |
| Feel free to reset the location. --> |
| <property name="bsf.jar" value="../../bsf.jar"/> |
| |
| <!-- Documentation-specific files and locations --> |
| <property name="stylebook.jar" value="${xalan.tools.dir}/stylebook-1.0-b3_xalan-2.jar"/> |
| <property name="doclet.jar" value="${xalan.tools.dir}/xalan2jdoc.jar"/> |
| <property name="test.xdocs.dir" value="java/xdocs"/> |
| <property name="test.generator.styletar" value="${test.xdocs.dir}/xml-site-style.tar"/> |
| <property name="test.xdocs.book" value="${test.xdocs.dir}/sources/xalantest.xml"/> |
| <property name="test.xdocs.style" value="${test.xdocs.dir}/style"/> |
| <property name="doc.generator" value="org.apache.stylebook.StyleBook"/> |
| <path id="test.docs.class.path"> |
| <pathelement location="${stylebook.jar}" /> |
| <pathelement location="${doclet.jar}" /> |
| <pathelement location="${jtidy.jar}" /> |
| <pathelement location="${xalan.jar}" /> |
| <pathelement location="${ser.jar}" /> |
| <pathelement location="${xml-apis.jar}" /> |
| <pathelement location="${parserjar}" /> |
| <pathelement path="${java.class.path}" /> |
| </path> |
| |
| <!-- Note: given that many of the tests interact with xerces and |
| xalan classes, and that Ant may use these classes (especially parser |
| ones) I've found it's best to fork the tests. |
| Later I'd like to give the user the option to fork or not, since |
| while forking is slower and problematic on some systems, it is |
| also a safer testing environment (since the Ant classes and the |
| parser aren't already loaded, etc.) |
| --> |
| <property name="fork-tests" value="yes"/> |
| <!-- Property to have the Ant build fail when a test has an |
| error (not necessarily a fail). Needs improvement. |
| --> |
| <property name="fail-on-error" value="yes"/> |
| |
| <!-- ================================================================== --> |
| <!-- Initialize: define classpaths for use within specific targets --> |
| <!-- ================================================================== --> |
| <!-- Classpath used when compiling tests --> |
| <path id="compiletest.class.path"> |
| <pathelement path="${java.class.path}" /> |
| <pathelement location="${xalan.jar}" /> |
| <pathelement location="${xsltc.jar}" /> <!-- add this so we can test the |
| separate jar distribution --> |
| <pathelement location="${ser.jar}" /> |
| <pathelement location="${xml-apis.jar}" /> |
| <pathelement location="${parserjar}" /> |
| <pathelement location="${jtidy.jar}" /> |
| </path> |
| |
| <!-- Classpath used when running API tests --> |
| <path id="api.class.path"> |
| <pathelement path="${java.class.path}" /> |
| <pathelement location="${xalan.jar}" /> |
| <pathelement location="${ser.jar}" /> |
| <pathelement location="${xml-apis.jar}" /> |
| <pathelement location="${parserjar}" /> |
| <pathelement location="${testxsl.jar}" /> |
| <pathelement location="${jtidy.jar}" /> |
| </path> |
| |
| <!-- Classpath used when running conf or conformance tests --> |
| <path id="conf.class.path"> |
| <pathelement path="${java.class.path}" /> |
| <pathelement location="${xalan.jar}" /> |
| <pathelement location="${ser.jar}" /> |
| <pathelement location="${xml-apis.jar}" /> |
| <pathelement location="${parserjar}" /> |
| <pathelement location="${testxsl.jar}" /> |
| <pathelement location="${jtidy.jar}" /> |
| </path> |
| |
| <!-- Boot class path for JDK 1.4. Order is important to ensure |
| GUMP builds work correctly, and people who don't use the |
| build.bat/build.sh can still build on JDK 1.4 as normal. --> |
| <path id="boot.class.path"> |
| <pathelement location="${xalan.jar}" /> |
| <pathelement location="${xsltc.jar}" /> <!-- add this so we can test the |
| separate jar distribution --> |
| <pathelement location="${ser.jar}" /> |
| <pathelement location="${java.class.path}" /> |
| <pathelement location="${xml-apis.jar}" /> |
| <pathelement location="${parserjar}" /> |
| </path> |
| |
| <!-- Gump build xml-xalan2-smoketest should use xalan.unbundled.jar --> |
| <path id="boot.class.path.gump"> |
| <pathelement location="${sun.boot.class.path}" /> |
| </path> |
| |
| <!-- Classpath used when running perf or performance tests --> |
| <path id="perf.class.path"> |
| <path refid="conf.class.path" /> |
| </path> |
| |
| <!-- Classpath used when running EXSLT tests --> |
| <path id="exslt.class.path"> |
| <path refid="conf.class.path" /> |
| </path> |
| |
| <!-- Classpath used when running contrib or user-contributed tests --> |
| <path id="contrib.class.path"> |
| <path refid="conf.class.path" /> |
| </path> |
| |
| <!-- Classpath used when running Bugzilla tests --> |
| <path id="bugzilla.class.path"> |
| <path refid="api.class.path" /> |
| <pathelement location="${tests.bugzilla.build.dir}" /> |
| </path> |
| |
| <!-- Classpath used when running extensions tests --> |
| <path id="extensions.class.path"> |
| <path refid="api.class.path" /> |
| <pathelement location="${bsf.jar}" /> |
| <pathelement location="${js.jar}" /> |
| <pathelement location="${tests.extensions.build.dir}" /> |
| <!-- Add more pathelements if we add more Java extensions dirs --> |
| </path> |
| |
| <!-- Classpath used when build/running xslt20 XPath 2.0 RWAPI tests --> |
| <path id="rwapitest.class.path"> |
| <path refid="api.class.path" /> |
| <pathelement location="${xalan.build.dir}/xpathapi.jar" /> |
| </path> |
| |
| <!-- ================================================================== --> |
| <!-- Initialize: Define an Ant task that executes Xalan test automation --> |
| <!-- ================================================================== --> |
| <taskdef name="xalantest" classname="org.apache.qetest.xsl.XSLTestAntTask"> |
| <classpath> |
| <pathelement path="${java.class.path}" /> |
| <!-- Needed so this build file can run: this refers to |
| a precompiled version of XSLTestAntTask.class that |
| is checked in: normally at runtime, it should come |
| from the testxsl.jar file instead of below. |
| --> |
| <pathelement location="${test.src.dir}" /> |
| <pathelement location="${test.build.dir}" /> |
| <pathelement location="${testxsl.jar}" /> |
| </classpath> |
| </taskdef> |
| |
| <!-- ================================================================== --> |
| <!-- Base target for running tests with specified properties. Actual --> |
| <!-- work is handled by dependent tasks, at most one of which should be --> |
| <!-- executed. --> |
| <!-- ================================================================== --> |
| <target name="run.xalantest" depends="run.xalantest.default,run.xalantest.transfact"/> |
| |
| <target name="run.xalantest.default" unless="sysprop.transfact" > |
| <antcall target="run.xalantest.default.gump"/> |
| <antcall target="run.xalantest.default.normal"/> |
| </target> |
| |
| <target name="run.xalantest.default.gump" if="gump" > |
| <xalantest test="${testClass}" |
| testType="${testType}" |
| classpathref="${xalantest.classpathref}" |
| bootclasspathref="boot.class.path.gump" |
| fork="${fork-tests}" |
| failonerror="${fail-on-error}" /> |
| </target> |
| |
| <target name="run.xalantest.default.normal" unless="gump" > |
| <xalantest test="${testClass}" |
| testType="${testType}" |
| classpathref="${xalantest.classpathref}" |
| bootclasspathref="boot.class.path" |
| fork="${fork-tests}" |
| failonerror="${fail-on-error}" /> |
| </target> |
| |
| <target name="run.xalantest.transfact" if="sysprop.transfact" > |
| <antcall target="run.xalantest.transfact.gump"/> |
| <antcall target="run.xalantest.transfact.normal"/> |
| </target> |
| |
| <target name="run.xalantest.transfact.gump" if="gump"> |
| <xalantest test="${testClass}" |
| testType="${testType}" |
| classpathref="${xalantest.classpathref}" |
| bootclasspathref="boot.class.path.gump" |
| fork="${fork-tests}" |
| failonerror="${fail-on-error}" > |
| <!-- Explicitly set TransformerFactory property to use --> |
| <sysproperty key="javax.xml.transform.TransformerFactory" |
| value="${sysprop.transfact}" /> |
| </xalantest> |
| </target> |
| |
| <target name="run.xalantest.transfact.normal" unless="gump"> |
| <xalantest test="${testClass}" |
| testType="${testType}" |
| classpathref="${xalantest.classpathref}" |
| bootclasspathref="boot.class.path" |
| fork="${fork-tests}" |
| failonerror="${fail-on-error}" > |
| <!-- Explicitly set TransformerFactory property to use --> |
| <sysproperty key="javax.xml.transform.TransformerFactory" |
| value="${sysprop.transfact}" /> |
| </xalantest> |
| </target> |
| |
| <target name="run.xalan-extension-test" > |
| <antcall target="run.xalan-extension-test.gump"/> |
| <antcall target="run.xalan-extension-test.normal"/> |
| </target> |
| |
| <target name="run.xalan-extension-test.gump" if="gump"> |
| <xalantest test="${testClass}" |
| testType="${testType}" |
| classpathref="${xalantest.classpathref}" |
| bootclasspathref="boot.class.path.gump" |
| fork="${fork-tests}" |
| failonerror="${fail-on-error}" > |
| <sysproperty key="org.apache.xalan.extensions.bsf.BSFManager" |
| value="${sysprop.BSFManager}" /> |
| </xalantest> |
| </target> |
| |
| <target name="run.xalan-extension-test.normal" unless="gump"> |
| <xalantest test="${testClass}" |
| testType="${testType}" |
| classpathref="${xalantest.classpathref}" |
| bootclasspathref="boot.class.path" |
| fork="${fork-tests}" |
| failonerror="${fail-on-error}" > |
| <sysproperty key="org.apache.xalan.extensions.bsf.BSFManager" |
| value="${sysprop.BSFManager}" /> |
| </xalantest> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Initialize: setup for compiling, doc building, running tests --> |
| <!-- ================================================================== --> |
| <target name="init.test" |
| description="Prepare timestamp, echo version for debugging"> |
| <echo message="Using parserjar ${parserjar} build.xml:$Revision$" /> |
| <tstamp /> |
| </target> |
| |
| <target name="init.build" depends="init.test" |
| description="Prepare build output tree, copy prebuilts"> |
| <!-- Note this is case-sensitive, even on Windows! --> |
| <!-- Note JARDIR support should probably be removed, since it's a maintenance hassle Jul-02 -sc --> |
| <echo message="Your ==JARDIR== is set to ==${ENV.JARDIR}==" /> |
| <echo message="JVM Classpath is ${java.class.path}" /> |
| <mkdir dir="${test.build.dir}" /> |
| <mkdir dir="${test.build.dir}/${test.root}" /> |
| <!-- Also copy over precompiled external processor wrapper classes --> |
| <copy todir="${test.build.dir}/${test.root}/xslwrapper" > |
| <fileset dir="${test.dir}xslwrapper"> |
| <include name="**/*.class" /> |
| <include name="**/*.properties" /> |
| </fileset> |
| </copy> |
| <!-- Also copy over precompiled Ant class (why do we suddenly need this? -sc) --> |
| <copy todir="${test.build.dir}/${test.root}/xsl" > |
| <fileset dir="${test.dir}xsl"> |
| <include name="**/*.class" /> |
| </fileset> |
| </copy> |
| </target> |
| |
| <target name="init.docs" depends="init.build" |
| description="Prepare output tree for documentation"> |
| <mkdir dir="${test.build.apidocs}" /> |
| <!-- Copy the Xalan-specific version of doc files and untargz them --> |
| <gunzip src="${xalan.generator.styletargz}" dest="${test.generator.styletar}"/> |
| <untar src="${test.generator.styletar}" dest="${test.xdocs.dir}"/> |
| <delete file="${test.generator.styletar}"/> |
| </target> |
| |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: the normal StylesheetTestletDriver on the conf suite --> |
| <!-- ================================================================== --> |
| <target name="conf" description="Run TestletDriver over the conf tree" |
| depends="init.test"> |
| <!-- Set the default conformance test driver, user may override --> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan conf test: ${testClass}" /> |
| <property name="testType" value="conf." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="conf.class.path" /> |
| </antcall> |
| <property name="scan.outputDir" value="${conf.outputDir}"/> |
| <antcall target="scan"/> |
| </target> |
| |
| <target name="conf.dom" description="Run TestletDriver over conf with DOM excludes"> |
| <antcall target="conf"> |
| <param name="conf.excludes" value="${trax.dom.excludes}"/> |
| <param name="conf.flavor" value="trax.dom"/> |
| </antcall> |
| </target> |
| |
| <target name="conf.one" description="Run a single conf test"> |
| <antcall target="conf"> |
| <param name="testClass" value="org.apache.qetest.xsl.StylesheetDriver" /> |
| </antcall> |
| </target> |
| |
| <target name="conf.xsltc.dom" description="Run TestletDriver over conf with DOM excludes"> |
| <antcall target="conf.xsltc"> |
| <param name="conf.xsltc.excludes" value="${trax.dom.excludes}"/> |
| <param name="conf.xsltc.flavor" value="trax.dom"/> |
| </antcall> |
| </target> |
| |
| <target name="conf.trace" description="Run TestletDriver over the conf tree"> |
| <property name="conf.trace" value="on"/> |
| <antcall target="conf"/> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: the normal StylesheetTestletDriver on the EXSLT suite --> |
| <!-- ================================================================== --> |
| <target name="exslt" description="Run TestletDriver over the exslt tree" |
| depends="init.test"> |
| <!-- Set the default conformance test driver, user may override --> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan exslt test: ${testClass}" /> |
| <property name="testType" value="exslt." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="exslt.class.path" /> |
| </antcall> |
| <property name="scan.outputDir" value="${exslt.outputDir}"/> |
| <antcall target="scan"/> |
| </target> |
| |
| <target name="exslt.dom" description="Run TestletDriver over exslt with DOM excludes"> |
| <antcall target="exslt"> |
| <param name="exslt.excludes" value="${trax.dom.excludes}"/> |
| <param name="exslt.flavor" value="trax.dom"/> |
| </antcall> |
| </target> |
| |
| <target name="exslt.one" description="Run a single exslt test"> |
| <antcall target="exslt"> |
| <param name="testClass" value="org.apache.qetest.xsl.StylesheetDriver" /> |
| </antcall> |
| </target> |
| |
| <target name="exslt.xsltc.dom" description="Run TestletDriver over exslt with DOM excludes"> |
| <antcall target="exslt.xsltc"> |
| <param name="exslt.xsltc.excludes" value="${trax.dom.excludes}"/> |
| <param name="exslt.xsltc.flavor" value="trax.dom"/> |
| </antcall> |
| </target> |
| |
| <target name="exslt.trace" description="Run TestletDriver over the conf tree"> |
| <property name="exslt.trace" value="on"/> |
| <antcall target="exslt"/> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: the normal StylesheetTestletDriver on the accept suite --> |
| <!-- ================================================================== --> |
| <target name="accept" description="Run TestletDriver over the accept tree"> |
| <echo message="Executing Xalan accept test." /> |
| <property name="qetest.summaryFile" value="Accept.xml" /> |
| <property name="testType" value="accept." /> |
| <property name="scan.outputDir" value="${accept.outputDir}"/> |
| <antcall target="conf"/> |
| </target> |
| |
| <target name="accept.xsltc" description="Run TestletDriver over the accept tree"> |
| <property name="testType" value="accept.xsltc." /> |
| <property name="qetest.summaryFile" value="Accept.xml" /> |
| <property name="scan.outputDir" value="${accept.xsltc.outputDir}"/> |
| <property name="use-processor" value="${accept.xsltc.processor}"/> |
| <antcall target="conf.xsltc" /> |
| </target> |
| |
| <target name="accept.trace" description="Run TestletDriver over the accept tree"> |
| <property name="accept.trace" value="on"/> |
| <antcall target="accept"/> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: the StylesheetErrorTestlet on the conferr suite --> |
| <!-- ================================================================== --> |
| <target name="conferr" description="Run TestletDriver over the conferr negative test tree" |
| depends="init.test"> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan conf test: ${testClass}" /> |
| <property name="testType" value="conferr." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="conf.class.path" /> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${conferr.outputDir}"/> |
| </antcall> |
| </target> |
| |
| |
| <target name="conferr.xsltc" description="Run TestletDriver over the conferr negative test tree" depends="init.test"> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan conferr test-xsltc: ${testClass}" /> |
| <property name="testType" value="conferr.xsltc." /> |
| |
| <!-- Set indent-number to 0 to match Xalan's default indentation --> |
| <property name="${testType}Processor.setAttribute.indent-number" value="0" /> |
| |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="conf.class.path" /> |
| <!-- Explicitly set TransformerFactory property to use xsltc --> |
| <param name="sysprop.transfact" |
| value="org.apache.xalan.xsltc.trax.TransformerFactoryImpl" /> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${conferr.xsltc.outputDir}" /> |
| </antcall> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: the normal StylesheetTestletDriver on the perf suite --> |
| <!-- ================================================================== --> |
| <target name="perf" description="Run TestletDriver over the perf tree" |
| depends="init.test"> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan perf test: ${testClass}" /> |
| <property name="testType" value="perf." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="perf.class.path" /> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${perf.outputDir}"/> |
| </antcall> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: the normal StylesheetTestletDriver on the contrib suite --> |
| <!-- ================================================================== --> |
| <target name="contrib" description="Run TestletDriver over the contrib tree" |
| depends="init.test"> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan contrib test: ${testClass}" /> |
| <property name="testType" value="contrib." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="contrib.class.path" /> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${contrib.outputDir}"/> |
| </antcall> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: the ThreadedTestletDriver on threads.filelist --> |
| <!-- ================================================================== --> |
| <target name="threads" description="Run ThreadedTestletDriver on threads.filelist" |
| depends="init.test"> |
| <!-- Set special threaded test driver and filelist, user may override --> |
| <property name="testClass" value="org.apache.qetest.xsl.ThreadedTestletDriver" /> |
| <echo message="Executing Xalan threads test: ${testClass}" /> |
| <property name="testType" value="threads." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="api.class.path" /> |
| </antcall> |
| </target> |
| |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: a specific named API test --> |
| <!-- ================================================================== --> |
| <target name="api" description="Run a specific API test" |
| depends="init.test"> |
| <!-- Note no default is set; also testClass is not prefixed! --> |
| <echo message="Executing Xalan api test: ${testClass}" /> |
| <property name="testType" value="api." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="api.class.path" /> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${api.outputDir}"/> |
| </antcall> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: Run all available API tests --> |
| <!-- ================================================================== --> |
| <target name="harness" description="Run all listed API harness.tests"> |
| <antcall target="api"> |
| <param name="testClass" value="org.apache.qetest.xsl.XSLTestHarness"/> |
| <param name="qetest.tests" value="${harness.tests}"/> |
| <!-- Below line is in case we run ThreadedTestletDriver --> |
| <param name="qetest.testlet" value="${harness.threads.testlet}"/> |
| <param name="qetest.fileList" value="${harness.threads.fileList}"/> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${api.outputDir}"/> |
| </antcall> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: all Bugzilla testlets to regress bugs --> |
| <!-- ================================================================== --> |
| <target name="bugzilla" description="Run all Bugzilla Testlets and tests to regress bugs" |
| depends="init.test"> |
| <echo message="Executing Xalan Bugzilla Testlets and tests to regress bugs" /> |
| <property name="testClass" value="org.apache.qetest.xsl.BugzillaTestletDriver" /> |
| <property name="testType" value="bugzilla." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="bugzilla.class.path" /> |
| </antcall> |
| <echo message="If you got ClassNotFound, did you 'build bugzilla.classes' first?" /> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: various extensions tests --> |
| <!-- ================================================================== --> |
| <target name="extensions" |
| description="Run extensions tests. |
| Non-Java extensions will use the Jakarta BSF implementation." |
| depends="init.test"> |
| <echo message="Executing Xalan extensions tests. Non-Java extensions will use the Jakarta BSF implementation." /> |
| <!-- Set the default conformance test driver, user may |
| override; note test.properties:extensions.testlet= |
| --> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <property name="testType" value="extensions." /> |
| <antcall target="run.xalan-extension-test"> |
| <param name="xalantest.classpathref" value="extensions.class.path" /> |
| <param name="sysprop.BSFManager" value="org.apache.bsf.BSFManager" /> |
| </antcall> |
| <property name="scan.outputDir" value="${extensions.outputDir}"/> |
| <antcall target="scan"/> |
| <echo message="If you got ClassNotFound, did you 'build extensions.classes' first?" /> |
| </target> |
| |
| <target name="extensions-with-ibm-bsf" |
| description="Run extensions tests. |
| Non-Java extensions will use the IBM BSF implementation." |
| depends="init.test"> |
| <echo message="Executing Xalan extensions tests. Non-Java extensions will use the IBM BSF implementation." /> |
| <!-- Set the default conformance test driver, user may |
| override; note test.properties:extensions.testlet= |
| --> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <property name="testType" value="extensions.with-ibm-bsf." /> |
| <property name="scan.outputDir" value="${extensions.with-ibm-bsf.outputDir}"/> |
| |
| <antcall target="run.xalan-extension-test"> |
| <param name="extensions.outputDir" value="${extensions.with-ibm-bsf.outputDir}" /> |
| <param name="xalantest.classpathref" value="extensions.class.path" /> |
| <param name="sysprop.BSFManager" value="com.ibm.bsf.BSFManager" /> |
| </antcall> |
| <antcall target="scan"/> |
| <echo message="If you got ClassNotFound, did you 'build extensions.classes' first?" /> |
| </target> |
| |
| <target name="rwapi" description="Run TestletDriver with xslt20 XPath2.0 RWAPI tests" |
| depends="init.test,compile.rwapi,jar"> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan conf test: ${testClass}" /> |
| <property name="testType" value="conf." /> |
| <property name="conf.testlet" value="org.apache.qetest.rwapi.XPathASTTestlet" /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" value="rwapitest.class.path" /> |
| </antcall> |
| <property name="scan.outputDir" value="${conf.outputDir}"/> |
| <antcall target="scan"/> |
| </target> |
| <!-- ================================================================== --> |
| <!-- Run tests: Run the Xalan-J 2.x Minitest --> |
| <!-- ================================================================== --> |
| <!-- This target doesn't actually do anything itself - it merely |
| depends on other targets, in order, to first run the whole |
| Minitest, then to log to Ant whether the test didn't pass |
| (i.e. failed, incomplete, error or ambiguous) or passed. |
| --> |
| <target name="minitest" |
| description="Run the Xalan-J 2.x Minitest" |
| depends="minitest-execute,minitest-notpass,minitest-pass"> |
| </target> |
| |
| <target name="minitest.gump" |
| description="Compile and Run the Xalan-J 2.x Minitest" |
| depends="jar"> |
| <antcall target="minitest"> |
| <param name="gump" value="boot.class.path.gump"/> |
| </antcall> |
| </target> |
| <target name="minitest-execute"> |
| <echo message="About to execute the Minitest..." /> |
| <antcall target="api"> |
| <param name="testClass" value="org.apache.qetest.trax.Minitest"/> |
| <param name="testType" value="minitest."/> |
| </antcall> |
| <available file="${minitest.passFile}" property="minitest-passed" /> |
| </target> |
| <target name="minitest-notpass" unless="minitest-passed"> |
| <echo message=" [minitest] ERROR! The Minitest failed!" /> |
| <echo message=" [minitest] See details in ${minitest.logFile}, output is in ${minitest.outputDir}" /> |
| <echo message=" [minitest] Please fix any Minitest problems before checking in!" /> |
| <fail message="Please fix any Minitest problems before checking in!" /> |
| </target> |
| <target name="minitest-pass" if="minitest-passed"> |
| <echo message=" [minitest] CONGRATULATIONS! The Minitest passed!" /> |
| <echo message=" [minitest] See details in ${minitest.logFile}" /> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: Run the Xalan-J 2.x Smoketest, including several tests --> |
| <!-- Note: this target is frequently called from outside of this file! --> |
| <!-- ================================================================== --> |
| <target name="smoketest" |
| description="Run the Xalan-J 2.x Smoketest" |
| depends="minitest-execute,extensions.classes,smoketest-execute,minitest-notpass,minitest-pass,smoketest-notpass,smoketest-pass"> |
| </target> |
| <target name="smoketest.xsltc" |
| description="Run the Xalan-J 2.x XSLTC Smoketest" |
| depends="smoketest.xsltc-execute,smoketest.xsltc-notpass,smoketest.xsltc-pass"> |
| </target> |
| <target name="smoketest.dev" |
| description="Run the Xalan-J 2.x Smoketest with dependencies" |
| depends="jar,minitest-execute,extensions.classes,smoketest-execute,minitest-notpass,minitest-pass,smoketest-notpass,smoketest-pass"> |
| <!-- This compiles the minimum to run the smoketests, runs them, |
| and creates distros just of the results and existing tree, |
| without actually running the docs - this is to ensure that |
| doc build errors in the tests won't affect GUMP runs. |
| --> |
| </target> |
| <target name="smoketest.gump" |
| description="Run the Xalan-J 2.x Smoketest in automated builds with dependencies"> |
| <antcall target="minitest.gump"> |
| <param name="gump" value="boot.class.path.gump"/> |
| </antcall> |
| <antcall target="extensions.classes"/> |
| <antcall target="smoketest-execute.gump"> |
| <param name="gump" value="boot.class.path.gump"/> |
| </antcall> |
| |
| <!-- This compiles the minimum to run the smoketests, runs them, |
| and creates distros just of the results and existing tree, |
| without actually running the docs - this is to ensure that |
| doc build errors in the tests won't affect GUMP runs. |
| --> |
| </target> |
| |
| <!-- This target smoketest-execute.gump is a subtarget which is called |
| from smoketest.gump. |
| --> |
| <target name="smoketest-execute.gump" |
| description="Run the Xalan-J 2.x Smoketest for Gump build " |
| depends="smoketest-execute,smoketest-results-dist,dist-nodeps, |
| smoketest-notpass,smoketest-pass"> |
| </target> |
| |
| <target name="smoketest-execute"> |
| <echo message="About to execute Conformance tests..." /> |
| <antcall target="conf"> |
| <param name="testType" value="smoketest.conf."/> |
| </antcall> |
| |
| <echo message="About to execute Accept tests..." /> |
| <antcall target="accept"> |
| <param name="testType" value="smoketest.accept."/> |
| </antcall> |
| |
| <echo message="About to execute other API tests..." /> |
| <antcall target="api"> |
| <param name="testClass" value="org.apache.qetest.xsl.XSLTestHarness"/> |
| <param name="testType" value="smoketest.api."/> |
| </antcall> |
| |
| <echo message="About to execute XalanJ2 extensions tests..." /> |
| <antcall target="extensions"> |
| <param name="testType" value="smoketest.extensions."/> |
| </antcall> |
| |
| <condition property="smoketest-passed"> |
| <and> |
| <available file="${smoketest.conf.passFile}" /> |
| <available file="${smoketest.accept.passFile}" /> |
| <available file="${smoketest.api.passFile}" /> |
| <available file="${smoketest.extensions.passFile}" /> |
| </and> |
| </condition> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="smoketest"/> |
| </antcall> |
| </target> |
| |
| <target name="smoketest.xsltc-execute"> |
| <echo message="About to execute Conformance tests..." /> |
| <antcall target="conf.xsltc"> |
| <param name="testType" value="smoketest.xsltc.conf."/> |
| </antcall> |
| |
| <echo message="About to execute Accept tests..." /> |
| <antcall target="accept.xsltc"> |
| <param name="testType" value="smoketest.xsltc.accept."/> |
| </antcall> |
| |
| <condition property="smoketest.xsltc-passed"> |
| <and> |
| <available file="${smoketest.xsltc.conf.passFile}" /> |
| <available file="${smoketest.xsltc.accept.passFile}" /> |
| </and> |
| </condition> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="smoketest.xsltc"/> |
| </antcall> |
| </target> |
| |
| <target name="smoketest-notpass" unless="smoketest-passed"> |
| <echo message=" [minitest] ERROR! The Smoketest failed!" /> |
| <echo message=" [minitest] See details in ${smoketest.conf.logFile}, output is in ${smoketest.conf.outputDir}" /> |
| <echo message=" [minitest] See details in ${smoketest.api.logFile}, output is in ${smoketest.api.outputDir}" /> |
| <echo message=" [minitest] See details in ${smoketest.extensions.logFile}, output is in ${smoketest.extensions.outputDir}" /> |
| <echo message=" [minitest] Please fix any smoketest problems before checking in!" /> |
| <fail message="Please fix any smoketest problems before checking in!" /> |
| </target> |
| <target name="smoketest-pass" if="smoketest-passed"> |
| <echo message=" [minitest] CONGRATULATIONS! The Smoketest passed!" /> |
| <echo message=" [minitest] Details are in ${smoketest.conf.logFile}, ${smoketest.api.logFile}, ${smoketest.extensions.logFile}" /> |
| </target> |
| |
| <target name="smoketest.xsltc-notpass" unless="smoketest.xsltc-passed"> |
| <echo message=" [minitest] ERROR! The Smoketest failed!" /> |
| <echo message=" [minitest] See details in ${smoketest.xsltc.conf.logFile}, output is in ${smoketest.xsltc.conf.outputDir}" /> |
| <echo message=" [minitest] See details in ${smoketest.xsltc.accept.logFile}, output is in ${smoketest.xsltc.accept.outputDir}" /> |
| <echo message=" [minitest] Please fix any smoketest problems before checking in!" /> |
| <fail message="Please fix any smoketest problems before checking in!" /> |
| </target> |
| <target name="smoketest.xsltc-pass" if="smoketest.xsltc-passed"> |
| <echo message=" [minitest] CONGRATULATIONS! The Smoketest passed!" /> |
| <echo message=" [minitest] Details are in ${smoketest.xsltc.conf.logFile}, ${smoketest.xsltc.accept.logFile}" /> |
| </target> |
| |
| <target name="smoketest-results-dist" depends="init.test"> |
| <property name="tarzip-backref" value="../.."/> |
| <property name="tarzip-fwdref" value="xml-xalan/test"/> |
| <!-- tar.gz the automation and batch files, etc. --> |
| <!-- # smoketest parent output location: used in test.properties/build.xml --> |
| <tar tarfile="${test.build.dir}/xalan-smoketest-${DSTAMP}.tar"> |
| <tarfileset dir="${tarzip-backref}"> |
| <include name="${tarzip-fwdref}/${smoketest.outputDir}/"/> |
| </tarfileset> |
| </tar> |
| <gzip src="${test.build.dir}/xalan-smoketest-${DSTAMP}.tar" |
| zipfile="${test.build.dir}/xalan-smoketest-${DSTAMP}.tar.gz"/> |
| <delete file="${test.build.dir}/xalan-smoketest-${DSTAMP}.tar"/> |
| |
| <zip zipfile="${test.build.dir}/xalan-smoketest-${DSTAMP}.zip" > |
| <zipfileset dir="${tarzip-backref}"> |
| <include name="${tarzip-fwdref}/${smoketest.outputDir}/"/> |
| </zipfileset> |
| </zip> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: A whole bunch of tests - used before posting builds, etc--> |
| <!-- ================================================================== --> |
| <target name="alltest" |
| description="Run nearly *all* available Xalan-J 2.x tests with defaults" |
| depends="all,alltest.other,alltest.conf,alltest.accept,alltest.contrib"> |
| <!-- Ensure that one last scan gets run of the whole output set |
| (Note that when we call sub-targets, some of our subdirs |
| may have had sub-scans done as well) --> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="results-alltest"/> |
| </antcall> |
| |
| </target> |
| <target name="alltest.features" |
| description="Re-Run nearly *all* available Xalan-J 2.x tests with setAttribute features set" |
| depends="all,alltest.other"> |
| <property name="alltest.resultDir" value="results-alltest" /> |
| <antcall target="alltest.conf"> |
| <param name="alltest.resultDir" value="${alltest.resultDir}/inctrue"/> |
| <param name="conf.Processor.setAttribute.http://xml.apache.org/xalan/features/incremental" value="true"/> |
| </antcall> |
| <antcall target="alltest.conf"> |
| <param name="alltest.resultDir" value="${alltest.resultDir}/optfalse"/> |
| <param name="conf.Processor.setAttribute.http://xml.apache.org/xalan/features/optimize" value="false"/> |
| </antcall> |
| <antcall target="alltest.contrib"> |
| <param name="alltest.resultDir" value="${alltest.resultDir}/inctrue"/> |
| <param name="conf.Processor.setAttribute.http://xml.apache.org/xalan/features/incremental" value="true"/> |
| </antcall> |
| <antcall target="alltest.contrib"> |
| <param name="alltest.resultDir" value="${alltest.resultDir}/optfalse"/> |
| <param name="conf.Processor.setAttribute.http://xml.apache.org/xalan/features/optimize" value="false"/> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${alltest.resultDir}"/> |
| </antcall> |
| </target> |
| |
| <target name="alltest.other"> |
| <property name="alltest.resultDir" value="results-alltest" /> |
| <echo message="About to execute various API, extensions, bugzilla tests, results under ${alltest.resultDir}/..." /> |
| <!-- Run all individual API tests through the harness --> |
| <antcall target="harness"> |
| <param name="api.outputDir" value="${alltest.resultDir}/harness"/> |
| <param name="api.logFile" value="${alltest.resultDir}/harness/results.xml"/> |
| </antcall> |
| <!-- Run other misc tests --> |
| <antcall target="extensions"> |
| <param name="extensions.outputDir" value="${alltest.resultDir}/extensions"/> |
| <param name="extensions.logFile" value="${alltest.resultDir}/extensions/results.xml"/> |
| </antcall> |
| <antcall target="bugzilla"> |
| <param name="bugzilla.outputDir" value="${alltest.resultDir}/bugzilla"/> |
| <param name="bugzilla.logFile" value="${alltest.resultDir}/bugzilla/results.xml"/> |
| </antcall> |
| <!-- Run the threading tests once --> |
| <antcall target="threads"> |
| <param name="threads.outputDir" value="${alltest.resultDir}/threads"/> |
| <param name="threads.logFile" value="${alltest.resultDir}/threads/results.xml"/> |
| </antcall> |
| <!-- Run the perf tests just with streams, which gives best perf data --> |
| <antcall target="perf"> |
| <param name="perf.flavor" value="trax.stream"/> |
| <param name="perf.fileList" value="perf.filelist"/> |
| <param name="perf.outputDir" value="${alltest.resultDir}/perf"/> |
| <param name="perf.logFile" value="${alltest.resultDir}/perf/results.xml"/> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${alltest.resultDir}"/> |
| </antcall> |
| </target> |
| |
| <target name="alltest.contrib"> |
| <property name="alltest.resultDir" value="results-alltest" /> |
| <property name="alltest.contrib.resultDir" value="${alltest.resultDir}/contrib" /> |
| <echo message="About to execute contrib tests with all flavors, results into ${alltest.contrib.resultDir}/..." /> |
| |
| <antcall target="contrib"> |
| <param name="contrib.flavor" value="trax.systemId"/> |
| <param name="contrib.outputDir" value="${alltest.contrib.resultDir}/systemId"/> |
| <param name="contrib.logFile" value="${alltest.contrib.resultDir}/systemId/results.xml"/> |
| </antcall> |
| <antcall target="contrib"> |
| <param name="contrib.flavor" value="trax.file"/> |
| <param name="contrib.outputDir" value="${alltest.contrib.resultDir}/file"/> |
| <param name="contrib.logFile" value="${alltest.contrib.resultDir}/file/results.xml"/> |
| </antcall> |
| <antcall target="contrib"> |
| <param name="contrib.flavor" value="trax.dom"/> |
| <param name="contrib.outputDir" value="${alltest.contrib.resultDir}/dom"/> |
| <param name="contrib.logFile" value="${alltest.contrib.resultDir}/dom/results.xml"/> |
| </antcall> |
| <antcall target="contrib"> |
| <param name="contrib.flavor" value="trax.sax"/> |
| <param name="contrib.outputDir" value="${alltest.contrib.resultDir}/sax"/> |
| <param name="contrib.logFile" value="${alltest.contrib.resultDir}/sax/results.xml"/> |
| </antcall> |
| <antcall target="contrib"> |
| <param name="contrib.flavor" value="trax.localPath"/> |
| <param name="contrib.outputDir" value="${alltest.contrib.resultDir}/localPath"/> |
| <param name="contrib.logFile" value="${alltest.contrib.resultDir}/localPath/results.xml"/> |
| </antcall> |
| <antcall target="contrib"> |
| <param name="contrib.flavor" value="trax.stream"/> |
| <param name="contrib.outputDir" value="${alltest.contrib.resultDir}/stream"/> |
| <param name="contrib.logFile" value="${alltest.contrib.resultDir}/stream/results.xml"/> |
| </antcall> |
| </target> |
| |
| <target name="alltest.conf"> |
| <property name="alltest.resultDir" value="results-alltest" /> |
| <property name="alltest.conf.resultDir" value="${alltest.resultDir}/conf" /> |
| <echo message="About to execute conf tests with all flavors, results into ${alltest.conf.resultDir}/..." /> |
| <!-- Run full conf test with each major available flavor into |
| specific output directories; note any user options will |
| override for all test calls. |
| Also exclude the currently failing tests in the |
| smoketest if use.excludes is set. |
| --> |
| <condition property="conf.excludes" value="${smoketest.conf.excludes}"> |
| <equals arg1="${use.excludes}" arg2="true" /> |
| </condition> |
| <antcall target="conf"> |
| <param name="conf.flavor" value="trax.systemId"/> |
| <param name="conf.excludes" value="${conf.excludes}"/> |
| <param name="conf.outputDir" value="${alltest.conf.resultDir}/systemId"/> |
| <param name="conf.logFile" value="${alltest.conf.resultDir}/systemId/results.xml"/> |
| </antcall> |
| <antcall target="conf"> |
| <param name="conf.flavor" value="trax.file"/> |
| <param name="conf.excludes" value="${conf.excludes}"/> |
| <param name="conf.outputDir" value="${alltest.conf.resultDir}/file"/> |
| <param name="conf.logFile" value="${alltest.conf.resultDir}/file/results.xml"/> |
| </antcall> |
| <antcall target="conf"> |
| <param name="conf.flavor" value="trax.dom"/> |
| <!-- Note DOM always has additional exclusions in conf tests--> |
| <param name="conf.excludes" value="${trax.dom.excludes};${conf.excludes}"/> |
| <param name="conf.outputDir" value="${alltest.conf.resultDir}/dom"/> |
| <param name="conf.logFile" value="${alltest.conf.resultDir}/dom/results.xml"/> |
| </antcall> |
| <antcall target="conf"> |
| <param name="conf.flavor" value="trax.sax"/> |
| <param name="conf.excludes" value="${conf.excludes}"/> |
| <param name="conf.outputDir" value="${alltest.conf.resultDir}/sax"/> |
| <param name="conf.logFile" value="${alltest.conf.resultDir}/sax/results.xml"/> |
| </antcall> |
| <antcall target="conf"> |
| <param name="conf.flavor" value="trax.localPath"/> |
| <param name="conf.excludes" value="${conf.excludes}"/> |
| <param name="conf.outputDir" value="${alltest.conf.resultDir}/localPath"/> |
| <param name="conf.logFile" value="${alltest.conf.resultDir}/localPath/results.xml"/> |
| </antcall> |
| <antcall target="conf"> |
| <param name="conf.flavor" value="trax.stream"/> |
| <param name="conf.excludes" value="${conf.excludes}"/> |
| <param name="conf.outputDir" value="${alltest.conf.resultDir}/stream"/> |
| <param name="conf.logFile" value="${alltest.conf.resultDir}/stream/results.xml"/> |
| </antcall> |
| <!-- we should really run conferr with each flavor --> |
| <antcall target="conferr"> |
| <param name="conferr.flavor" value="trax.systemId"/> |
| <param name="conferr.outputDir" value="${alltest.conf.resultDir}/conferr"/> |
| <param name="conferr.logFile" value="${alltest.conf.resultDir}/conferr/results.xml"/> |
| <!-- Note that conferr doesn't currently use gold files, |
| but we need to set the goldDir anyway for convenience |
| --> |
| <param name="conferr.goldDir" value="${alltest.conf.resultDir}/conferr-gold"/> |
| </antcall> |
| <!-- To be updated: also use at least one run of ErrorHandlerTestlet --> |
| <antcall target="conf"> |
| <param name="conf.testlet" value="org.apache.qetest.xsl.ErrorHandlerTestlet"/> |
| <param name="conf.flavor" value="trax.stream"/> |
| <param name="conf.excludes" value="${conf.excludes}"/> |
| <param name="conf.outputDir" value="${alltest.conf.resultDir}/streamEH"/> |
| <param name="conf.logFile" value="${alltest.conf.resultDir}/streamEH/results.xml"/> |
| </antcall> |
| </target> |
| |
| <target name="alltest.accept"> |
| <property name="alltest.resultDir" value="results-alltest" /> |
| <property name="alltest.accept.resultDir" value="${alltest.resultDir}/accept" /> |
| <echo message="About to execute accept tests with all flavors, results into ${alltest.accept.resultDir}/..." /> |
| <!-- Run full accept test with each major available flavor into |
| specific output directories; note any user options will |
| override for all test calls. |
| Also exclude the currently failing tests in the |
| smoketest if use.excludes is set. |
| --> |
| <condition property="accept.excludes" value="${smoketest.accept.excludes}"> |
| <equals arg1="${use.excludes}" arg2="true" /> |
| </condition> |
| <antcall target="accept"> |
| <param name="accept.flavor" value="trax.systemId"/> |
| <param name="accept.excludes" value="${accept.excludes}"/> |
| <param name="accept.outputDir" value="${alltest.accept.resultDir}/systemId"/> |
| <param name="accept.logFile" value="${alltest.accept.resultDir}/systemId/results.xml"/> |
| </antcall> |
| <antcall target="accept"> |
| <param name="accept.flavor" value="trax.file"/> |
| <param name="accept.excludes" value="${accept.excludes}"/> |
| <param name="accept.outputDir" value="${alltest.accept.resultDir}/file"/> |
| <param name="accept.logFile" value="${alltest.accept.resultDir}/file/results.xml"/> |
| </antcall> |
| <antcall target="accept"> |
| <param name="accept.flavor" value="trax.dom"/> |
| <!-- Note DOM always has additional exclusions in accept tests--> |
| <param name="accept.excludes" value="${trax.dom.excludes};${accept.excludes}"/> |
| <param name="accept.outputDir" value="${alltest.accept.resultDir}/dom"/> |
| <param name="accept.logFile" value="${alltest.accept.resultDir}/dom/results.xml"/> |
| </antcall> |
| <antcall target="accept"> |
| <param name="accept.flavor" value="trax.sax"/> |
| <param name="accept.excludes" value="${accept.excludes}"/> |
| <param name="accept.outputDir" value="${alltest.accept.resultDir}/sax"/> |
| <param name="accept.logFile" value="${alltest.accept.resultDir}/sax/results.xml"/> |
| </antcall> |
| <antcall target="accept"> |
| <param name="accept.flavor" value="trax.localPath"/> |
| <param name="accept.excludes" value="${accept.excludes}"/> |
| <param name="accept.outputDir" value="${alltest.accept.resultDir}/localPath"/> |
| <param name="accept.logFile" value="${alltest.accept.resultDir}/localPath/results.xml"/> |
| </antcall> |
| <antcall target="accept"> |
| <param name="accept.flavor" value="trax.stream"/> |
| <param name="accept.excludes" value="${accept.excludes}"/> |
| <param name="accept.outputDir" value="${alltest.accept.resultDir}/stream"/> |
| <param name="accept.logFile" value="${alltest.accept.resultDir}/stream/results.xml"/> |
| </antcall> |
| <!-- we should really run accept with each flavor --> |
| </target> |
| |
| <target name="alltest.conf.xsltc"> |
| <property name="alltest.xsltc.resultDir" value="results-alltest.xsltc" /> |
| <property name="alltest.conf.xsltc.resultDir" value="${alltest.xsltc.resultDir}/conf" /> |
| <echo message="About to execute xsltc.conf tests with all flavors, results into ${alltest.conf.xsltc.resultDir}/..." /> |
| <!-- Run full conf test with each major available flavor into |
| specific output directories; note any user options will |
| override for all test calls. |
| Also exclude the currently failing tests in the |
| smoketest if use.excludes is set. |
| --> |
| <condition property="conf.xsltc.excludes" value="${smoketest.conf.xsltc.excludes}"> |
| <equals arg1="${use.excludes}" arg2="true" /> |
| </condition> |
| <antcall target="conf.xsltc"> |
| <param name="conf.xsltc.flavor" value="trax.systemId"/> |
| <param name="conf.xsltc.excludes" value="${conf.xsltc.excludes}"/> |
| <param name="conf.xsltc.outputDir" value="${alltest.conf.xsltc.resultDir}/systemId"/> |
| <param name="conf.xsltc.logFile" value="${alltest.conf.xsltc.resultDir}/systemId/results.xml"/> |
| </antcall> |
| <antcall target="conf.xsltc"> |
| <param name="conf.xsltc.flavor" value="trax.file"/> |
| <param name="conf.xsltc.excludes" value="${conf.xsltc.excludes}"/> |
| <param name="conf.xsltc.outputDir" value="${alltest.conf.xsltc.resultDir}/file"/> |
| <param name="conf.xsltc.logFile" value="${alltest.conf.xsltc.resultDir}/file/results.xml"/> |
| </antcall> |
| <antcall target="conf.xsltc"> |
| <param name="conf.xsltc.flavor" value="trax.dom"/> |
| <!-- Note DOM always has additional exclusions in conf tests--> |
| <param name="conf.xsltc.excludes" value="${trax.dom.excludes};${conf.xsltc.excludes}"/> |
| <param name="conf.xsltc.outputDir" value="${alltest.conf.xsltc.resultDir}/dom"/> |
| <param name="conf.xsltc.logFile" value="${alltest.conf.xsltc.resultDir}/dom/results.xml"/> |
| </antcall> |
| <antcall target="conf.xsltc"> |
| <param name="conf.xsltc.flavor" value="trax.sax"/> |
| <param name="conf.xsltc.excludes" value="${conf.xsltc.excludes}"/> |
| <param name="conf.xsltc.outputDir" value="${alltest.conf.xsltc.resultDir}/sax"/> |
| <param name="conf.xsltc.logFile" value="${alltest.conf.xsltc.resultDir}/sax/results.xml"/> |
| </antcall> |
| <antcall target="conf.xsltc"> |
| <param name="conf.xsltc.flavor" value="trax.localPath"/> |
| <param name="conf.xsltc.excludes" value="${conf.xsltc.excludes}"/> |
| <param name="conf.xsltc.outputDir" value="${alltest.conf.xsltc.resultDir}/localPath"/> |
| <param name="conf.xsltc.logFile" value="${alltest.conf.xsltc.resultDir}/localPath/results.xml"/> |
| </antcall> |
| <antcall target="conf.xsltc"> |
| <param name="conf.xsltc.flavor" value="trax.stream"/> |
| <param name="conf.xsltc.excludes" value="${conf.xsltc.excludes}"/> |
| <param name="conf.xsltc.outputDir" value="${alltest.conf.xsltc.resultDir}/stream"/> |
| <param name="conf.xsltc.logFile" value="${alltest.conf.xsltc.resultDir}/stream/results.xml"/> |
| </antcall> |
| </target> |
| |
| <target name="alltest.accept.xsltc"> |
| <property name="alltest.xsltc.resultDir" value="results-alltest.xsltc" /> |
| <property name="alltest.accept.xsltc.resultDir" value="${alltest.xsltc.resultDir}/accept" /> |
| <echo message="About to execute xsltc.accept tests with all flavors, results into ${alltest.accept.xsltc.resultDir}/..." /> |
| <!-- Run full accept test with each major available flavor into |
| specific output directories; note any user options will |
| override for all test calls. |
| Also exclude the currently failing tests in the |
| smoketest if use.excludes is set. |
| --> |
| <condition property="accept.xsltc.excludes" value="${smoketest.accept.xsltc.excludes}"> |
| <equals arg1="${use.excludes}" arg2="true" /> |
| </condition> |
| <antcall target="accept.xsltc"> |
| <param name="accept.xsltc.flavor" value="trax.systemId"/> |
| <param name="accept.xsltc.excludes" value="${accept.xsltc.excludes}"/> |
| <param name="accept.xsltc.outputDir" value="${alltest.accept.xsltc.resultDir}/systemId"/> |
| <param name="accept.xsltc.logFile" value="${alltest.accept.xsltc.resultDir}/systemId/results.xml"/> |
| </antcall> |
| <antcall target="accept.xsltc"> |
| <param name="accept.xsltc.flavor" value="trax.file"/> |
| <param name="accept.xsltc.excludes" value="${accept.xsltc.excludes}"/> |
| <param name="accept.xsltc.outputDir" value="${alltest.accept.xsltc.resultDir}/file"/> |
| <param name="accept.xsltc.logFile" value="${alltest.accept.xsltc.resultDir}/file/results.xml"/> |
| </antcall> |
| <antcall target="accept.xsltc"> |
| <param name="accept.xsltc.flavor" value="trax.dom"/> |
| <!-- Note DOM always has additional exclusions in accept tests--> |
| <param name="accept.xsltc.excludes" value="${trax.dom.excludes};${accept.xsltc.excludes}"/> |
| <param name="accept.xsltc.outputDir" value="${alltest.accept.xsltc.resultDir}/dom"/> |
| <param name="accept.xsltc.logFile" value="${alltest.accept.xsltc.resultDir}/dom/results.xml"/> |
| </antcall> |
| <antcall target="accept.xsltc"> |
| <param name="accept.xsltc.flavor" value="trax.sax"/> |
| <param name="accept.xsltc.excludes" value="${accept.xsltc.excludes}"/> |
| <param name="accept.xsltc.outputDir" value="${alltest.accept.xsltc.resultDir}/sax"/> |
| <param name="accept.xsltc.logFile" value="${alltest.accept.xsltc.resultDir}/sax/results.xml"/> |
| </antcall> |
| <antcall target="accept.xsltc"> |
| <param name="accept.xsltc.flavor" value="trax.localPath"/> |
| <param name="accept.xsltc.excludes" value="${accept.xsltc.excludes}"/> |
| <param name="accept.xsltc.outputDir" value="${alltest.accept.xsltc.resultDir}/localPath"/> |
| <param name="accept.xsltc.logFile" value="${alltest.accept.xsltc.resultDir}/localPath/results.xml"/> |
| </antcall> |
| <antcall target="accept.xsltc"> |
| <param name="accept.xsltc.flavor" value="trax.stream"/> |
| <param name="accept.xsltc.excludes" value="${accept.xsltc.excludes}"/> |
| <param name="accept.xsltc.outputDir" value="${alltest.accept.xsltc.resultDir}/stream"/> |
| <param name="accept.xsltc.logFile" value="${alltest.accept.xsltc.resultDir}/stream/results.xml"/> |
| </antcall> |
| </target> |
| |
| <target name="alltest.conf.trace"> |
| <property name="conf.trace" value="on"/> |
| <antcall target="alltest.conf"/> |
| </target> |
| |
| <target name="alltest.accept.trace"> |
| <property name="accept.trace" value="on"/> |
| <antcall target="alltest.accept"/> |
| </target> |
| |
| <target name="test" |
| depends="alltest" |
| description="Alias for alltest"> |
| </target> |
| |
| <target name="check" |
| depends="alltest" |
| description="Alias for alltest"> |
| </target> |
| |
| <target name="scan" |
| description="Run a simple ResultScanner on a tree of test results"> |
| <property name="scan.outputDir" value="results-alltest" /> |
| <property name="scan.logFile" value="${scan.outputDir}/ResultReport" /> |
| <java classname="org.apache.qetest.xsl.ResultScanner" |
| classpathref="conf.class.path" |
| fork="yes" > |
| <arg line="${scan.outputDir} ${scan.logFile}"/> |
| </java> |
| </target> |
| <!-- ================================================================== --> |
| <!-- Build Tests: Compile/jar targets for each 'layer' of testing code --> |
| <!-- ================================================================== --> |
| <target name="compile.qetest" depends="init.build" |
| description="Compile base qetest files; no Xalan dependencies"> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}*.java" |
| debug="${debug}" |
| target="${compiler.target}" source="${compiler.source}"/> |
| </target> |
| |
| |
| <target name="jar.qetest" depends="compile.qetest" |
| description="Jar base qetest files; no Xalan dependencies"> |
| <jar jarfile="${qetest.jar}" |
| basedir="${test.build.dir}" |
| includes="${test.root}*.java,${test.root}*.properties" /> |
| </target> |
| |
| |
| <!-- This step should be dependent upon general XML/XSL |
| functionality like SAX, DOM, JAXP and the like, but |
| should not directly depend on Xalan |
| --> |
| <target name="compile.xsl" depends="compile.qetest" |
| description="Compile TransformWrapper and associated classes"> |
| <!-- This javac has no dependencies --> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}xslwrapper/TransformWrapperHelper.java,${test.root}xslwrapper/TransformWrapper.java,${test.root}xslwrapper/TransformWrapperFactory.java" |
| debug="${debug}" |
| target="${compiler.target}" source="${compiler.source}"/> |
| <!-- This javac depends on JAXP, SAX, DOM; hence the specific classpathref --> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}xsl/*.java" |
| debug="${debug}" |
| classpathref="compiletest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| </target> |
| |
| <target name="compile.trax.xslwrappers" depends="compile.xsl" |
| description="Compile Trax*Wrapper xslwrappers only"> |
| <!-- Should only be dependent on JAXP, not Xalan specifically --> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}xslwrapper/Trax*Wrapper.java,${test.root}xslwrapper/TraxWrapperUtils.java,${test.root}xslwrapper/XalanProcessWrapper.java" |
| debug="${debug}" |
| classpathref="compiletest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| </target> |
| |
| <target name="compile.trax" depends="compile.xsl,compile.trax.xslwrappers" |
| description="Compile various JAXP-based API tests"> |
| <!-- Should only be dependent on JAXP, not Xalan specifically --> |
| <!-- Separate javac steps to avoid compiler oddities --> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}trax/*.java" |
| debug="${debug}" |
| classpathref="compiletest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}trax/stream/*.java" |
| debug="${debug}" |
| classpathref="compiletest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}trax/dom/*.java" |
| debug="${debug}" |
| classpathref="compiletest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}trax/sax/*.java" |
| debug="${debug}" |
| classpathref="compiletest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| </target> |
| |
| <target name="compile" depends="compile.trax"> |
| <echo message="Compile Xalan-J 2.x specific tests" /> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}xalanj2/*.java,${test.root}dtm/*.java" |
| excludes="${test.root}dtm/xsltcDocCode.java" |
| debug="${debug}" |
| classpathref="compiletest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| </target> |
| |
| <target name="compile.rwapi" depends="compile"> |
| <echo message="Compile xslt20 / XPath2.0 RWAPI tests" /> |
| <javac srcdir="${test.src.dir}" |
| destdir="${test.build.dir}" |
| includes="${test.root}rwapi/*.*" |
| debug="${debug}" |
| classpathref="rwapitest.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| </target> |
| |
| <!-- Note that this target must *not* depend on any XSLTC tests, |
| which have to be compiled separately; otherwise the |
| smoketest will fail. |
| --> |
| <target name="jar" depends="compile" |
| description="Build testxsl.jar with all available tests"> |
| <jar jarfile="${testxsl.jar}" |
| basedir="${test.build.dir}" |
| includes="**/*.class,**/*.properties" /> |
| </target> |
| |
| <!-- excludes="Bugzilla1288.java"; test refers to removed classes --> |
| <target name="bugzilla.classes" depends="jar" |
| description="Compile any bugzilla testlet classes"> |
| <mkdir dir="${tests.bugzilla.build.dir}" /> |
| <javac srcdir="${tests.bugzilla.dir}" |
| destdir="${tests.bugzilla.build.dir}" |
| debug="${debug}" |
| excludes="Bugzilla1288.java" |
| classpathref="bugzilla.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| </target> |
| |
| <target name="extensions.classes" depends="jar" |
| description="Compile any extensions test classes"> |
| <mkdir dir="${tests.extensions.build.dir}" /> |
| <javac srcdir="${tests.extensions.dir}" |
| destdir="${tests.extensions.build.dir}" |
| debug="${debug}" |
| classpathref="extensions.class.path" |
| target="${compiler.target}" source="${compiler.source}"/> |
| <!-- Add more javac calls if we add more Java extensions dirs --> |
| </target> |
| |
| <!-- This target compiles both the main tests and test drivers |
| in testxsl.jar from the java/ directory, as well as |
| various other classes in subdirs under tests/ |
| --> |
| <target name="all" description="Build testxsl.jar *and* compile .java under tests/" |
| depends="jar,bugzilla.classes,extensions.classes"> |
| </target> |
| |
| <target name="main" |
| depends="all" |
| description="Alias for all"> |
| </target> |
| |
| <!-- =================================================================== --> |
| <!-- Various targets to clean the build tree --> |
| <!-- =================================================================== --> |
| <target name="distclean" depends="clean" |
| description="Clean everything, including most test results!" > |
| <delete dir="${alltest.resultDir}" /> |
| <delete dir="${api.outputDir}" /> |
| <delete dir="${conf.outputDir}" /> |
| <delete dir="${perf.outputDir}" /> |
| <delete dir="${contrib.outputDir}" /> |
| <delete dir="${smoketest.outputDir}" /> |
| </target> |
| |
| <target name="clean" |
| description="Clean up the compiled tests and docs"> |
| <delete dir="${test.build.dir}"/> |
| <delete dir="${tests.bugzilla.build.dir}"/> |
| <delete dir="${tests.extensions.build.dir}"/> |
| <delete dir="${xdocs.style}"/> <!-- init.build.docs creates this tree --> |
| </target> |
| |
| |
| <!-- ================================================================== --> |
| <!-- Build docs: Creates the User's Guide --> |
| <!-- ================================================================== --> |
| <target name="docs" depends="init.docs" |
| description="Build the framework/overview docs for tests"> |
| <java fork="yes" |
| classname="${doc.generator}" |
| classpathref="test.docs.class.path" > |
| <arg line="targetDirectory=${test.build.docs} ${test.xdocs.book} ${test.xdocs.style}"/> |
| </java> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Build docs: Creates the Javadoc API documentation --> |
| <!-- ================================================================== --> |
| <target name="javadocs" depends="init.docs" |
| description="Build the Javadocs for tests"> |
| |
| <!-- Ant 1.2 ignores destdir arg if doclet is set, so must send to doclet in doclet subelement dleslie--> |
| <!-- But: Ant 1.3 fails if you *don't* provide destdir attr... curcuru--> |
| <javadoc |
| sourcepath="${test.src.dir}" |
| packagenames="org.apache.qetest,org.apache.qetest.xslwrapper,org.apache.qetest.xsl,org.apache.qetest.trax,org.apache.qetest.trax.dom,org.apache.qetest.trax.sax,org.apache.qetest.trax.stream,org.apache.qetest.xalanj2" |
| protected="true" |
| author="true" |
| version="true" |
| use="true" |
| windowtitle="Xalan Testing Framework" |
| doctitle="Xalan Testing Framework" |
| bottom="Copyright © ${year} The Apache Software Foundation. All rights reserved." |
| destdir="${test.build.apidocs}"> |
| <classpath refid="test.docs.class.path" /> |
| <doclet name="xalanjdoc.Standard" path="${doclet.jar}"> |
| <param name="-d" value="${test.build.apidocs}"/> |
| </doclet> |
| <group title="QETEST Independent Framework" packages="org.apache.qetest"/> |
| <group title="Xalan Framework and Base tests" packages="org.apache.qetest.xsl:org.apache.qetest.xslwrapper"/> |
| <group title="JAXP/TrAX Generic Tests" packages="org.apache.qetest.trax:org.apache.qetest.trax.dom:org.apache.qetest.trax.sax:org.apache.qetest.trax.stream:"/> |
| <group title="Xalan-J 2.x Specific Tests" packages="org.apache.qetest.xalanj2:org.apache.qetest.xsltc:org.apache.qetest.dtm"/> |
| </javadoc> |
| </target> |
| |
| <target name="printerdocs" depends="init.docs"> |
| <echo message="${ant.project.name} currently doesn't support printerdocs; try docs or javadocs instead."/> |
| </target> |
| |
| <!-- =================================================================== --> |
| <!-- Build distribution - simple zip/tar.gz for sharing tests --> |
| <!-- =================================================================== --> |
| <target name="dist" depends="all,docs,javadocs,dist-nodeps" |
| description="Build a simple distribution module incl. docs"> |
| </target> |
| |
| <target name="dist-nodeps" depends="init.build" |
| description="Build a simple distribution module, without depends"> |
| <echo message="Create .zip/.tar/gz in ${test.build.dir}" /> |
| |
| <!-- Build .tars, then .gzs, then cleanup .tars before doing .zips --> |
| <!-- Note ../.. paths to ensure archives start with |
| top-level xml-xalan/test/blah directories |
| --> |
| <property name="tarzip-backref" value="../.."/> |
| <property name="tarzip-fwdref" value="xml-xalan/test"/> |
| |
| <!-- tar.gz just the xml/xsl/out test files --> |
| <tar tarfile="${test.build.dir}/xalan-tests-${DSTAMP}.tar"> |
| <tarfileset dir="${tarzip-backref}"> |
| <include name="${tarzip-fwdref}/tests/"/> |
| </tarfileset> |
| </tar> |
| <gzip src="${test.build.dir}/xalan-tests-${DSTAMP}.tar" |
| zipfile="${test.build.dir}/xalan-tests-${DSTAMP}.tar.gz"/> |
| <delete file="${test.build.dir}/xalan-tests-${DSTAMP}.tar"/> |
| |
| <!-- tar.gz the automation and batch files, etc. --> |
| <tar tarfile="${test.build.dir}/xalan-automation-${DSTAMP}.tar"> |
| <tarfileset dir="${tarzip-backref}"> |
| <include name="${tarzip-fwdref}/*.*"/> |
| <include name="${tarzip-fwdref}/${testxsl.jar}"/> |
| <include name="${tarzip-fwdref}/${test.build.dir}/${test.root}"/> |
| <include name="${tarzip-fwdref}/${test.build.docs}/"/> |
| <include name="${tarzip-fwdref}/${test.build.apidocs}/"/> |
| <include name="${tarzip-fwdref}/java/xdocs/"/> |
| <include name="${tarzip-fwdref}/java/src/"/> |
| <include name="${tarzip-fwdref}/bin/"/> |
| </tarfileset> |
| </tar> |
| <gzip src="${test.build.dir}/xalan-automation-${DSTAMP}.tar" |
| zipfile="${test.build.dir}/xalan-automation-${DSTAMP}.tar.gz"/> |
| <delete file="${test.build.dir}/xalan-automation-${DSTAMP}.tar"/> |
| |
| <!-- Zip just the xml/xsl/out test files --> |
| <zip zipfile="${test.build.dir}/xalan-tests-${DSTAMP}.zip" > |
| <zipfileset dir="${tarzip-backref}"> |
| <include name="${tarzip-fwdref}/tests/"/> |
| </zipfileset> |
| </zip> |
| <!-- Zip the automation and batch files, etc. --> |
| <zip zipfile="${test.build.dir}/xalan-automation-${DSTAMP}.zip" > |
| <zipfileset dir="${tarzip-backref}"> |
| <include name="${tarzip-fwdref}/*.*"/> |
| <include name="${tarzip-fwdref}/${testxsl.jar}"/> |
| <include name="${tarzip-fwdref}/${test.build.dir}/${test.root}"/> |
| <include name="${tarzip-fwdref}/${test.build.docs}/"/> |
| <include name="${tarzip-fwdref}/${test.build.apidocs}/"/> |
| <include name="${tarzip-fwdref}/java/xdocs/"/> |
| <include name="${tarzip-fwdref}/java/src/"/> |
| <include name="${tarzip-fwdref}/bin/"/> |
| </zipfileset> |
| </zip> |
| |
| <!-- tar.gz just the documentation for potential posting to the website --> |
| <tar tarfile="${test.build.dir}/xalan-docs-${DSTAMP}.tar"> |
| <tarfileset dir=".."> |
| <include name="test/${test.build.docs}/"/> |
| <include name="test/${test.build.apidocs}/"/> |
| <include name="test/README.html"/> |
| </tarfileset> |
| </tar> |
| <gzip src="${test.build.dir}/xalan-docs-${DSTAMP}.tar" |
| zipfile="${test.build.dir}/xalan-docs-${DSTAMP}.tar.gz"/> |
| <delete file="${test.build.dir}/xalan-docs-${DSTAMP}.tar"/> |
| <zip zipfile="${test.build.dir}/xalan-docs-${DSTAMP}.zip" > |
| <zipfileset dir=".."> |
| <include name="test/${test.build.docs}/"/> |
| <include name="test/${test.build.apidocs}/"/> |
| <include name="test/README.html"/> |
| </zipfileset> |
| </zip> |
| |
| </target> |
| |
| <target name="export" depends="jar" |
| description="Build a very simple export of just the important sources"> |
| <!-- Note that Shane has external dependencies on this target --> |
| <!-- Zip only the sources used in the plain 'jar' target --> |
| <zip zipfile="${test.build.dir}/testxsl-src-${DSTAMP}.zip" > |
| <zipfileset dir="java"> |
| <include name="src/"/> |
| <!-- Don't copy qetesttest due to JUnit dependency --> |
| <exclude name="src/${test.root}qetesttest/"/> |
| </zipfileset> |
| </zip> |
| |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Special: Targets specific to XSLTC which requires extra .jars --> |
| <!-- This section will be updated as xsltc integrates more with xalan --> |
| <!-- ================================================================== --> |
| <!-- Actually, I'd like to figure out some sneaky Ant trick to |
| allow swapping of parts of classpaths (i.e. swap in xsltc.jar |
| and related files instead of xalan.jar; likewise replace |
| xercesImpl.jar with the PARSER_JAR defined outside) to clean |
| this section up. But for the time being I'm planning on |
| simply maintaining separate-but-equal targets.xsltc |
| --> |
| |
| <path id="xsltc.runtime.class.path"> |
| <pathelement path="${java.class.path}" /> |
| <pathelement location="${xalan.build.dir}/xalan.jar" /> |
| |
| <!-- add xsltc.jar so we can test the separate jar distribution --> |
| <pathelement location="${xalan.build.dir}/xsltc.jar" /> |
| <pathelement location="${ser.jar}" /> |
| |
| <pathelement location="${testxsl.jar}" /> |
| <pathelement location="${parserjar}" /> |
| <pathelement location="${xml-apis.jar}" /> |
| <pathelement location="${jtidy.jar}" /> |
| </path> |
| <path id="xsltc.compile.class.path"> |
| <pathelement path="${java.class.path}" /> |
| <pathelement location="${xalan.build.dir}/xalan.jar" /> |
| |
| <!-- add xsltc.jar so we can test the separate jar distribution --> |
| <pathelement location="${xalan.build.dir}/xsltc.jar" /> |
| |
| <pathelement location="${testxsl.jar}" /> |
| <pathelement location="${parserjar}" /> |
| <pathelement location="${xml-apis.jar}" /> |
| <pathelement location="${jtidy.jar}" /> |
| <!-- Note addition of . to the classpath to enable loading |
| of translets; this needs more work and coordination |
| with tests and translet output dirs. |
| --> |
| <pathelement location="." /> |
| </path> |
| |
| <target name="conf.xsltc" description="Run TestletDriver over the conf tree using xsltc"> |
| <!-- Set the default conformance test driver, user may override --> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan-xsltc conf test: ${testClass}" /> |
| <!-- Special: allow explicit test.properties overrides for inputDir, etc for xsltc --> |
| <property name="testType" value="conf.xsltc." /> |
| <!-- Set indent-number to 0 to match Xalan's default indentation --> |
| <property name="${testType}Processor.setAttribute.indent-number" value="0"/> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" |
| value="xsltc.runtime.class.path" /> |
| <!-- Explicitly set TransformerFactory property to use xsltc --> |
| <param name="sysprop.transfact" |
| value="org.apache.xalan.xsltc.trax.TransformerFactoryImpl" /> |
| </antcall> |
| <property name="scan.outputDir" value="${conf.xsltc.outputDir}"/> |
| <antcall target="scan" /> |
| </target> |
| |
| <target name="perf.xsltc" description="Run TestletDriver over the perf tree using xsltc"> |
| <!-- Set the default conformance test driver, user may override --> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Xalan-xsltc perf test: ${testClass}" /> |
| <!-- Special: allow explicit test.properties overrides for inputDir, etc for xsltc --> |
| <property name="testType" value="perf.xsltc." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" |
| value="xsltc.runtime.class.path" /> |
| <!-- Explicitly set TransformerFactory property to use xsltc --> |
| <param name="sysprop.transfact" |
| value="org.apache.xalan.xsltc.trax.TransformerFactoryImpl" /> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${perf.xsltc.outputDir}"/> |
| </antcall> |
| </target> |
| |
| |
| <target name="perf.saxon" description="Run TestletDriver over the perf tree using Saxon"> |
| <!-- New addition, NOT TESTED --> |
| <!-- Set the default conformance test driver, user may override --> |
| <property name="testClass" value="org.apache.qetest.xsl.StylesheetTestletDriver" /> |
| <echo message="Executing Saxon perf test: ${testClass}" /> |
| <!-- Special: allow explicit test.properties overrides for inputDir, etc for Saxon --> |
| <property name="testType" value="perf.saxon." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" |
| value="saxon.runtime.class.path" /> |
| <!-- Explicitly set TransformerFactory property to use saxon --> |
| <param name="sysprop.transfact" |
| value="org.saxon.trax.TransformerFactoryImpl" /> |
| </antcall> |
| <antcall target="scan"> |
| <param name="scan.outputDir" value="${perf.saxon.outputDir}"/> |
| </antcall> |
| </target> |
| |
| <!-- ================================================================== --> |
| <!-- Run tests: a specific named API test with xsltc code --> |
| <!-- ================================================================== --> |
| <target name="api.xsltc" description="Run a specific API test with xsltc code" |
| depends="init.test"> |
| <!-- Note no default is set; also testClass is not prefixed! --> |
| <echo message="Executing Xalan-xsltc api test: ${testClass}" /> |
| <property name="testType" value="api." /> |
| <antcall target="run.xalantest"> |
| <param name="xalantest.classpathref" |
| value="xsltc.compile.class.path" /> |
| <!-- Explicitly set TransformerFactory property to use xsltc --> |
| <param name="sysprop.transfact" |
| value="org.apache.xalan.xsltc.trax.TransformerFactoryImpl" /> |
| </antcall> |
| </target> |
| |
| <!-- =================================================================== --> |
| <!-- Install/Uninstall targets - not currently applicable --> |
| <!-- =================================================================== --> |
| <target name="install"> |
| <echo message="${ant.project.name} currently doesn't support (un)installation; try jar or api instead"/> |
| </target> |
| <target name="uninstall"> |
| <echo message="${ant.project.name} currently doesn't support (un)installation; try distclean instead"/> |
| </target> |
| |
| </project> |