jakarta-cactus-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marcelo Römulo Fernandes <marc...@neus.com.br>
Subject Problems with Cactus + Ant
Date Tue, 01 Oct 2002 01:23:05 GMT
Hi,

    I've adapted the sample servlet build scripts that comes with 
cactus  to test my application. It works, but I've got two problems:
    1 - Every time I run the test, I must restart the server 
application. Is it necessary?
    2 - If I run the tests by "JUnit 3.7 by Kent Beck and Erich Gamma" 
swing, it's ok with release jakarta-cactus-13-1.3. However, if I use 
release jakarta-cactus-13-1.4.1, I got the following error:
      junit.framework.AssertionFailedError: Exception in constructor: 
testTeste (org.apache.commons.logging.LogConfigurationException: 
java.lang.ClassCastException
        The  works ok.
    3 - If I run tomcat by myself before running the tests, it's ok. But 
if I run tomcat from ant, I got the following error:
    [junit] Running com.neus.componentes.test.gui.TestServlet
    [junit] setup configuracaoTeste = Login
    [junit] contadorList = 0
    [junit] setup configuracaoTeste = listarCidade
    [junit] contadorList = 1
     [java] setup configuracaoTeste = Login
     [java] contadorList = 0
     [java] javax.servlet.ServletException: Error allocating a servlet 
instance
     [java]     at 
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:659)
     [java]     at 
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:652)
     [java]     at 
org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:534)
     [java]     at 
org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:497)
     [java]     at 
org.apache.cactus.server.RequestDispatcherWrapper.dispatch130_include(RequestDispatcherWrapper.java;org/apache/cactus/util/log/LogAspect.java
(1k):123)
     [java]     at 
org.apache.cactus.server.RequestDispatcherWrapper.around130_include(RequestDispatcherWrapper.java;org/apache/cactus/util/log/LogAspect.java(1
k):1147)
     [java]     at 
org.apache.cactus.server.RequestDispatcherWrapper.include(RequestDispatcherWrapper.java;org/apache/cactus/util/log/LogAspect.java(1k):118)
     [java]     at 
com.neus.componentes.test.gui.TestServlet.testTeste(TestServlet.java:253)
     [java]     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native 
Method)
     [java]     at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     [java]     at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     [java]     at java.lang.reflect.Method.invoke(Method.java:324)
     [java]     at 
org.apache.cactus.AbstractTestCase.runServerTest(AbstractTestCase.java:524)
     [java]     at 
org.apache.cactus.AbstractTestCase.runBareServerTest(AbstractTestCase.java:490)
     [java]     at 
org.apache.cactus.server.AbstractTestCaller.doTest(AbstractTestCaller.java:148)
     [java]     at 
org.apache.cactus.server.AbstractTestController.dispatch79_handleRequest(AbstractTestController.java;org/apache/cactus/util/log/LogAspect.jav
a(1k):123)
     [java]     at 
org.apache.cactus.server.AbstractTestController.around79_handleRequest(AbstractTestController.java;org/apache/cactus/util/log/LogAspect.java(
1k):1147)
     [java]     at 
org.apache.cactus.server.AbstractTestController.handleRequest(AbstractTestController.java;org/apache/cactus/util/log/LogAspect.java(1k):101)
     [java]     at 
org.apache.cactus.server.ServletTestRedirector.dispatch88_doPost(ServletTestRedirector.java;org/apache/cactus/util/log/LogAspect.java(1k):132
)
     [java]     at 
org.apache.cactus.server.ServletTestRedirector.around88_doPost(ServletTestRedirector.java;org/apache/cactus/util/log/LogAspect.java(1k):1147)

     [java]     at 
org.apache.cactus.server.ServletTestRedirector.doPost(ServletTestRedirector.java;org/apache/cactus/util/log/LogAspect.java(1k):118)
     [java]     at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
     [java]     at 
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
     [java]     at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
     [java]     at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
     [java]     at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
     [java]     at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
     [java]     at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
     [java]     at 
org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
     [java]     at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
     [java]     at 
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2347)
     [java]     at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
     [java]     at 
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
     [java]     at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
     [java]     at 
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:468)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
     [java]     at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
     [java]     at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
     [java]     at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
     [java]     at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
     [java]     at 
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:1027)
     [java]     at 
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1125)
     [java]     at java.lang.Thread.run(Thread.java:536)
    [junit] Tests run: 1, Failures: 1, Errors: 0, Time elapsed: 3.154 sec

thanks in advance
marcelo


--
To unsubscribe, e-mail:   <mailto:cactus-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:cactus-user-help@jakarta.apache.org>


Mime
View raw message