6 Replies Latest reply on Jun 17, 2006 11:03 AM by Song He

    SeamTest fails

    Dan Liu Apprentice

      We are thinking of start using SeamTest again since seam going to GA. However, we can't get it working and there's no way to find out what causes the problem.

      Here is the exception.

      FAILED: end
      java.lang.NullPointerException
      at org.jboss.seam.mock.SeamTest.end(SeamTest.java:297)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.testng.internal.MethodHelper.invokeMethod(MethodHelper.java:536)
      at org.testng.internal.Invoker.invokeConfigurationMethod(Invoker.java:316)
      at org.testng.internal.Invoker.invokeConfigurations(Invoker.java:152)
      at org.testng.internal.Invoker.invokeMethod(Invoker.java:465)
      at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:672)
      at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:92)
      at org.testng.TestRunner.privateRun(TestRunner.java:624)
      at org.testng.TestRunner.run(TestRunner.java:515)
      at org.testng.SuiteRunner.privateRun(SuiteRunner.java:221)
      at org.testng.SuiteRunner.run(SuiteRunner.java:147)
      at org.testng.eclipse.runner.RemoteTestNG.run(RemoteTestNG.java:98)
      at org.testng.eclipse.runner.RemoteTestNG.main(RemoteTestNG.java:138)

      FAILED: init
      java.lang.NullPointerException
      at org.jboss.seam.mock.SeamTest$Script.run(SeamTest.java:213)
      at com.mytest.MyObject.init(InitMonthlyTypes.java:95)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.testng.internal.MethodHelper.invokeMethod(MethodHelper.java:536)
      at org.testng.internal.Invoker.invokeMethod(Invoker.java:395)
      at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:672)
      at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:92)
      at org.testng.TestRunner.privateRun(TestRunner.java:624)
      at org.testng.TestRunner.run(TestRunner.java:515)
      at org.testng.SuiteRunner.privateRun(SuiteRunner.java:221)
      at org.testng.SuiteRunner.run(SuiteRunner.java:147)
      at org.testng.eclipse.runner.RemoteTestNG.run(RemoteTestNG.java:98)
      at org.testng.eclipse.runner.RemoteTestNG.main(RemoteTestNG.java:138)

      SKIPPED: cleanup



        • 1. Re: SeamTest fails
          Song He Newbie

          Not only the tests failed. The examples don't work at all .. It seems to me that Seam GA is screwed (RC3 worked fine). I got errors as below:

          23:10:48,656 ERROR [[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception
          javax.faces.FacesException: Error calling action method of component with id _id0:_id6
          at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
          at javax.faces.component.UICommand.broadcast(UICommand.java:106)
          at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:90)
          at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:164)
          at org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:316)
          at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
          at javax.faces.webapp.FacesServlet.service(FacesServlet.java:106)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
          at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
          at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
          at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
          at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
          at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
          at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
          at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
          at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
          at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
          at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
          at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
          at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
          at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
          at java.lang.Thread.run(Thread.java:595)
          Caused by: javax.faces.el.EvaluationException: Exception while invoking expression #{register.register}
          at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:153)
          at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
          ... 24 more
          Caused by: javax.ejb.EJBException: java.lang.RuntimeException: java.lang.NoSuchMethodError: javax.interceptor.InvocationContext.getTarget()Ljava/lang/Object;
          at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:69)
          at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:83)
          at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:197)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:62)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:78)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.ejb3.stateless.StatelessContainer.localInvoke(StatelessContainer.java:181)
          at org.jboss.ejb3.stateless.StatelessLocalProxy.invoke(StatelessLocalProxy.java:79)
          at $Proxy73.register(Unknown Source)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:585)
          at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:129)
          ... 25 more
          Caused by: java.lang.RuntimeException: java.lang.NoSuchMethodError: javax.interceptor.InvocationContext.getTarget()Ljava/lang/Object;
          at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:128)
          at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:47)
          at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
          at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:79)
          ... 45 more
          Caused by: java.lang.NoSuchMethodError: javax.interceptor.InvocationContext.getTarget()Ljava/lang/Object;
          at org.jboss.seam.ejb.SeamInterceptor.aroundInvoke(SeamInterceptor.java:38)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
          at java.lang.reflect.Method.invoke(Method.java:585)
          at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
          ... 52 more

          It is embarassing to call this GA even when the code is free.[size=18]

          • 2. Re: SeamTest fails
            Thomas Heute Master

            Please read the instructions from the getting started guide.
            http://labs.jboss.com/portal/jbossseam/gettingstarted/index.html

            You need to use the JEMS installer

            • 3. Re: SeamTest fails
              Thomas Heute Master

              liudan, we need to know what you tried to achieve so we can help you, your code would be useful

              • 4. Re: SeamTest fails
                Dan Liu Apprentice

                I've just noticed one of our methods named init() and SeamTest has got the seam method name. changing the method name solve the problem. The NullPointerException and "comp not bound" stopped us using seamtest for a couple of months now. As it works now, guess we can start using seamtest again.

                I do feel that seam's error message need to be somehow improved.

                Anyway, Thanks tom.

                • 5. Re: SeamTest fails
                  Song He Newbie

                  It turned out that Seam 1.0.0GA cannot work with JAS 4.0.4SP1. JAS needs to updated with EJB-3.0_RC8_FD to get things work. Hope this helps.

                  • 6. Re: SeamTest fails
                    Song He Newbie

                     

                    "songhe" wrote:
                    It turned out that Seam 1.0.0GA cannot work with JAS 4.0.4SP1. JAS needs to be updated with EJB-3.0_RC8_FD to get things work. Hope this helps.