Hi,
 
I am trying to run a JWebUnit test in IBM's RAD. I have configured all the required jar files from JUnit and JWebUnit. I am executing the test using JUnitEE Testrunner. 
 
Here is my Test : 
 
public class ParcelTest extends WebTestCase {
 
  private static final Log LOG = LogFactory.getLog(ParcelTest.class);
 
     public ParcelTest(String name) {
         super(name);
    }

 /*
  * @see TestCase#setUp()
  */
 protected void setUp() throws Exception {
   getTestContext().setBaseUrl("http://localhost:9080/wsx");
   LOG.info("Log4j Initialized");
}
 
 
 /*
  * @see TestCase#tearDown()
  */
 public void tearDown() throws Exception {
  
 }
 
 
  public void testInfoPage(){
   
       beginAt("/BaseServlet?prmAction=prmActionGotoLogin");
        LOG.info("ending the testcase");
   
   }
}
 
I am getting the following error :
 
java.lang.NoSuchMethodError: org.apache.commons.lang.StringUtils: method substringAfter(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String; not found
at com.gargoylesoftware.htmlunit.WebResponseImpl.getContentCharSet(WebResponseImpl.java:184)
at com.gargoylesoftware.htmlunit.html.HTMLParser.parse(HTMLParser.java:215)
at com.gargoylesoftware.htmlunit.DefaultPageCreator.createHtmlPage(DefaultPageCreator.java:112)
at com.gargoylesoftware.htmlunit.DefaultPageCreator.createPage(DefaultPageCreator.java:85)
at com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:431)
at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:335)
at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:389)
at net.sourceforge.jwebunit.htmlunit.HtmlUnitDialog.beginAt(HtmlUnitDialog.java:120)
at net.sourceforge.jwebunit.WebTester.beginAt(WebTester.java:152)
at net.sourceforge.jwebunit.WebTestCase.beginAt(WebTestCase.java:88)
at org.lacsd.wsx.action.parcel.test.ParcelTest.testInfoPage(ParcelTest.java:107)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
at junit.framework.TestCase.runTest(TestCase.java:154)
The jsp I am tetsing has the DOCTYPE tag.
 
Could anyone help me resolve this error? 
 
Thanks,
Vani
 
 
 
 
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Jwebunit-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jwebunit-users

Reply via email to