You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by Erik Hatcher <ja...@ehatchersolutions.com> on 2001/12/24 13:04:17 UTC

test cases failing

I'm attempting to get CruiseControl working with the latest version (HEAD
from CVS) of Ant.  At first I built without ORO, and CruiseControl requires
the P4 tasks to be present, so I dug and found that adding ORO would get the
P4 tasks compiled, so I added it.

Then I build Ant, and run a 'build test' and got this:

Testcase:
testBackslash(org.apache.tools.ant.taskdefs.optional.perforce.P4Change
Test):   Caused an ERROR
try to access method
org.apache.tools.ant.taskdefs.optional.perforce.P4Change.ba
ckslash(Ljava/lang/String;)Ljava/lang/String; from class
org.apache.tools.ant.ta
skdefs.optional.perforce.P4ChangeTest
java.lang.IllegalAccessError: try to access method
org.apache.tools.ant.taskdefs
.optional.perforce.P4Change.backslash(Ljava/lang/String;)Ljava/lang/String;
from
 class org.apache.tools.ant.taskdefs.optional.perforce.P4ChangeTest

... digging more, I see that the backslash method is protected, so the test
case can't call it.  How did this ever work?  Or did it?  So I made
backslash 'public static final' (since its really a helper method and
doesn't need any member access), and now that test case passes.  I now get
this:

Testcase:
testVector(org.apache.tools.ant.taskdefs.optional.sitraka.ClassFileTes
t):     Caused an ERROR
null
java.lang.NullPointerException
        at java.io.DataInputStream.readInt(DataInputStream.java:338)
        at
org.apache.tools.ant.taskdefs.optional.sitraka.bytecode.ClassFile.<in
it>(ClassFile.java:90)
        at
org.apache.tools.ant.taskdefs.optional.sitraka.ClassFileTest.testVect
or(ClassFileTest.java:76)

I'm not sure where to go from here.  Can anyone lend a hand in this?

And all I want to do is get CruiseControl compiling and running.... :)  What
a tangent!

I started to go down the route of modifying CruiseControl's build so that it
did not have to have the P4 task in order to build properly, but they have
some direct references to that class in some of their code rather than using
reflection, so I thought it would be easier to just get P4 compiled into Ant
instead.... Hmmmm.... :))

I'll go ahead and commit my 'backslash' change - and I'm sure someone will
let me know if that change is inappropriate.

Thanks,
    Erik




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>