]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
Fork JUnit test in new VM. (Maybe this fixes classpath problems with commons-logging...
authorJeremias Maerki <jeremias@apache.org>
Thu, 6 Jan 2005 19:20:37 +0000 (19:20 +0000)
committerJeremias Maerki <jeremias@apache.org>
Thu, 6 Jan 2005 19:20:37 +0000 (19:20 +0000)
Added layout engine tests specifying a default exclusion file.
To disable the exclusion file add the following line to your build-local.properties:
layoutengine.disabled=

git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@198243 13f79535-47bb-0310-9956-ffa450edef68

build.properties
build.xml

index 0bd20366bb2ad9970dd9b71112c7bb2571857827..e88b5e024b029d2285050d48f98fb015f5541dad 100644 (file)
@@ -4,6 +4,12 @@
 # output format for "ant examples"
 build.property.examples.mime.type = application/pdf
 
+# decides if JUnit test shall be forked
+junit.fork = on
+
+# specifies the default file that contains a list of disabled layout engine tests.
+layoutengine.disabled=test/layoutengine/disabled-testcases.txt
+
 # directory for optional-lib (so there is no need to copy the jar into
 # the fop/lib directory
 # optional.lib.dir = <Optional Lib Directory>
\ No newline at end of file
index fa5ce1553da12761d9b9970c32195a95fb08e046..cdcaf9cb3b130f758bab52a6be8a54393e2d9198 100644 (file)
--- a/build.xml
+++ b/build.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0"?>
 <!--
-  Copyright 1999-2004 The Apache Software Foundation
+  Copyright 1999-2005 The Apache Software Foundation
 
   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
@@ -168,7 +168,7 @@ list of possible build targets.
     <property name="NAME" value="FOP"/>
     <property name="version" value="1.0dev"/>
     <filter token="version" value="${version}"/>
-    <property name="year" value="1999-2004"/>
+    <property name="year" value="1999-2005"/>
 
     <echo message="------------------- ${Name} ${version} [${year}] ----------------"/>
     <echo message="See build.properties and build-local.properties for additional build settings"/>
@@ -177,7 +177,7 @@ list of possible build targets.
     <property name="debug" value="on"/>
     <property name="optimize" value="off"/>
     <property name="deprecation" value="on"/>
-
+    
     <property name="textfontencoding" value="WinAnsiEncoding"/>
 
     <property name="src.dir" value="${basedir}/src"/>
@@ -673,7 +673,7 @@ list of possible build targets.
     </javac>
     <echo message="Running basic functionality tests for fop-transcoder.jar"/>
     <mkdir dir="${build.dir}/test-reports/fop-transcoder"/>
-    <junit haltonerror="yes">
+    <junit haltonerror="yes" fork="${junit.fork}">
       <sysproperty key="basedir" value="${basedir}"/>
       <formatter type="brief" usefile="false"/>
       <classpath>
@@ -691,7 +691,7 @@ list of possible build targets.
     </junit>
     <echo message="Running basic functionality tests for fop-transcoder-allinone.jar"/>
     <mkdir dir="${build.dir}/test-reports/fop-transcoder-allinone"/>
-    <junit haltonerror="yes">
+    <junit haltonerror="yes" fork="${junit.fork}">
       <sysproperty key="basedir" value="${basedir}"/>
       <formatter type="brief" usefile="false"/>
       <classpath>
@@ -711,7 +711,7 @@ list of possible build targets.
     </junit>
     <echo message="Running basic functionality tests for fop.jar"/>
     <mkdir dir="${build.dir}/test-reports/fop"/>
-    <junit haltonerror="yes">
+    <junit haltonerror="yes" fork="${junit.fork}">
       <sysproperty key="basedir" value="${basedir}"/>
       <formatter type="brief" usefile="false"/>
       <classpath>
@@ -728,6 +728,25 @@ list of possible build targets.
         </fileset>
       </batchtest>
     </junit>
+    <echo message="Running layout engine tests"/>
+    <mkdir dir="${build.dir}/test-reports/fop"/>
+    <junit haltonerror="yes" fork="${junit.fork}">
+      <sysproperty key="basedir" value="${basedir}"/>
+      <sysproperty key="fop.layoutengine.disabled" value="${layoutengine.disabled}"/>
+      <formatter type="brief" usefile="false"/>
+      <classpath>
+        <pathelement location="${build.dir}/test-classes"/>
+        <path refid="libs-build-classpath"/>
+        <fileset dir="build">
+          <include name="fop.jar"/>
+        </fileset>
+      </classpath>
+      <batchtest todir="${build.dir}/test-reports/fop">
+        <fileset dir="${build.dir}/test-classes">
+          <include name="org/apache/fop/layoutengine/LayoutEngineTestSuite.class"/>
+        </fileset>
+      </batchtest>
+    </junit>
   </target>
 
   <!-- =================================================================== -->