I am tryin to test a simple session bean. This bean has a simple method:
public String printName(String n){
String name=n;
System.out.println("name is "+ name);
return name;
}
I followed the EJB example provided in the cactus/samples to write a test class
for this bean and included the following method to test my printName(..) method:
public void testPrintName() throws Exception
{
try
{
String s = cFacade.printName("john");
assertNotNull(s);
}
catch(Exception e)
{
e.printStackTrace();
}
}
But when I run my test class using the browser, I get the following errors:
Name: testPrintName
Status: Error
"
org.apache.commons.httpclient.HttpMethod.setRequestHeader
(Ljava/lang/String;Ljava/lang/String;)V
java.lang.NoSuchMethodError:
org.apache.commons.httpclient.HttpMethod.setRequestHeader
(Ljava/lang/String;Ljava/lang/String;)V
at
org.apache.cactus.client.connector.http.HttpClientConnectionHelper.dispatch50_co
nnect(HttpClientConnectionHelper.java;org/apache/cactus/util/log/LogAspect.aj
[1k]:152)
at ....".
Can anyone guide me how to solve this problem or any other information on
testing ejb.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]