You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Martin Cooper <ma...@apache.org> on 2002/12/29 07:37:18 UTC

Cactus tests failing

Trying to run the Cactus tests, I'm getting a very strange error. Many of
the tests succeed just fine, but then I get an HTTP 500 error on the
testCookieStringEquals test, with a partial stack trace looking like this:

----- Root Cause -----
javax.servlet.ServletException: org.apache.cactus.util.Configuration.isLoggingEnabled()Z
	at
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:533)
	at
org.apache.jsp.jspRedirector_jsp._jspService(jspRedirector_jsp.java:121)

The weird thing about this is that jspRedirector_jsp.java only has 91
lines, but the exception supposedly occurs on line 121!

I get the same error with Tomcat 4.1.18 and 4.0.6, and an equivalent error
with Tomcat 3.3.1, so either my system is misconfigured, or we have a bug
in the tests. Given that the error message refers to a non-existent line
of code, I'm having a hard time figuring out which...

I'm using Cactus 13-1.3 (the tests fail even earlier with more recent
versions) and Ant 1.5.1.

Anyone have any idea what's up?

--
Martin Cooper



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


Re: Cactus tests failing

Posted by Martin Cooper <ma...@apache.org>.
So I finally figured this out. There were two gotchas I ran into, and I
figured it might be worthwhile to report back on them so that other people
don't have to go through the same pain. ;-)

At first, I tried to use Cactus 1.4.1, the latest release. I discovered
that this does not work, because the LogService class that we use in
jspRedirector.jsp no longer exists, as of Cactus 1.4.

So I backed off to Cactus 1.3, which is what I was using the last time I
had the tests working, but then ran into the problem I reported below.
While combing the logs, I finally noticed that somehow 2 versions of the
Cactus jars, and 2 versions of the AspectJ jars, were in my classpath. I
have no idea how that happened, but an 'ant clean dist' fixed that.

Then I ran into a failure with the DynaBean tests. Most were working, but
the String test was not. This didn't make sense, so I fiddled around for a
while, and eventually discovered that everything works as long as I set
the junit.home property to the Cactus lib directory.

All this boils down to two tips for getting the tests running:

1) Always do an 'ant dist clean' before running the tests, and check the
classpath being used by the tests.

2) Don't worry about what version of JUnit to use, just use whatever is in
the Cactus distribution, whatever that happens to be, because if you use
something different, the tests may fail.

Happy testing!

--
Martin Cooper


On Sat, 28 Dec 2002, Martin Cooper wrote:

> Trying to run the Cactus tests, I'm getting a very strange error. Many of
> the tests succeed just fine, but then I get an HTTP 500 error on the
> testCookieStringEquals test, with a partial stack trace looking like this:
>
> ----- Root Cause -----
> javax.servlet.ServletException: org.apache.cactus.util.Configuration.isLoggingEnabled()Z
> 	at
> org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:533)
> 	at
> org.apache.jsp.jspRedirector_jsp._jspService(jspRedirector_jsp.java:121)
>
> The weird thing about this is that jspRedirector_jsp.java only has 91
> lines, but the exception supposedly occurs on line 121!
>
> I get the same error with Tomcat 4.1.18 and 4.0.6, and an equivalent error
> with Tomcat 3.3.1, so either my system is misconfigured, or we have a bug
> in the tests. Given that the error message refers to a non-existent line
> of code, I'm having a hard time figuring out which...
>
> I'm using Cactus 13-1.3 (the tests fail even earlier with more recent
> versions) and Ant 1.5.1.
>
> Anyone have any idea what's up?
>
> --
> Martin Cooper
>
>
>
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>


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