[jboss-user] [JBoss Portal] - Unit testing portlet

rashmitambe do-not-reply at jboss.com
Wed Oct 22 12:35:00 EDT 2008


Hello All

Has anybody used portletunit for unit testing portlets? There is very less help available and there is no community as well. I am trying to use it for testing Portlets in Jboss portal platform and getting erros as -


  | 
  |     java.lang.RuntimeException: Unable to autoload servlet: javax.faces.webapp.FacesServlet: java.lang.NullPointerException
  |     	at com.meterware.servletunit.WebApplication$WebResourceMap.autoLoadServlets(WebApplication.java:997)
  |     	at com.meterware.servletunit.WebApplication.<init>(WebApplication.java:132)
  |     	at com.meterware.servletunit.ServletRunner.<init>(ServletRunner.java:109)
  |     	at net.sf.portletunit.PortletRunner.createPortletRunner(PortletRunner.java:128)
  |     	at net.sf.portletunit.PortletRunner.createPortletRunner(PortletRunner.java:104)
  |     	at com.groundworkopensource.portal.dashboard.test.TestTreePortlet.testHelloWorld(TestTreePortlet.java:47)
  |     	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  |     	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
  |     	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  |     	at java.lang.reflect.Method.invoke(Unknown Source)
  |     	at junit.framework.TestCase.runTest(TestCase.java:154)
  |     	at junit.framework.TestCase.runBare(TestCase.java:127)
  |     	at junit.framework.TestResult$1.protect(TestResult.java:106)
  |     	at junit.framework.TestResult.runProtected(TestResult.java:124)
  |     	at junit.framework.TestResult.run(TestResult.java:109)
  |     	at junit.framework.TestCase.run(TestCase.java:118)
  |     	at junit.framework.TestSuite.runTest(TestSuite.java:208)
  |     	at junit.framework.TestSuite.run(TestSuite.java:203)
  |     	at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:128)
  |     	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
  |     	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
  |     	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
  |     	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
  |     	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
  |      
  |       
  | 

If anybody can help with portletunit or has used any other framework to test portlets, please reply.


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4183921#4183921

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4183921



More information about the jboss-user mailing list