You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cactus-user@jakarta.apache.org by Jo...@ubs.com on 2004/09/23 20:10:15 UTC
Form
I am trying to set up testcases for a struts site with form based authentication. However, I have not been able to get passed the authentication.
Thanks,
John
--------- URL -------------
http://localhost:8320/ServletTestRunner?suite=test.TestFormAuthentication
---------- Results ---------------------
- <testsuites>
- <testsuite name="test.TestFormAuthentication" tests="1" failures="0" errors="1" time="1.203">
- <testcase name="testFormAuthentication" time="1.031">
<error message="Failed to get the test results at [http://localhost:8320/ServletRedirectorSecure]" type="org.apache.cactus.util.ChainedRuntimeException">org.apache.cactus.util.ChainedRuntimeException: Failed to get the test results at [http://localhost:8320/ServletRedirectorSecure] at org.apache.cactus.internal.client.connector.http.DefaultHttpClient.doTest_aroundBody0(DefaultHttpClient.java:92) at org.apache.cactus.internal.client.connector.http.DefaultHttpClient.doTest_aroundBody1$advice(DefaultHttpClient.java:206) at org.apache.cactus.internal.client.connector.http.DefaultHttpClient.doTest(DefaultHttpClient.java) at org.apache.cactus.internal.client.connector.http.HttpProtocolHandler.runWebTest(HttpProtocolHandler.java:159) at
---------------- web.xml ------------------------------
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
" http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
<!-- <filter>
<filter-name>AuthenticationFilter</filter-name>
<filter-class>RegRptAuthenticationFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>AuthenticationFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
-->
<!-- =========== LISTENERS ======================== -->
<listener>
<listener-class>ApplicationAssembler</listener-class>
</listener>
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet>
<servlet-name>ServletRedirector</servlet-name>
<servlet-class>
org.apache.cactus.server.ServletTestRedirector
</servlet-class>
<init-param>
<param-name>param1</param-name>
<param-value>value1 used for testing</param-value>
</init-param>
</servlet>
<servlet>
Visit our website at http://www.ubs.com
This message contains confidential information and is intended only
for the individual named. If you are not the named addressee you
should not disseminate, distribute or copy this e-mail. Please
notify the sender immediately by e-mail if you have received this
e-mail by mistake and delete this e-mail from your system.
E-mail transmission cannot be guaranteed to be secure or error-free
as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses. The sender therefore
does not accept liability for any errors or omissions in the contents
of this message which arise as a result of e-mail transmission. If
verification is required please request a hard-copy version. This
message is provided for informational purposes and should not be
construed as a solicitation or offer to buy or sell any securities or
related financial instruments.
RE: Form
Posted by Vincent Massol <vm...@pivolis.com>.
Hi John,
Have you been able to solve your problem? I personally have no knowledge of
using Cactus with Struts and I haven't coded the form-authentication support
in Cactus. Have you tried searching the Cactus mailing list archives?
Thanks
-Vincent
_____
From: John.Cotter@ubs.com [mailto:John.Cotter@ubs.com]
Sent: jeudi 23 septembre 2004 20:10
To: cactus-user@jakarta.apache.org
Subject: Form
I am trying to set up testcases for a struts site with form based
authentication. However, I have not been able to get passed the
authentication.
Thanks,
John
--------- URL -------------
http://localhost:8320/ServletTestRunner?suite=test.TestFormAuthentication
---------- Results ---------------------
- <testsuites>
- <testsuite name="test.TestFormAuthentication" tests="1" failures="0"
errors="1" time="1.203">
- <testcase name="testFormAuthentication" time="1.031">
<error message="Failed to get the test results at
[http://localhost:8320/ServletRedirectorSecure]"
type="org.apache.cactus.util.ChainedRuntimeException">org.apache.cactus.util
.ChainedRuntimeException: Failed to get the test results at
[http://localhost:8320/ServletRedirectorSecure] at
org.apache.cactus.internal.client.connector.http.DefaultHttpClient.doTest_ar
oundBody0(DefaultHttpClient.java:92) at
org.apache.cactus.internal.client.connector.http.DefaultHttpClient.doTest_ar
oundBody1$advice(DefaultHttpClient.java:206) at
org.apache.cactus.internal.client.connector.http.DefaultHttpClient.doTest(De
faultHttpClient.java) at
org.apache.cactus.internal.client.connector.http.HttpProtocolHandler.runWebT
est(HttpProtocolHandler.java:159) at
---------------- web.xml ------------------------------
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
<!-- <filter>
<filter-name>AuthenticationFilter</filter-name>
<filter-class>RegRptAuthenticationFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>AuthenticationFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
-->
<!-- =========== LISTENERS ======================== -->
<listener>
<listener-class>ApplicationAssembler</listener-class>
</listener>
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet>
<servlet-name>ServletRedirector</servlet-name>
<servlet-class>
org.apache.cactus.server.ServletTestRedirector
</servlet-class>
<init-param>
<param-name>param1</param-name>
<param-value>value1 used for testing</param-value>
</init-param>
</servlet>
<servlet>