jakarta-cactus-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pujari, Ashis" <ashis.puj...@cbm.com>
Subject RE: Exception in constructor: testSaveToSessionOK
Date Sun, 04 Jan 2004 21:48:27 GMT

My classes are in inside an expanded folder format (not archive like WAR
or JAR) in the JBoss server deploy folder. Is it not enough if I drop
them under the deploy folder? Do I still need to add it to the
classpath? I am able to access servlets in my application but when I try
accessing the test case it is throwing this exception. 


-----Original Message-----
From: Martin Gainty [mailto:mgainty@hotmail.com] 
Sent: Saturday, January 03, 2004 8:30 PM
To: Cactus Users List
Subject: Re: Exception in constructor: testSaveToSessionOK

Ashis-
Do you mean your class is located in the WAR?
or in a jar thats on the classpath?
I guess I dont know what you mean by "in the application"?
Regards,
Martin
----- Original Message ----- 
From: "Pujari, Ashis" <ashis.pujari@cbm.com>
To: "Cactus Users List" <cactus-user@jakarta.apache.org>
Sent: Saturday, January 03, 2004 2:58 PM
Subject: RE: Exception in constructor: testSaveToSessionOK



TestSampleServlet.class , SampleServlet.class are in the same package
inside my application.

-----Original Message-----
From: Martin Gainty [mailto:mgainty@hotmail.com] 
Sent: Saturday, January 03, 2004 2:42 PM
To: Cactus Users List
Subject: Re: Exception in constructor: testSaveToSessionOK

is TestSampleServlet.class is on your classpath?
-Martin
----- Original Message ----- 
From: "Pujari, Ashis" <ashis.pujari@cbm.com>
To: <cactus-user@jakarta.apache.org>
Sent: Saturday, January 03, 2004 2:39 PM
Subject: Exception in constructor: testSaveToSessionOK 



Hi, 

I tired to use the testcase -> TestSampleServlet given as example on
Cactus website. Added the following jars to my web application running
on jboss-3.2.1_tomcat 4.1.24: 
 aspectjrt-1.1.1.jar
 cactus-1.5.jar
 cactus-ant-1.5.jar
 commons-httpclient-2.0-rc2.jar
 commons-logging-1.0.3.jar
 httpunit-1.5.3.jar
 junit-3.8.1.jar
 nekohtml-0.7.4.jar
 servletapi-2.3.jar

I compiled the file TestCase using these jars.

But on accessing the URL
http://localhost:8080/ashtest/ServletTestRunner?suite=com.ash.test.TestS
ampleServlet I am getting the exception below. I do not have any older
versions of junit. Any solutions ?  
Thanks
Ashis


========================================================================
==
  <?xml version="1.0" encoding="UTF-8" ?> 
- <testsuites>
- <testsuite name="com.ash.test.TestSampleServlet" tests="1"
failures="1" errors="0" time="0">
- <testcase name="warning" time="0">
  <failure message="Exception in constructor: testSaveToSessionOK
(java.lang.NoClassDefFoundError at
org.apache.cactus.ServletTestCase.init(ServletTestCase.java:188) at
org.apache.cactus.ServletTestCase.<init>(ServletTestCase.java:164) at
com.ash.test.TestSampleServlet.<init>(TestSampleServlet.java:13) at
java.lang.reflect.Constructor.newInstance(Native Method) at
junit.framework.TestSuite.createTest(TestSuite.java:135) at
junit.framework.TestSuite.addTestMethod(TestSuite.java:114) at
junit.framework.TestSuite.<init>(TestSuite.java:75) at
com.ash.test.TestSampleServlet.suite(TestSampleServlet.java:18) at
java.lang.reflect.Method.invoke(Native Method) at
junit.runner.BaseTestRunner.getTest(BaseTestRunner.java:111) at 

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



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


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



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


Mime
View raw message