You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beehive.apache.org by js...@apache.org on 2004/10/05 23:50:03 UTC
svn commit: rev 53827 - in incubator/beehive/trunk/controls/test/webapps/common: . milton milton/resources milton/resources/milton milton/resources/milton/jsp milton/src milton/src/global
Author: jsong
Date: Tue Oct 5 14:50:02 2004
New Revision: 53827
Added:
incubator/beehive/trunk/controls/test/webapps/common/
incubator/beehive/trunk/controls/test/webapps/common/milton/
incubator/beehive/trunk/controls/test/webapps/common/milton/resources/
incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/
incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/jsp/
incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/jsp/miltonResults.jsp
incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/jsp/miltonResultsTemplate.jsp
incubator/beehive/trunk/controls/test/webapps/common/milton/src/
incubator/beehive/trunk/controls/test/webapps/common/milton/src/global/
incubator/beehive/trunk/controls/test/webapps/common/milton/src/global/Global.app
Log:
forgot a few files in last checkin for zsmith@bea.com's bug fix
Added: incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/jsp/miltonResults.jsp
==============================================================================
--- (empty file)
+++ incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/jsp/miltonResults.jsp Tue Oct 5 14:50:02 2004
@@ -0,0 +1,14 @@
+<!-- WARNING: This file is part of the test framework. It is copied
+ into this webapp at build time. Any changes you make to
+ this file will be lost the next time you rebuild.
+ DO NOT ADD THIS FILE TO YOUR WEBAPP! -->
+
+<%@ page contentType="text/html;charset=UTF-8" language="java" %>
+<html>
+ <head>
+ <title>Milton Test Results</title>
+ </head>
+ <body>
+ <jsp:include page="miltonResultsTemplate.jsp" />
+ </body>
+</html>
Added: incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/jsp/miltonResultsTemplate.jsp
==============================================================================
--- (empty file)
+++ incubator/beehive/trunk/controls/test/webapps/common/milton/resources/milton/jsp/miltonResultsTemplate.jsp Tue Oct 5 14:50:02 2004
@@ -0,0 +1,23 @@
+<!-- WARNING: This file is part of the test framework. It is copied
+ into this webapp at build time. Any changes you make to
+ this file will be lost the next time you rebuild.
+ DO NOT ADD THIS FILE TO YOUR WEBAPP! -->
+
+<%@ page contentType="text/html;charset=UTF-8" language="java" %>
+
+<%@ page import="org.apache.beehive.test.tools.milton.common.Report"%>
+<%@ page import="org.apache.beehive.netui.pageflow.PageFlowUtils"%>
+
+<% Report report = (Report)PageFlowUtils.getPageInput(Report.KEY, request); %>
+
+<table border="1" id="<% out.print(Report.RESULT_TABLE_ID); %>">
+ <tr>
+ <td id="<% out.print(Report.STATUS_ID); %>"><% out.print(report.getStatus()); %></td>
+ </tr>
+ <tr>
+ <td id="<% out.print(Report.MESSAGE_ID); %>"><% out.print(report.getMessage()); %></td>
+ </tr>
+ <tr>
+ <td id="<% out.print(Report.EXCEPTION_ID); %>"><% out.print(report.getExceptionStack()); %></td>
+ </tr>
+</table>
Added: incubator/beehive/trunk/controls/test/webapps/common/milton/src/global/Global.app
==============================================================================
--- (empty file)
+++ incubator/beehive/trunk/controls/test/webapps/common/milton/src/global/Global.app Tue Oct 5 14:50:02 2004
@@ -0,0 +1,34 @@
+package global;
+
+import org.apache.beehive.test.tools.milton.common.Report;
+import org.apache.beehive.netui.pageflow.*;
+import org.apache.beehive.netui.pageflow.annotations.Jpf;
+
+/**
+ * WARNING: This file is part of the test framework. It is copied
+ * into this webapp at build time. Any changes you make to
+ * this file will be lost the next time you rebuild.
+ * DO NOT ADD THIS FILE TO YOUR WEBAPP! -->
+ */
+@Jpf.Controller(
+ catches={
+ @Jpf.Catch(type=java.lang.Exception.class, method="handleException")
+ }
+)
+public class Global extends GlobalApp
+{
+ @Jpf.ExceptionHandler(
+ forwards={
+ @Jpf.Forward(name=Report.RESULTS, path=Report.RESULTSJSP)
+ }
+ )
+ protected Forward handleException(Exception ex, String actionName, String message, Object form)
+ {
+ Report report = (Report)getRequest().getAttribute(Report.KEY);
+
+ if (null == report)
+ report = new Report(Report.ABORT, "An Unexpected Exception Was Found", ex);
+
+ return new Forward(Report.RESULTS, Report.KEY, report);
+ }
+}