gump-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject [GUMP][PATCH] Make test resources available
Date Wed, 14 Apr 2004 07:09:09 GMT
Hi,

Using Gump, some of the tests fail to load resources since the JVM has
dropped build/cocoon-@@DATE@@/test from the CLASSPATH (some JDKs do so
for non-existant entries on startup).  To avoid that, Gump has to
create the directory before invoking Ant, patch appended.

On my machine (Linux, in case it matters)
IOUtilsTestCase#testNormalizedFilename fails with an ArrayIndexOOBE
for the empty String (the second test from the array).  Stack-Trace:

    [junit] java.lang.ArrayIndexOutOfBoundsException: 0
    [junit] 	at org.apache.cocoon.util.IOUtils.normalizedFilename(IOUtils.java:203)
    [junit] 	at org.apache.cocoon.util.test.IOUtilsTestCase.testNormalizedFilename(IOUtilsTestCase.java:82)
    [junit] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [junit] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    [junit] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

line numer in IOUtilsTestCase.java is wrong since I added a System.err
in front of the assert in order to know which file name causes the
exception.

Cheers

        Stefan

Index: gump.xml
===================================================================
RCS file: /home/cvspublic/cocoon-2.1/gump.xml,v
retrieving revision 1.142
diff -u -r1.142 gump.xml
--- gump.xml	13 Apr 2004 09:43:08 -0000	1.142
+++ gump.xml	14 Apr 2004 07:03:37 -0000
@@ -35,6 +35,8 @@
   <project name="cocoon">
     <package>org.apache.cocoon</package>
 
+    <mkdir dir="build/cocoon-@@DATE@@/test"/>
+
     <ant target="gump-core">
       <property name="version" value="@@DATE@@"/>
       <depend property="logkit.jar" project="avalon-logkit"/>

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@gump.apache.org
For additional commands, e-mail: general-help@gump.apache.org


Mime
View raw message