You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cactus-user@jakarta.apache.org by Sam Joseph <ga...@yha.att.ne.jp> on 2002/04/23 17:25:56 UTC
Re: Problem with ServletInit and testSetAttribute in tests_tomcat
_40
Ryan Campbell wrote:
>Vincent,
> Mi culpa. I had an old (Tomcat 3.2) servlet.jar in my CLASSPATH
>environment variable. Removing this solved my problems. Cactus 1.2 & 1.3
>run flawlessly. I hadn't had this problem before because the Tomcat 4.0.x
>startup scripts don't include the environmental CLASSPATH in Tomcat's
>classpath.
>
Thanks Ryan, looks like I had the same problem. I threw out the old
classpath and I can now run a much bigger swathe of tests, although I
now have a new error
[junit] Testcase: testStatusCode took 0.02 sec
[junit] Caused an ERROR
[junit] Server returned HTTP response code: 401 for URL:
http://localhost:8180/test/ServletRedirector/
[junit] java.io.IOException: Server returned HTTP response code: 401
for URL: http://localhost:8180/test/ServletRedirector/
[junit] at
sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:562)
[junit] at
org.apache.cactus.client.AutoReadHttpURLConnection.getInputStream(AutoReadHttpURLConnection.java:127)
[junit] at
org.apache.cactus.client.AbstractHttpClient.doTest(AbstractHttpClient.java:136)
[junit] at
org.apache.cactus.AbstractTestCase.runGenericTest(AbstractTestCase.java:422)
[junit] at
org.apache.cactus.ServletTestCase.runTest(ServletTestCase.java:130)
[junit] at
org.apache.cactus.AbstractTestCase.runBare(AbstractTestCase.java:371)
[junit] at junit.framework.TestResult$1.protect(TestResult.java:106)
[junit] at
junit.framework.TestResult.runProtected(TestResult.java:124)
[junit] at junit.framework.TestResult.run(TestResult.java:109)
[junit] at junit.framework.TestCase.run(TestCase.java:131)
[junit] at junit.framework.TestSuite.runTest(TestSuite.java:173)
[junit] at junit.framework.TestSuite.run(TestSuite.java:168)
[junit] at junit.framework.TestSuite.runTest(TestSuite.java:173)
[junit] at junit.framework.TestSuite.run(TestSuite.java:168)
[junit] at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:231)
[junit] at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:409)
[junit]
CHEERS> SAM
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem with ServletInit and testSetAttribute in tests_tomcat
_40
Posted by Sam Joseph <ga...@yha.att.ne.jp>.
Hi Vincent
Vincent Massol wrote:
>Sam,
>
>Removing the trailing slash and modify your web.xml accordingly should
>solve your problem.
>
Thanks, I'll do that. Although I'm a little scared of modifying the
web.xml files :-)
>I would also suggest to migrate to Cactus 1.3 (see migration guide on
>web site).
>
Sure. Thanks for all your help on this.
CHEERS> SAM
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
RE: Problem with ServletInit and testSetAttribute in tests_tomcat _40
Posted by Vincent Massol <vm...@octo.com>.
Sam,
Removing the trailing slash and modify your web.xml accordingly should
solve your problem.
I would also suggest to migrate to Cactus 1.3 (see migration guide on
web site).
Thanks
-Vincent
> -----Original Message-----
> From: Sam Joseph [mailto:gaijin@yha.att.ne.jp]
> Sent: 23 April 2002 16:26
> To: Cactus Users List
> Subject: Re: Problem with ServletInit and testSetAttribute in
tests_tomcat
> _40
>
> Ryan Campbell wrote:
>
> >Vincent,
> > Mi culpa. I had an old (Tomcat 3.2) servlet.jar in my CLASSPATH
> >environment variable. Removing this solved my problems. Cactus 1.2
&
> 1.3
> >run flawlessly. I hadn't had this problem before because the Tomcat
> 4.0.x
> >startup scripts don't include the environmental CLASSPATH in Tomcat's
> >classpath.
> >
> Thanks Ryan, looks like I had the same problem. I threw out the old
> classpath and I can now run a much bigger swathe of tests, although I
> now have a new error
>
> [junit] Testcase: testStatusCode took 0.02 sec
> [junit] Caused an ERROR
> [junit] Server returned HTTP response code: 401 for URL:
> http://localhost:8180/test/ServletRedirector/
> [junit] java.io.IOException: Server returned HTTP response code:
401
> for URL: http://localhost:8180/test/ServletRedirector/
> [junit] at
>
sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnec
ti
> on.java:562)
> [junit] at
>
org.apache.cactus.client.AutoReadHttpURLConnection.getInputStream(AutoRe
ad
> HttpURLConnection.java:127)
> [junit] at
>
org.apache.cactus.client.AbstractHttpClient.doTest(AbstractHttpClient.ja
va
> :136)
> [junit] at
>
org.apache.cactus.AbstractTestCase.runGenericTest(AbstractTestCase.java:
42
> 2)
> [junit] at
> org.apache.cactus.ServletTestCase.runTest(ServletTestCase.java:130)
> [junit] at
> org.apache.cactus.AbstractTestCase.runBare(AbstractTestCase.java:371)
> [junit] at
> junit.framework.TestResult$1.protect(TestResult.java:106)
> [junit] at
> junit.framework.TestResult.runProtected(TestResult.java:124)
> [junit] at junit.framework.TestResult.run(TestResult.java:109)
> [junit] at junit.framework.TestCase.run(TestCase.java:131)
> [junit] at
junit.framework.TestSuite.runTest(TestSuite.java:173)
> [junit] at junit.framework.TestSuite.run(TestSuite.java:168)
> [junit] at
junit.framework.TestSuite.runTest(TestSuite.java:173)
> [junit] at junit.framework.TestSuite.run(TestSuite.java:168)
> [junit] at
>
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTe
st
> Runner.java:231)
> [junit] at
>
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitT
es
> tRunner.java:409)
> [junit]
>
> CHEERS> SAM
>
>
> --
> To unsubscribe, e-mail: <mailto:cactus-user-
> unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:cactus-user-
> help@jakarta.apache.org>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>