You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pluto-scm@portals.apache.org by ms...@apache.org on 2014/09/01 15:29:55 UTC

[47/63] [abbrv] git commit: Moved filter test cases to proper filter method. Added keyword "Api" to test case names whose definitions were derived from the API documentation to allow targeted test runs for that group of tests.

Moved filter test cases to proper filter method. Added keyword "Api" to test
case names whose definitions were derived from the API documentation to
allow targeted test runs for that group of tests.


Project: http://git-wip-us.apache.org/repos/asf/portals-pluto/repo
Commit: http://git-wip-us.apache.org/repos/asf/portals-pluto/commit/db1071e7
Tree: http://git-wip-us.apache.org/repos/asf/portals-pluto/tree/db1071e7
Diff: http://git-wip-us.apache.org/repos/asf/portals-pluto/diff/db1071e7

Branch: refs/heads/master
Commit: db1071e75e6c5fba83032352edf53204716b1ade
Parents: 6856ba4
Author: Scott Nicklous <ms...@apache.org>
Authored: Fri Aug 29 16:19:40 2014 +0200
Committer: Scott Nicklous <ms...@apache.org>
Committed: Fri Aug 29 16:19:40 2014 +0200

----------------------------------------------------------------------
 .../AnnotationTests_ProcessAction_Action.java   |  135 -
 ...AnnotationTests_ProcessAction_ApiAction.java |  135 +
 .../AnnotationTests_ProcessEvent_ApiEvent.java  |  124 +
 ...tationTests_ProcessEvent_ApiEvent_event.java |  125 +
 .../AnnotationTests_ProcessEvent_Event.java     |  124 -
 ...nnotationTests_ProcessEvent_Event_event.java |  125 -
 .../AnnotationTests_RenderMode_ApiRender.java   |  113 +
 .../AnnotationTests_RenderMode_Render.java      |  113 -
 .../resources/xml-resources/additionalTCs.xml   |    8 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |   48 +-
 ...EnvironmentTests_CacheControl_ApiRender.java |  288 +
 ...vironmentTests_CacheControl_ApiResource.java |  303 +
 .../EnvironmentTests_CacheControl_Render.java   |  288 -
 .../EnvironmentTests_CacheControl_Resource.java |  303 -
 ...nvironmentTests_PortalContext_ApiRender.java |  261 +
 .../EnvironmentTests_PortalContext_Render.java  |  261 -
 ...vironmentTests_PortletContext_ApiRender.java |  548 ++
 .../EnvironmentTests_PortletContext_Render.java |  548 --
 ...ironmentTests_PortletPreferences_Action.java |  781 ---
 ...nmentTests_PortletPreferences_ApiAction.java |  781 +++
 ...onmentTests_PortletPreferences_ApiEvent.java |  473 ++
 ...Tests_PortletPreferences_ApiEvent_event.java |  406 ++
 ...nmentTests_PortletPreferences_ApiRender.java |  265 +
 ...entTests_PortletPreferences_ApiResource.java |  417 ++
 ...vironmentTests_PortletPreferences_Event.java |  473 --
 ...entTests_PortletPreferences_Event_event.java |  406 --
 ...ironmentTests_PortletPreferences_Render.java |  265 -
 ...onmentTests_PortletPreferences_Resource.java |  417 --
 ...ests_PortletRequestDispatcher_ApiRender.java |  204 +
 ...ntTests_PortletRequestDispatcher_Render.java |  204 -
 ...nmentTests_PortletSessionUtil_ApiRender.java |  149 +
 ...ironmentTests_PortletSessionUtil_Render.java |  149 -
 ...vironmentTests_PortletSession_ApiRender.java |  565 ++
 .../EnvironmentTests_PortletSession_Render.java |  565 --
 ...onmentTests_PreferencesValidator_Action.java |  171 -
 ...entTests_PreferencesValidator_ApiAction.java |  171 +
 ...mentTests_PreferencesValidator_ApiEvent.java |  135 +
 ...sts_PreferencesValidator_ApiEvent_event.java |  134 +
 ...tTests_PreferencesValidator_ApiResource.java |  145 +
 ...ronmentTests_PreferencesValidator_Event.java |  135 -
 ...tTests_PreferencesValidator_Event_event.java |  134 -
 ...mentTests_PreferencesValidator_Resource.java |  145 -
 .../resources/xml-resources/additionalTCs.xml   |  648 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |  132 +-
 ...ionTests_PortletModeException_ApiRender.java |  112 +
 ...eptionTests_PortletModeException_Render.java |  112 -
 ...ionTests_UnavailableException_ApiRender.java |  143 +
 ...eptionTests_UnavailableException_Render.java |  143 -
 ...ptionTests_ValidatorException_ApiRender.java |  150 +
 ...xceptionTests_ValidatorException_Render.java |  150 -
 ...ionTests_WindowStateException_ApiRender.java |  113 +
 ...eptionTests_WindowStateException_Render.java |  113 -
 .../resources/xml-resources/additionalTCs.xml   |   24 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |   42 +-
 ...sts_ActionFilter_ApiActionFilter_filter.java |  160 +
 ...Tests_EventFilter_ApiEventFilter_filter.java |  159 +
 ...ests_FilterChain_ApiActionFilter_filter.java |  105 +
 ...Tests_FilterChain_ApiEventFilter_filter.java |  105 +
 ...ests_FilterChain_ApiRenderFilter_filter.java |  102 +
 ...ts_FilterChain_ApiResourceFilter_filter.java |  102 +
 ...sts_FilterConfig_ApiRenderFilter_filter.java |  125 +
 ...ts_PortletFilter_ApiActionFilter_filter.java |  104 +
 ...sts_PortletFilter_ApiEventFilter_filter.java |  104 +
 ...ts_PortletFilter_ApiRenderFilter_filter.java |  101 +
 ..._PortletFilter_ApiResourceFilter_filter.java |  101 +
 ...sts_RenderFilter_ApiRenderFilter_filter.java |  157 +
 ...ResourceFilter_ApiResourceFilter_filter.java |  157 +
 .../FilterTests_ActionFilter_ActionFilter.java  |  293 -
 ...ilterTests_ActionFilter_ApiActionFilter.java |  206 +
 .../FilterTests_EventFilter_ApiEventFilter.java |  201 +
 ...rTests_EventFilter_ApiEventFilter_event.java |  102 +
 .../FilterTests_EventFilter_EventFilter.java    |  201 -
 ...lterTests_EventFilter_EventFilter_event.java |  188 -
 .../FilterTests_FilterChain_ActionFilter.java   |  187 -
 ...FilterTests_FilterChain_ApiActionFilter.java |  139 +
 .../FilterTests_FilterChain_ApiEventFilter.java |  135 +
 ...rTests_FilterChain_ApiEventFilter_event.java |  102 +
 ...FilterTests_FilterChain_ApiRenderFilter.java |  101 +
 ...lterTests_FilterChain_ApiResourceFilter.java |  116 +
 .../FilterTests_FilterChain_EventFilter.java    |  144 -
 ...lterTests_FilterChain_EventFilter_event.java |  141 -
 .../FilterTests_FilterChain_RenderFilter.java   |  137 -
 .../FilterTests_FilterChain_ResourceFilter.java |  152 -
 ...ilterTests_FilterConfig_ApiRenderFilter.java |  101 +
 .../FilterTests_FilterConfig_RenderFilter.java  |  153 -
 .../FilterTests_PortletFilter_ActionFilter.java |  169 -
 ...lterTests_PortletFilter_ApiActionFilter.java |  138 +
 ...ilterTests_PortletFilter_ApiEventFilter.java |  134 +
 ...ests_PortletFilter_ApiEventFilter_event.java |  102 +
 ...lterTests_PortletFilter_ApiRenderFilter.java |  101 +
 ...erTests_PortletFilter_ApiResourceFilter.java |  116 +
 .../FilterTests_PortletFilter_EventFilter.java  |  134 -
 ...erTests_PortletFilter_EventFilter_event.java |  133 -
 .../FilterTests_PortletFilter_RenderFilter.java |  129 -
 ...ilterTests_PortletFilter_ResourceFilter.java |  144 -
 ...ilterTests_RenderFilter_ApiRenderFilter.java |  101 +
 .../FilterTests_RenderFilter_RenderFilter.java  |  185 -
 ...rTests_ResourceFilter_ApiResourceFilter.java |  116 +
 ...lterTests_ResourceFilter_ResourceFilter.java |  200 -
 .../resources/xml-resources/additionalTCs.xml   |  136 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |  233 +-
 .../PortletTests_EventPortlet_ApiEvent.java     |  114 +
 ...ortletTests_EventPortlet_ApiEvent_event.java |  117 +
 .../PortletTests_EventPortlet_Event.java        |  114 -
 .../PortletTests_EventPortlet_Event_event.java  |  117 -
 .../portlets/PortletTests_Event_ApiEvent.java   |  162 +
 .../PortletTests_Event_ApiEvent_event.java      |  155 +
 .../tck/portlets/PortletTests_Event_Event.java  |  162 -
 .../PortletTests_Event_Event_event.java         |  155 -
 .../PortletTests_GenericPortlet_ApiRender.java  |  474 ++
 .../PortletTests_GenericPortlet_Render.java     |  474 --
 .../PortletTests_PortletConfig_ApiRender.java   |  235 +
 .../PortletTests_PortletConfig_ApiRender2.java  |  162 +
 .../PortletTests_PortletConfig_Render.java      |  235 -
 .../PortletTests_PortletConfig_Render2.java     |  162 -
 .../PortletTests_PortletMode_ApiRender.java     |  169 +
 .../PortletTests_PortletMode_Render.java        |  169 -
 .../portlets/PortletTests_Portlet_Action.java   |  133 -
 .../PortletTests_Portlet_ApiAction.java         |  133 +
 .../PortletTests_Portlet_ApiRender.java         |  137 +
 .../portlets/PortletTests_Portlet_Render.java   |  137 -
 ...ests_ResourceServingPortlet_ApiResource.java |  128 +
 ...etTests_ResourceServingPortlet_Resource.java |  128 -
 .../PortletTests_WindowState_ApiRender.java     |  169 +
 .../PortletTests_WindowState_Render.java        |  169 -
 .../resources/xml-resources/additionalTCs.xml   |  188 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |  104 +-
 .../RequestTests_ActionRequest_Action.java      |  133 -
 .../RequestTests_ActionRequest_ApiAction.java   |  133 +
 .../RequestTests_ClientDataRequest_Action.java  |  453 --
 ...equestTests_ClientDataRequest_ApiAction.java |  453 ++
 ...uestTests_ClientDataRequest_ApiResource.java |  271 +
 ...RequestTests_ClientDataRequest_Resource.java |  271 -
 .../RequestTests_EventRequest_ApiEvent.java     |  124 +
 ...equestTests_EventRequest_ApiEvent_event.java |  125 +
 .../RequestTests_EventRequest_Event.java        |  124 -
 .../RequestTests_EventRequest_Event_event.java  |  125 -
 .../RequestTests_PortletRequest_Action.java     | 1895 ------
 .../RequestTests_PortletRequest_ApiAction.java  | 1895 ++++++
 .../RequestTests_PortletRequest_ApiEvent.java   | 1092 +++
 ...uestTests_PortletRequest_ApiEvent_event.java |  901 +++
 .../RequestTests_PortletRequest_ApiRender.java  |  896 +++
 ...RequestTests_PortletRequest_ApiResource.java |  912 +++
 .../RequestTests_PortletRequest_Event.java      | 1092 ---
 ...RequestTests_PortletRequest_Event_event.java |  901 ---
 .../RequestTests_PortletRequest_Render.java     |  896 ---
 .../RequestTests_PortletRequest_Resource.java   |  912 ---
 .../RequestTests_RenderRequest_ApiRender.java   |  120 +
 .../RequestTests_RenderRequest_Render.java      |  120 -
 ...equestTests_ResourceRequest_ApiResource.java |  209 +
 .../RequestTests_ResourceRequest_Resource.java  |  209 -
 .../resources/xml-resources/additionalTCs.xml   |  888 +--
 .../src/main/webapp/WEB-INF/portlet.xml         |   92 +-
 .../ResponseTests_ActionResponse_Action.java    |  459 --
 .../ResponseTests_ActionResponse_ApiAction.java |  459 ++
 .../ResponseTests_EventResponse_ApiEvent.java   |  125 +
 ...ponseTests_EventResponse_ApiEvent_event.java |  126 +
 .../ResponseTests_EventResponse_Event.java      |  125 -
 ...ResponseTests_EventResponse_Event_event.java |  126 -
 .../ResponseTests_MimeResponse_ApiRender.java   |  367 +
 .../ResponseTests_MimeResponse_ApiResource.java |  382 ++
 .../ResponseTests_MimeResponse_Render.java      |  367 -
 .../ResponseTests_MimeResponse_Resource.java    |  382 --
 .../ResponseTests_PortletResponse_Action.java   |  483 --
 ...ResponseTests_PortletResponse_ApiAction.java |  483 ++
 .../ResponseTests_PortletResponse_ApiEvent.java |  308 +
 ...nseTests_PortletResponse_ApiEvent_event.java |  273 +
 ...ResponseTests_PortletResponse_ApiRender.java |  269 +
 ...sponseTests_PortletResponse_ApiResource.java |  284 +
 .../ResponseTests_PortletResponse_Event.java    |  308 -
 ...sponseTests_PortletResponse_Event_event.java |  273 -
 .../ResponseTests_PortletResponse_Render.java   |  269 -
 .../ResponseTests_PortletResponse_Resource.java |  284 -
 .../ResponseTests_RenderResponse_ApiRender.java |  139 +
 .../ResponseTests_RenderResponse_Render.java    |  139 -
 ...ponseTests_ResourceResponse_ApiResource.java |  195 +
 ...ResponseTests_ResourceResponse_Resource.java |  195 -
 ...ResponseTests_StateAwareResponse_Action.java | 1089 ---
 ...ponseTests_StateAwareResponse_ApiAction.java | 1089 +++
 ...sponseTests_StateAwareResponse_ApiEvent.java |  643 ++
 ...Tests_StateAwareResponse_ApiEvent_event.java |  544 ++
 .../ResponseTests_StateAwareResponse_Event.java |  643 --
 ...nseTests_StateAwareResponse_Event_event.java |  544 --
 .../resources/xml-resources/additionalTCs.xml   |  566 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |  120 +-
 .../URLTests_BaseURL_ApiRenderActurl.java       |  523 ++
 .../URLTests_BaseURL_ApiRenderRenurl.java       |  523 ++
 .../URLTests_BaseURL_ApiRenderResurl.java       |  523 ++
 .../portlets/URLTests_BaseURL_RenderActurl.java |  523 --
 .../portlets/URLTests_BaseURL_RenderRenurl.java |  523 --
 .../portlets/URLTests_BaseURL_RenderResurl.java |  523 --
 ..._PortletURLGenerationListener_ApiRender.java |  233 +
 ...sts_PortletURLGenerationListener_Render.java |  233 -
 .../URLTests_PortletURL_ApiRenderActurl.java    |  223 +
 .../URLTests_PortletURL_ApiRenderRenurl.java    |  223 +
 .../URLTests_PortletURL_RenderActurl.java       |  223 -
 .../URLTests_PortletURL_RenderRenurl.java       |  223 -
 .../URLTests_ResourceURL_ApiRenderResurl.java   |  185 +
 .../URLTests_ResourceURL_RenderResurl.java      |  185 -
 .../resources/xml-resources/additionalTCs.xml   |  410 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |   60 +-
 ...perTests_ActionRequestWrapper_ApiRender.java |  171 +
 ...rapperTests_ActionRequestWrapper_Render.java |  171 -
 ...erTests_ActionResponseWrapper_ApiRender.java |  229 +
 ...apperTests_ActionResponseWrapper_Render.java |  229 -
 ...pperTests_EventRequestWrapper_ApiRender.java |  142 +
 ...WrapperTests_EventRequestWrapper_Render.java |  142 -
 ...perTests_EventResponseWrapper_ApiRender.java |  222 +
 ...rapperTests_EventResponseWrapper_Render.java |  222 -
 ...erTests_PortletRequestWrapper_ApiRender.java |  391 ++
 ...apperTests_PortletRequestWrapper_Render.java |  391 --
 ...rTests_PortletResponseWrapper_ApiRender.java |  174 +
 ...pperTests_PortletResponseWrapper_Render.java |  174 -
 ...perTests_RenderRequestWrapper_ApiRender.java |  128 +
 ...rapperTests_RenderRequestWrapper_Render.java |  128 -
 ...erTests_RenderResponseWrapper_ApiRender.java |  248 +
 ...apperTests_RenderResponseWrapper_Render.java |  248 -
 ...rTests_ResourceRequestWrapper_ApiRender.java |  200 +
 ...pperTests_ResourceRequestWrapper_Render.java |  200 -
 ...Tests_ResourceResponseWrapper_ApiRender.java |  255 +
 ...perTests_ResourceResponseWrapper_Render.java |  255 -
 .../resources/xml-resources/additionalTCs.xml   |  302 +-
 .../src/main/webapp/WEB-INF/portlet.xml         |   68 +-
 .../tck/beans/JSR286ApiTestCaseDetails.java     | 6340 +++++++++---------
 224 files changed, 34684 insertions(+), 33658 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_Action.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_Action.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_Action.java
deleted file mode 100644
index 4da9702..0000000
--- a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_Action.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-
-package javax.portlet.tck.portlets;
-
-import java.io.*;
-import java.util.*;
-import java.util.logging.*;
-import static java.util.logging.Logger.*;
-import javax.xml.namespace.QName;
-import javax.portlet.*;
-import javax.portlet.filter.*;
-import javax.servlet.*;
-import javax.servlet.http.*;
-import javax.portlet.tck.beans.*;
-import javax.portlet.tck.constants.*;
-import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
-import static javax.portlet.tck.constants.Constants.*;
-import static javax.portlet.PortletSession.*;
-import static javax.portlet.ResourceURL.*;
-
-/**
- * This portlet implements several test cases for the JSR 362 TCK. The test case names
- * are defined in the /src/main/resources/xml-resources/additionalTCs.xml
- * file. The build process will integrate the test case names defined in the 
- * additionalTCs.xml file into the complete list of test case names for execution by the driver.
- *
- * This is the main portlet for the test cases. If the test cases call for events, this portlet
- * will initiate the events, but not process them. The processing is done in the companion 
- * portlet AnnotationTests_ProcessAction_Action_event
- *
- */
-public class AnnotationTests_ProcessAction_Action implements Portlet, ResourceServingPortlet {
-   private static final String LOG_CLASS = 
-         AnnotationTests_ProcessAction_Action.class.getName();
-   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
-   
-   private PortletConfig portletConfig = null;
-
-   @Override
-   public void init(PortletConfig config) throws PortletException {
-      this.portletConfig = config;
-   }
-
-   @Override
-   public void destroy() {
-   }
-
-   @Override
-   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet processAction entry");
-
-      portletResp.setRenderParameters(portletReq.getParameterMap());
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      StringWriter writer = new StringWriter();
-
-      JSR286ApiTestCaseDetails tcd = new JSR286ApiTestCaseDetails();
-
-      // Create result objects for the tests
-
-      /* TestCase: V2AnnotationTests_ProcessAction_Action_name                */
-      /* Details: "Method name(): On an action request, the method is         */
-      /* executed if the parameter \"javax.portlet.action\" matches the       */
-      /* name field"                                                          */
-      TestResult tr0 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_PROCESSACTION_ACTION_NAME);
-      /* TODO: implement test */
-      tr0.appendTcDetail("Not implemented.");
-      tr0.writeTo(writer);
-
-      portletReq.getPortletSession().setAttribute(
-                   Constants.RESULT_ATTR_PREFIX + "AnnotationTests_ProcessAction_Action",
-                   writer.toString(), APPLICATION_SCOPE);
-   }
-
-   @Override
-   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet serveResource entry");
-
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      PrintWriter writer = portletResp.getWriter();
-
-   }
-
-   @Override
-   public void render(RenderRequest portletReq, RenderResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet render entry");
-
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      PrintWriter writer = portletResp.getWriter();
-
-      PortletSession ps = portletReq.getPortletSession();
-      String msg = (String) ps.getAttribute(RESULT_ATTR_PREFIX + "AnnotationTests_ProcessAction_Action", APPLICATION_SCOPE);
-      if (msg != null) {
-         writer.write("<p>" + msg + "</p><br/>\n");
-         ps.removeAttribute(RESULT_ATTR_PREFIX + "AnnotationTests_ProcessAction_Action", APPLICATION_SCOPE);
-      }
-
-      /* TestCase: V2AnnotationTests_ProcessAction_Action_name                */
-      /* Details: "Method name(): On an action request, the method is         */
-      /* executed if the parameter \"javax.portlet.action\" matches the       */
-      /* name field"                                                          */
-      {
-         PortletURL aurl = portletResp.createActionURL();
-         aurl.setParameters(portletReq.getPrivateParameterMap());
-         TestButton tb = new TestButton("V2AnnotationTests_ProcessAction_Action_name", aurl);
-         tb.writeTo(writer);
-      }
-
-   }
-
-}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_ApiAction.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_ApiAction.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_ApiAction.java
new file mode 100644
index 0000000..a172fc8
--- /dev/null
+++ b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessAction_ApiAction.java
@@ -0,0 +1,135 @@
+/*  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+
+package javax.portlet.tck.portlets;
+
+import java.io.*;
+import java.util.*;
+import java.util.logging.*;
+import static java.util.logging.Logger.*;
+import javax.xml.namespace.QName;
+import javax.portlet.*;
+import javax.portlet.filter.*;
+import javax.servlet.*;
+import javax.servlet.http.*;
+import javax.portlet.tck.beans.*;
+import javax.portlet.tck.constants.*;
+import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
+import static javax.portlet.tck.constants.Constants.*;
+import static javax.portlet.PortletSession.*;
+import static javax.portlet.ResourceURL.*;
+
+/**
+ * This portlet implements several test cases for the JSR 362 TCK. The test case names
+ * are defined in the /src/main/resources/xml-resources/additionalTCs.xml
+ * file. The build process will integrate the test case names defined in the 
+ * additionalTCs.xml file into the complete list of test case names for execution by the driver.
+ *
+ * This is the main portlet for the test cases. If the test cases call for events, this portlet
+ * will initiate the events, but not process them. The processing is done in the companion 
+ * portlet AnnotationTests_ProcessAction_ApiAction_event
+ *
+ */
+public class AnnotationTests_ProcessAction_ApiAction implements Portlet, ResourceServingPortlet {
+   private static final String LOG_CLASS = 
+         AnnotationTests_ProcessAction_ApiAction.class.getName();
+   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
+   
+   private PortletConfig portletConfig = null;
+
+   @Override
+   public void init(PortletConfig config) throws PortletException {
+      this.portletConfig = config;
+   }
+
+   @Override
+   public void destroy() {
+   }
+
+   @Override
+   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet processAction entry");
+
+      portletResp.setRenderParameters(portletReq.getParameterMap());
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      StringWriter writer = new StringWriter();
+
+      JSR286ApiTestCaseDetails tcd = new JSR286ApiTestCaseDetails();
+
+      // Create result objects for the tests
+
+      /* TestCase: V2AnnotationTests_ProcessAction_ApiAction_name             */
+      /* Details: "Method name(): On an action request, the method is         */
+      /* executed if the parameter \"javax.portlet.action\" matches the       */
+      /* name field"                                                          */
+      TestResult tr0 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_PROCESSACTION_APIACTION_NAME);
+      /* TODO: implement test */
+      tr0.appendTcDetail("Not implemented.");
+      tr0.writeTo(writer);
+
+      portletReq.getPortletSession().setAttribute(
+                   Constants.RESULT_ATTR_PREFIX + "AnnotationTests_ProcessAction_ApiAction",
+                   writer.toString(), APPLICATION_SCOPE);
+   }
+
+   @Override
+   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet serveResource entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+   }
+
+   @Override
+   public void render(RenderRequest portletReq, RenderResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet render entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+      PortletSession ps = portletReq.getPortletSession();
+      String msg = (String) ps.getAttribute(RESULT_ATTR_PREFIX + "AnnotationTests_ProcessAction_ApiAction", APPLICATION_SCOPE);
+      if (msg != null) {
+         writer.write("<p>" + msg + "</p><br/>\n");
+         ps.removeAttribute(RESULT_ATTR_PREFIX + "AnnotationTests_ProcessAction_ApiAction", APPLICATION_SCOPE);
+      }
+
+      /* TestCase: V2AnnotationTests_ProcessAction_ApiAction_name             */
+      /* Details: "Method name(): On an action request, the method is         */
+      /* executed if the parameter \"javax.portlet.action\" matches the       */
+      /* name field"                                                          */
+      {
+         PortletURL aurl = portletResp.createActionURL();
+         aurl.setParameters(portletReq.getPrivateParameterMap());
+         TestButton tb = new TestButton("V2AnnotationTests_ProcessAction_ApiAction_name", aurl);
+         tb.writeTo(writer);
+      }
+
+   }
+
+}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent.java
new file mode 100644
index 0000000..33fd0ed
--- /dev/null
+++ b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent.java
@@ -0,0 +1,124 @@
+/*  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+
+package javax.portlet.tck.portlets;
+
+import java.io.*;
+import java.util.*;
+import java.util.logging.*;
+import static java.util.logging.Logger.*;
+import javax.xml.namespace.QName;
+import javax.portlet.*;
+import javax.portlet.filter.*;
+import javax.servlet.*;
+import javax.servlet.http.*;
+import javax.portlet.tck.beans.*;
+import javax.portlet.tck.constants.*;
+import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
+import static javax.portlet.tck.constants.Constants.*;
+import static javax.portlet.PortletSession.*;
+import static javax.portlet.ResourceURL.*;
+
+/**
+ * This portlet implements several test cases for the JSR 362 TCK. The test case names
+ * are defined in the /src/main/resources/xml-resources/additionalTCs.xml
+ * file. The build process will integrate the test case names defined in the 
+ * additionalTCs.xml file into the complete list of test case names for execution by the driver.
+ *
+ * This is the main portlet for the test cases. If the test cases call for events, this portlet
+ * will initiate the events, but not process them. The processing is done in the companion 
+ * portlet AnnotationTests_ProcessEvent_ApiEvent_event
+ *
+ */
+public class AnnotationTests_ProcessEvent_ApiEvent implements Portlet, ResourceServingPortlet {
+   private static final String LOG_CLASS = 
+         AnnotationTests_ProcessEvent_ApiEvent.class.getName();
+   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
+   
+   private PortletConfig portletConfig = null;
+
+   @Override
+   public void init(PortletConfig config) throws PortletException {
+      this.portletConfig = config;
+   }
+
+   @Override
+   public void destroy() {
+   }
+
+   @Override
+   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet processAction entry");
+
+      portletResp.setRenderParameters(portletReq.getParameterMap());
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      StringWriter writer = new StringWriter();
+
+      QName eventQName = new QName(TCKNAMESPACE,
+             "AnnotationTests_ProcessEvent_ApiEvent");
+      portletResp.setEvent(eventQName, "Hi!");
+   }
+
+   @Override
+   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet serveResource entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+   }
+
+   @Override
+   public void render(RenderRequest portletReq, RenderResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet render entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+      /* TestCase: V2AnnotationTests_ProcessEvent_ApiEvent_qname              */
+      /* Details: "Method qname(): On an event request, the method is         */
+      /* executed if the Event qname matches the qname field"                 */
+      {
+         PortletURL aurl = portletResp.createActionURL();
+         aurl.setParameters(portletReq.getPrivateParameterMap());
+         TestButton tb = new TestButton("V2AnnotationTests_ProcessEvent_ApiEvent_qname", aurl);
+         tb.writeTo(writer);
+      }
+
+      /* TestCase: V2AnnotationTests_ProcessEvent_ApiEvent_name               */
+      /* Details: "Method name(): On an event request, the method is          */
+      /* executed if the Event name matches the name field"                   */
+      {
+         PortletURL aurl = portletResp.createActionURL();
+         aurl.setParameters(portletReq.getPrivateParameterMap());
+         TestButton tb = new TestButton("V2AnnotationTests_ProcessEvent_ApiEvent_name", aurl);
+         tb.writeTo(writer);
+      }
+
+   }
+
+}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent_event.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent_event.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent_event.java
new file mode 100644
index 0000000..4aeb885
--- /dev/null
+++ b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_ApiEvent_event.java
@@ -0,0 +1,125 @@
+/*  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+
+package javax.portlet.tck.portlets;
+
+import java.io.*;
+import java.util.*;
+import java.util.logging.*;
+import static java.util.logging.Logger.*;
+import javax.xml.namespace.QName;
+import javax.portlet.*;
+import javax.portlet.filter.*;
+import javax.servlet.*;
+import javax.servlet.http.*;
+import javax.portlet.tck.beans.*;
+import javax.portlet.tck.constants.*;
+import static javax.portlet.tck.constants.Constants.*;
+import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
+import static javax.portlet.PortletSession.*;
+
+/**
+ * This is the event processing portlet for the test cases. This portlet processes events, 
+ * but does not publish them. Events are published in the main portlet for the test cases. 
+ */
+public class AnnotationTests_ProcessEvent_ApiEvent_event implements Portlet, EventPortlet, ResourceServingPortlet {
+   private static final String LOG_CLASS = 
+         AnnotationTests_ProcessEvent_ApiEvent_event.class.getName();
+   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
+   
+   private PortletConfig portletConfig = null;
+
+   @Override
+   public void init(PortletConfig config) throws PortletException {
+      this.portletConfig = config;
+   }
+
+   @Override
+   public void destroy() {
+   }
+
+   @Override
+   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "event companion processAction - ERROR!!");
+   }
+
+   @Override
+   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "event companion serveResource - ERROR!!");
+   }
+
+   @Override
+   public void processEvent(EventRequest portletReq, EventResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "event companion processEvent");
+
+
+      portletResp.setRenderParameters(portletReq);
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      StringWriter writer = new StringWriter();
+
+      JSR286ApiTestCaseDetails tcd = new JSR286ApiTestCaseDetails();
+
+      // Create result objects for the tests
+
+      /* TestCase: V2AnnotationTests_ProcessEvent_ApiEvent_qname              */
+      /* Details: "Method qname(): On an event request, the method is         */
+      /* executed if the Event qname matches the qname field"                 */
+      TestResult tr0 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_PROCESSEVENT_APIEVENT_QNAME);
+      /* TODO: implement test */
+      tr0.appendTcDetail("Not implemented.");
+      tr0.writeTo(writer);
+
+      /* TestCase: V2AnnotationTests_ProcessEvent_ApiEvent_name               */
+      /* Details: "Method name(): On an event request, the method is          */
+      /* executed if the Event name matches the name field"                   */
+      TestResult tr1 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_PROCESSEVENT_APIEVENT_NAME);
+      /* TODO: implement test */
+      tr1.appendTcDetail("Not implemented.");
+      tr1.writeTo(writer);
+
+      portletReq.getPortletSession().setAttribute(
+                   Constants.RESULT_ATTR_PREFIX + "AnnotationTests_ProcessEvent_ApiEvent",
+                   writer.toString(), APPLICATION_SCOPE);
+
+   }
+
+   @Override
+   public void render(RenderRequest portletReq, RenderResponse portletResp)
+         throws PortletException, IOException {
+      
+      LOGGER.entering(LOG_CLASS, "event companion render");
+
+      portletResp.setContentType("text/html");
+      PrintWriter writer = portletResp.getWriter();
+      writer.write("<h3>Event Companion Portlet </h3>\n");
+      writer.write("<p>AnnotationTests_ProcessEvent_ApiEvent_event</p>\n");
+
+      String msg = (String) portletReq.getPortletSession()
+            .getAttribute(RESULT_ATTR_PREFIX + "AnnotationTests_ProcessEvent_ApiEvent", APPLICATION_SCOPE);
+      msg = (msg==null) ? "Not ready. click test case link." : msg;
+      writer.write("<p>" + msg + "</p>\n");
+
+   }
+
+}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event.java
deleted file mode 100644
index a153ec6..0000000
--- a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event.java
+++ /dev/null
@@ -1,124 +0,0 @@
-/*  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-
-package javax.portlet.tck.portlets;
-
-import java.io.*;
-import java.util.*;
-import java.util.logging.*;
-import static java.util.logging.Logger.*;
-import javax.xml.namespace.QName;
-import javax.portlet.*;
-import javax.portlet.filter.*;
-import javax.servlet.*;
-import javax.servlet.http.*;
-import javax.portlet.tck.beans.*;
-import javax.portlet.tck.constants.*;
-import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
-import static javax.portlet.tck.constants.Constants.*;
-import static javax.portlet.PortletSession.*;
-import static javax.portlet.ResourceURL.*;
-
-/**
- * This portlet implements several test cases for the JSR 362 TCK. The test case names
- * are defined in the /src/main/resources/xml-resources/additionalTCs.xml
- * file. The build process will integrate the test case names defined in the 
- * additionalTCs.xml file into the complete list of test case names for execution by the driver.
- *
- * This is the main portlet for the test cases. If the test cases call for events, this portlet
- * will initiate the events, but not process them. The processing is done in the companion 
- * portlet AnnotationTests_ProcessEvent_Event_event
- *
- */
-public class AnnotationTests_ProcessEvent_Event implements Portlet, ResourceServingPortlet {
-   private static final String LOG_CLASS = 
-         AnnotationTests_ProcessEvent_Event.class.getName();
-   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
-   
-   private PortletConfig portletConfig = null;
-
-   @Override
-   public void init(PortletConfig config) throws PortletException {
-      this.portletConfig = config;
-   }
-
-   @Override
-   public void destroy() {
-   }
-
-   @Override
-   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet processAction entry");
-
-      portletResp.setRenderParameters(portletReq.getParameterMap());
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      StringWriter writer = new StringWriter();
-
-      QName eventQName = new QName(TCKNAMESPACE,
-             "AnnotationTests_ProcessEvent_Event");
-      portletResp.setEvent(eventQName, "Hi!");
-   }
-
-   @Override
-   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet serveResource entry");
-
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      PrintWriter writer = portletResp.getWriter();
-
-   }
-
-   @Override
-   public void render(RenderRequest portletReq, RenderResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet render entry");
-
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      PrintWriter writer = portletResp.getWriter();
-
-      /* TestCase: V2AnnotationTests_ProcessEvent_Event_qname                 */
-      /* Details: "Method qname(): On an event request, the method is         */
-      /* executed if the Event qname matches the qname field"                 */
-      {
-         PortletURL aurl = portletResp.createActionURL();
-         aurl.setParameters(portletReq.getPrivateParameterMap());
-         TestButton tb = new TestButton("V2AnnotationTests_ProcessEvent_Event_qname", aurl);
-         tb.writeTo(writer);
-      }
-
-      /* TestCase: V2AnnotationTests_ProcessEvent_Event_name                  */
-      /* Details: "Method name(): On an event request, the method is          */
-      /* executed if the Event name matches the name field"                   */
-      {
-         PortletURL aurl = portletResp.createActionURL();
-         aurl.setParameters(portletReq.getPrivateParameterMap());
-         TestButton tb = new TestButton("V2AnnotationTests_ProcessEvent_Event_name", aurl);
-         tb.writeTo(writer);
-      }
-
-   }
-
-}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event_event.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event_event.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event_event.java
deleted file mode 100644
index c3f03ae..0000000
--- a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_ProcessEvent_Event_event.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-
-package javax.portlet.tck.portlets;
-
-import java.io.*;
-import java.util.*;
-import java.util.logging.*;
-import static java.util.logging.Logger.*;
-import javax.xml.namespace.QName;
-import javax.portlet.*;
-import javax.portlet.filter.*;
-import javax.servlet.*;
-import javax.servlet.http.*;
-import javax.portlet.tck.beans.*;
-import javax.portlet.tck.constants.*;
-import static javax.portlet.tck.constants.Constants.*;
-import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
-import static javax.portlet.PortletSession.*;
-
-/**
- * This is the event processing portlet for the test cases. This portlet processes events, 
- * but does not publish them. Events are published in the main portlet for the test cases. 
- */
-public class AnnotationTests_ProcessEvent_Event_event implements Portlet, EventPortlet, ResourceServingPortlet {
-   private static final String LOG_CLASS = 
-         AnnotationTests_ProcessEvent_Event_event.class.getName();
-   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
-   
-   private PortletConfig portletConfig = null;
-
-   @Override
-   public void init(PortletConfig config) throws PortletException {
-      this.portletConfig = config;
-   }
-
-   @Override
-   public void destroy() {
-   }
-
-   @Override
-   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "event companion processAction - ERROR!!");
-   }
-
-   @Override
-   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "event companion serveResource - ERROR!!");
-   }
-
-   @Override
-   public void processEvent(EventRequest portletReq, EventResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "event companion processEvent");
-
-
-      portletResp.setRenderParameters(portletReq);
-
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      StringWriter writer = new StringWriter();
-
-      JSR286ApiTestCaseDetails tcd = new JSR286ApiTestCaseDetails();
-
-      // Create result objects for the tests
-
-      /* TestCase: V2AnnotationTests_ProcessEvent_Event_qname                 */
-      /* Details: "Method qname(): On an event request, the method is         */
-      /* executed if the Event qname matches the qname field"                 */
-      TestResult tr0 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_PROCESSEVENT_EVENT_QNAME);
-      /* TODO: implement test */
-      tr0.appendTcDetail("Not implemented.");
-      tr0.writeTo(writer);
-
-      /* TestCase: V2AnnotationTests_ProcessEvent_Event_name                  */
-      /* Details: "Method name(): On an event request, the method is          */
-      /* executed if the Event name matches the name field"                   */
-      TestResult tr1 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_PROCESSEVENT_EVENT_NAME);
-      /* TODO: implement test */
-      tr1.appendTcDetail("Not implemented.");
-      tr1.writeTo(writer);
-
-      portletReq.getPortletSession().setAttribute(
-                   Constants.RESULT_ATTR_PREFIX + "AnnotationTests_ProcessEvent_Event",
-                   writer.toString(), APPLICATION_SCOPE);
-
-   }
-
-   @Override
-   public void render(RenderRequest portletReq, RenderResponse portletResp)
-         throws PortletException, IOException {
-      
-      LOGGER.entering(LOG_CLASS, "event companion render");
-
-      portletResp.setContentType("text/html");
-      PrintWriter writer = portletResp.getWriter();
-      writer.write("<h3>Event Companion Portlet </h3>\n");
-      writer.write("<p>AnnotationTests_ProcessEvent_Event_event</p>\n");
-
-      String msg = (String) portletReq.getPortletSession()
-            .getAttribute(RESULT_ATTR_PREFIX + "AnnotationTests_ProcessEvent_Event", APPLICATION_SCOPE);
-      msg = (msg==null) ? "Not ready. click test case link." : msg;
-      writer.write("<p>" + msg + "</p>\n");
-
-   }
-
-}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_ApiRender.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_ApiRender.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_ApiRender.java
new file mode 100644
index 0000000..ce94925
--- /dev/null
+++ b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_ApiRender.java
@@ -0,0 +1,113 @@
+/*  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+
+package javax.portlet.tck.portlets;
+
+import java.io.*;
+import java.util.*;
+import java.util.logging.*;
+import static java.util.logging.Logger.*;
+import javax.xml.namespace.QName;
+import javax.portlet.*;
+import javax.portlet.filter.*;
+import javax.servlet.*;
+import javax.servlet.http.*;
+import javax.portlet.tck.beans.*;
+import javax.portlet.tck.constants.*;
+import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
+import static javax.portlet.tck.constants.Constants.*;
+import static javax.portlet.PortletSession.*;
+import static javax.portlet.ResourceURL.*;
+
+/**
+ * This portlet implements several test cases for the JSR 362 TCK. The test case names
+ * are defined in the /src/main/resources/xml-resources/additionalTCs.xml
+ * file. The build process will integrate the test case names defined in the 
+ * additionalTCs.xml file into the complete list of test case names for execution by the driver.
+ *
+ * This is the main portlet for the test cases. If the test cases call for events, this portlet
+ * will initiate the events, but not process them. The processing is done in the companion 
+ * portlet AnnotationTests_RenderMode_ApiRender_event
+ *
+ */
+public class AnnotationTests_RenderMode_ApiRender implements Portlet, ResourceServingPortlet {
+   private static final String LOG_CLASS = 
+         AnnotationTests_RenderMode_ApiRender.class.getName();
+   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
+   
+   private PortletConfig portletConfig = null;
+
+   @Override
+   public void init(PortletConfig config) throws PortletException {
+      this.portletConfig = config;
+   }
+
+   @Override
+   public void destroy() {
+   }
+
+   @Override
+   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet processAction entry");
+
+      portletResp.setRenderParameters(portletReq.getParameterMap());
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      StringWriter writer = new StringWriter();
+
+   }
+
+   @Override
+   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet serveResource entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+   }
+
+   @Override
+   public void render(RenderRequest portletReq, RenderResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet render entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+      JSR286ApiTestCaseDetails tcd = new JSR286ApiTestCaseDetails();
+
+      // Create result objects for the tests
+
+      /* TestCase: V2AnnotationTests_RenderMode_ApiRender_name                */
+      /* Details: "Method name(): On a render request, the method is          */
+      /* executed if the portlet mode matches the name field"                 */
+      TestResult tr0 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_RENDERMODE_APIRENDER_NAME);
+      /* TODO: implement test */
+      tr0.appendTcDetail("Not implemented.");
+      tr0.writeTo(writer);
+
+   }
+
+}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_Render.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_Render.java b/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_Render.java
deleted file mode 100644
index 7375ccf..0000000
--- a/portlet-tck_3.0/V2AnnotationTests/src/main/java/javax/portlet/tck/portlets/AnnotationTests_RenderMode_Render.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*  Licensed to the Apache Software Foundation (ASF) under one
- *  or more contributor license agreements.  See the NOTICE file
- *  distributed with this work for additional information
- *  regarding copyright ownership.  The ASF licenses this file
- *  to you under the Apache License, Version 2.0 (the
- *  "License"); you may not use this file except in compliance
- *  with the License.  You may obtain a copy of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing,
- *  software distributed under the License is distributed on an
- *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- *  KIND, either express or implied.  See the License for the
- *  specific language governing permissions and limitations
- *  under the License.
- */
-
-package javax.portlet.tck.portlets;
-
-import java.io.*;
-import java.util.*;
-import java.util.logging.*;
-import static java.util.logging.Logger.*;
-import javax.xml.namespace.QName;
-import javax.portlet.*;
-import javax.portlet.filter.*;
-import javax.servlet.*;
-import javax.servlet.http.*;
-import javax.portlet.tck.beans.*;
-import javax.portlet.tck.constants.*;
-import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
-import static javax.portlet.tck.constants.Constants.*;
-import static javax.portlet.PortletSession.*;
-import static javax.portlet.ResourceURL.*;
-
-/**
- * This portlet implements several test cases for the JSR 362 TCK. The test case names
- * are defined in the /src/main/resources/xml-resources/additionalTCs.xml
- * file. The build process will integrate the test case names defined in the 
- * additionalTCs.xml file into the complete list of test case names for execution by the driver.
- *
- * This is the main portlet for the test cases. If the test cases call for events, this portlet
- * will initiate the events, but not process them. The processing is done in the companion 
- * portlet AnnotationTests_RenderMode_Render_event
- *
- */
-public class AnnotationTests_RenderMode_Render implements Portlet, ResourceServingPortlet {
-   private static final String LOG_CLASS = 
-         AnnotationTests_RenderMode_Render.class.getName();
-   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
-   
-   private PortletConfig portletConfig = null;
-
-   @Override
-   public void init(PortletConfig config) throws PortletException {
-      this.portletConfig = config;
-   }
-
-   @Override
-   public void destroy() {
-   }
-
-   @Override
-   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet processAction entry");
-
-      portletResp.setRenderParameters(portletReq.getParameterMap());
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      StringWriter writer = new StringWriter();
-
-   }
-
-   @Override
-   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet serveResource entry");
-
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      PrintWriter writer = portletResp.getWriter();
-
-   }
-
-   @Override
-   public void render(RenderRequest portletReq, RenderResponse portletResp)
-         throws PortletException, IOException {
-      LOGGER.entering(LOG_CLASS, "main portlet render entry");
-
-      long tid = Thread.currentThread().getId();
-      portletReq.setAttribute(THREADID_ATTR, tid);
-
-      PrintWriter writer = portletResp.getWriter();
-
-      JSR286ApiTestCaseDetails tcd = new JSR286ApiTestCaseDetails();
-
-      // Create result objects for the tests
-
-      /* TestCase: V2AnnotationTests_RenderMode_Render_name                   */
-      /* Details: "Method name(): On a render request, the method is          */
-      /* executed if the portlet mode matches the name field"                 */
-      TestResult tr0 = tcd.getTestResultFailed(V2ANNOTATIONTESTS_RENDERMODE_RENDER_NAME);
-      /* TODO: implement test */
-      tr0.appendTcDetail("Not implemented.");
-      tr0.writeTo(writer);
-
-   }
-
-}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/resources/xml-resources/additionalTCs.xml
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/resources/xml-resources/additionalTCs.xml b/portlet-tck_3.0/V2AnnotationTests/src/main/resources/xml-resources/additionalTCs.xml
index daa5156..1874fc0 100644
--- a/portlet-tck_3.0/V2AnnotationTests/src/main/resources/xml-resources/additionalTCs.xml
+++ b/portlet-tck_3.0/V2AnnotationTests/src/main/resources/xml-resources/additionalTCs.xml
@@ -20,8 +20,8 @@
 <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
 <properties>
 <!-- JSR 286 API AnnotationTests test case names and page mappings -->
-<entry key="V2AnnotationTests_ProcessAction_Action_name">V2AnnotationTests</entry>
-<entry key="V2AnnotationTests_ProcessEvent_Event_qname">V2AnnotationTests</entry>
-<entry key="V2AnnotationTests_ProcessEvent_Event_name">V2AnnotationTests</entry>
-<entry key="V2AnnotationTests_RenderMode_Render_name">V2AnnotationTests</entry>
+<entry key="V2AnnotationTests_ProcessAction_ApiAction_name">V2AnnotationTests</entry>
+<entry key="V2AnnotationTests_ProcessEvent_ApiEvent_qname">V2AnnotationTests</entry>
+<entry key="V2AnnotationTests_ProcessEvent_ApiEvent_name">V2AnnotationTests</entry>
+<entry key="V2AnnotationTests_RenderMode_ApiRender_name">V2AnnotationTests</entry>
 </properties>

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2AnnotationTests/src/main/webapp/WEB-INF/portlet.xml
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2AnnotationTests/src/main/webapp/WEB-INF/portlet.xml b/portlet-tck_3.0/V2AnnotationTests/src/main/webapp/WEB-INF/portlet.xml
index b5ed6f2..cebfa93 100644
--- a/portlet-tck_3.0/V2AnnotationTests/src/main/webapp/WEB-INF/portlet.xml
+++ b/portlet-tck_3.0/V2AnnotationTests/src/main/webapp/WEB-INF/portlet.xml
@@ -23,105 +23,107 @@
    xmlns:tck="http://www.apache.org/portals/pluto/portlet-tck_3.0"
    version="2.0" id="V2AnnotationTests">
    <portlet>
-      <portlet-name>AnnotationTests_ProcessAction_Action</portlet-name>
-      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_ProcessAction_Action</portlet-class>
+      <portlet-name>AnnotationTests_ProcessAction_ApiAction</portlet-name>
+      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_ProcessAction_ApiAction</portlet-class>
       <expiration-cache>0</expiration-cache>
       <supports>
          <mime-type>text/html</mime-type>
       </supports>
       <supported-locale>en_US</supported-locale>
       <portlet-info>
-         <title>AnnotationTests_ProcessAction_Action</title>
+         <title>AnnotationTests_ProcessAction_ApiAction</title>
       </portlet-info>
    </portlet>
 
    <portlet>
-      <portlet-name>AnnotationTests_ProcessEvent_Event</portlet-name>
-      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_ProcessEvent_Event</portlet-class>
+      <portlet-name>AnnotationTests_ProcessEvent_ApiEvent</portlet-name>
+      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_ProcessEvent_ApiEvent</portlet-class>
       <expiration-cache>0</expiration-cache>
       <supports>
          <mime-type>text/html</mime-type>
       </supports>
       <supported-locale>en_US</supported-locale>
       <portlet-info>
-         <title>AnnotationTests_ProcessEvent_Event</title>
+         <title>AnnotationTests_ProcessEvent_ApiEvent</title>
       </portlet-info>
       <supported-publishing-event>
-         <qname>tck:AnnotationTests_ProcessEvent_Event</qname>
+         <qname>tck:AnnotationTests_ProcessEvent_ApiEvent</qname>
       </supported-publishing-event>
    </portlet>
 
    <portlet>
-      <portlet-name>AnnotationTests_ProcessEvent_Event_event</portlet-name>
-      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_ProcessEvent_Event_event</portlet-class>
+      <portlet-name>AnnotationTests_ProcessEvent_ApiEvent_event</portlet-name>
+      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_ProcessEvent_ApiEvent_event</portlet-class>
       <expiration-cache>0</expiration-cache>
       <supports>
          <mime-type>text/html</mime-type>
       </supports>
       <supported-locale>en_US</supported-locale>
       <portlet-info>
-         <title>AnnotationTests_ProcessEvent_Event_event</title>
+         <title>AnnotationTests_ProcessEvent_ApiEvent_event</title>
       </portlet-info>
       <supported-processing-event>
-         <qname>tck:AnnotationTests_ProcessEvent_Event</qname>
+         <qname>tck:AnnotationTests_ProcessEvent_ApiEvent</qname>
       </supported-processing-event>
    </portlet>
 
    <portlet>
-      <portlet-name>AnnotationTests_RenderMode_Render</portlet-name>
-      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_RenderMode_Render</portlet-class>
+      <portlet-name>AnnotationTests_RenderMode_ApiRender</portlet-name>
+      <portlet-class>javax.portlet.tck.portlets.AnnotationTests_RenderMode_ApiRender</portlet-class>
       <expiration-cache>0</expiration-cache>
       <supports>
          <mime-type>text/html</mime-type>
       </supports>
       <supported-locale>en_US</supported-locale>
       <portlet-info>
-         <title>AnnotationTests_RenderMode_Render</title>
+         <title>AnnotationTests_RenderMode_ApiRender</title>
       </portlet-info>
    </portlet>
 
+
+
    <event-definition>
-      <qname>tck:FilterTests_FilterChain_EventFilter</qname>
+      <qname>tck:FilterTests_FilterChain_ApiEventFilter</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:FilterTests_PortletFilter_EventFilter</qname>
+      <qname>tck:FilterTests_PortletFilter_ApiEventFilter</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:FilterTests_EventFilter_EventFilter</qname>
+      <qname>tck:FilterTests_EventFilter_ApiEventFilter</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:RequestTests_PortletRequest_Event</qname>
+      <qname>tck:RequestTests_PortletRequest_ApiEvent</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:RequestTests_EventRequest_Event</qname>
+      <qname>tck:RequestTests_EventRequest_ApiEvent</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:ResponseTests_PortletResponse_Event</qname>
+      <qname>tck:ResponseTests_PortletResponse_ApiEvent</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:ResponseTests_StateAwareResponse_Event</qname>
+      <qname>tck:ResponseTests_StateAwareResponse_ApiEvent</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:ResponseTests_EventResponse_Event</qname>
+      <qname>tck:ResponseTests_EventResponse_ApiEvent</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 
    <event-definition>
-      <qname>tck:AnnotationTests_ProcessEvent_Event</qname>
+      <qname>tck:AnnotationTests_ProcessEvent_ApiEvent</qname>
       <value-type>java.lang.String</value-type>
    </event-definition>
 

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/db1071e7/portlet-tck_3.0/V2EnvironmentTests/src/main/java/javax/portlet/tck/portlets/EnvironmentTests_CacheControl_ApiRender.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V2EnvironmentTests/src/main/java/javax/portlet/tck/portlets/EnvironmentTests_CacheControl_ApiRender.java b/portlet-tck_3.0/V2EnvironmentTests/src/main/java/javax/portlet/tck/portlets/EnvironmentTests_CacheControl_ApiRender.java
new file mode 100644
index 0000000..0e13766
--- /dev/null
+++ b/portlet-tck_3.0/V2EnvironmentTests/src/main/java/javax/portlet/tck/portlets/EnvironmentTests_CacheControl_ApiRender.java
@@ -0,0 +1,288 @@
+/*  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License.
+ */
+
+package javax.portlet.tck.portlets;
+
+import java.io.*;
+import java.util.*;
+import java.util.logging.*;
+import static java.util.logging.Logger.*;
+import javax.xml.namespace.QName;
+import javax.portlet.*;
+import javax.portlet.filter.*;
+import javax.servlet.*;
+import javax.servlet.http.*;
+import javax.portlet.tck.beans.*;
+import javax.portlet.tck.constants.*;
+import static javax.portlet.tck.beans.JSR286ApiTestCaseDetails.*;
+import static javax.portlet.tck.constants.Constants.*;
+import static javax.portlet.PortletSession.*;
+import static javax.portlet.ResourceURL.*;
+
+/**
+ * This portlet implements several test cases for the JSR 362 TCK. The test case names
+ * are defined in the /src/main/resources/xml-resources/additionalTCs.xml
+ * file. The build process will integrate the test case names defined in the 
+ * additionalTCs.xml file into the complete list of test case names for execution by the driver.
+ *
+ * This is the main portlet for the test cases. If the test cases call for events, this portlet
+ * will initiate the events, but not process them. The processing is done in the companion 
+ * portlet EnvironmentTests_CacheControl_ApiRender_event
+ *
+ */
+public class EnvironmentTests_CacheControl_ApiRender implements Portlet, ResourceServingPortlet {
+   private static final String LOG_CLASS = 
+         EnvironmentTests_CacheControl_ApiRender.class.getName();
+   private final Logger LOGGER = Logger.getLogger(LOG_CLASS);
+   
+   private PortletConfig portletConfig = null;
+
+   @Override
+   public void init(PortletConfig config) throws PortletException {
+      this.portletConfig = config;
+   }
+
+   @Override
+   public void destroy() {
+   }
+
+   @Override
+   public void processAction(ActionRequest portletReq, ActionResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet processAction entry");
+
+      portletResp.setRenderParameters(portletReq.getParameterMap());
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      StringWriter writer = new StringWriter();
+
+   }
+
+   @Override
+   public void serveResource(ResourceRequest portletReq, ResourceResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet serveResource entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+   }
+
+   @Override
+   public void render(RenderRequest portletReq, RenderResponse portletResp)
+         throws PortletException, IOException {
+      LOGGER.entering(LOG_CLASS, "main portlet render entry");
+
+      long tid = Thread.currentThread().getId();
+      portletReq.setAttribute(THREADID_ATTR, tid);
+
+      PrintWriter writer = portletResp.getWriter();
+
+      JSR286ApiTestCaseDetails tcd = new JSR286ApiTestCaseDetails();
+
+      // Create result objects for the tests
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_getExpirationTime1 */
+      /* Details: "Method getExpirationTime(): Returns the expiration time    */
+      /* set through setExpirationTime"                                       */
+      TestResult tr0 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_GETEXPIRATIONTIME1);
+      /* TODO: implement test */
+      tr0.appendTcDetail("Not implemented.");
+      tr0.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_getExpirationTime2 */
+      /* Details: "Method getExpirationTime(): Returns the default            */
+      /* expiration time from the deployment descriptor if the expiration     */
+      /* time has not been set"                                               */
+      TestResult tr1 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_GETEXPIRATIONTIME2);
+      /* TODO: implement test */
+      tr1.appendTcDetail("Not implemented.");
+      tr1.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_getExpirationTime3 */
+      /* Details: "Method getExpirationTime(): Returns 0 if the expiration    */
+      /* time has not been set and no default is set in the deployment        */
+      /* descriptor"                                                          */
+      TestResult tr2 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_GETEXPIRATIONTIME3);
+      /* TODO: implement test */
+      tr2.appendTcDetail("Not implemented.");
+      tr2.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setExpirationTime1 */
+      /* Details: "Method setExpirationTime(int): Sets the expiration time    */
+      /* for the current response to the specified value"                     */
+      TestResult tr3 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETEXPIRATIONTIME1);
+      /* TODO: implement test */
+      tr3.appendTcDetail("Not implemented.");
+      tr3.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setExpirationTime2 */
+      /* Details: "Method setExpirationTime(int): If the expiration value     */
+      /* is set to 0, caching is disabled"                                    */
+      TestResult tr4 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETEXPIRATIONTIME2);
+      /* TODO: implement test */
+      tr4.appendTcDetail("Not implemented.");
+      tr4.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setExpirationTime3 */
+      /* Details: "Method setExpirationTime(int): If the expiration value     */
+      /* is set to -1, the cache does not expire"                             */
+      TestResult tr5 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETEXPIRATIONTIME3);
+      /* TODO: implement test */
+      tr5.appendTcDetail("Not implemented.");
+      tr5.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_isPublicScope1   */
+      /* Details: "Method isPublicScope(): Returns true if the caching        */
+      /* scope has been set to public through the setPublicScope method"      */
+      TestResult tr6 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_ISPUBLICSCOPE1);
+      /* TODO: implement test */
+      tr6.appendTcDetail("Not implemented.");
+      tr6.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_isPublicScope2   */
+      /* Details: "Method isPublicScope(): Returns true if the caching        */
+      /* scope default has not been set with the setPublicScope method, but   */
+      /* has been set to public in the deployment descriptor "                */
+      TestResult tr7 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_ISPUBLICSCOPE2);
+      /* TODO: implement test */
+      tr7.appendTcDetail("Not implemented.");
+      tr7.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_isPublicScope3   */
+      /* Details: "Method isPublicScope(): Returns false if the caching       */
+      /* scope has not been set with the setPublicScope method, but has       */
+      /* been set to private through the setPublicScope method "              */
+      TestResult tr8 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_ISPUBLICSCOPE3);
+      /* TODO: implement test */
+      tr8.appendTcDetail("Not implemented.");
+      tr8.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_isPublicScope5   */
+      /* Details: "Method isPublicScope(): Returns false if the caching       */
+      /* scope has not been set with the setPublicScope method and has not    */
+      /* been set in the deployment descriptor"                               */
+      TestResult tr9 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_ISPUBLICSCOPE5);
+      /* TODO: implement test */
+      tr9.appendTcDetail("Not implemented.");
+      tr9.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setPublicScope1  */
+      /* Details: "Method setPublicScope(boolean): If the input parameter     */
+      /* is true, the cache scope is set to public"                           */
+      TestResult tr10 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETPUBLICSCOPE1);
+      /* TODO: implement test */
+      tr10.appendTcDetail("Not implemented.");
+      tr10.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setPublicScope2  */
+      /* Details: "Method setPublicScope(boolean): If the input parameter     */
+      /* is false, the cache scope is set to non-public"                      */
+      TestResult tr11 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETPUBLICSCOPE2);
+      /* TODO: implement test */
+      tr11.appendTcDetail("Not implemented.");
+      tr11.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_getETag1         */
+      /* Details: "Method getETag(): Returns a String containing the ETag     */
+      /* for the current response"                                            */
+      TestResult tr12 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_GETETAG1);
+      /* TODO: implement test */
+      tr12.appendTcDetail("Not implemented.");
+      tr12.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_getETag2         */
+      /* Details: "Method getETag(): Returns null if no ETag is set on the    */
+      /* response"                                                            */
+      TestResult tr13 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_GETETAG2);
+      /* TODO: implement test */
+      tr13.appendTcDetail("Not implemented.");
+      tr13.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setETag1         */
+      /* Details: "Method setETag(String): Sets an ETag for the current       */
+      /* response"                                                            */
+      TestResult tr14 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETETAG1);
+      /* TODO: implement test */
+      tr14.appendTcDetail("Not implemented.");
+      tr14.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setETag2         */
+      /* Details: "Method setETag(String): A previously-set ETag is           */
+      /* overwritten"                                                         */
+      TestResult tr15 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETETAG2);
+      /* TODO: implement test */
+      tr15.appendTcDetail("Not implemented.");
+      tr15.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setETag3         */
+      /* Details: "Method setETag(String): Removes the ETag if the input      */
+      /* parameter is null"                                                   */
+      TestResult tr16 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETETAG3);
+      /* TODO: implement test */
+      tr16.appendTcDetail("Not implemented.");
+      tr16.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_useCachedContent1 */
+      /* Details: "Method useCachedContent(): Returns true if cached          */
+      /* content has been set to valid through the setUseCachedContent        */
+      /* method"                                                              */
+      TestResult tr17 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_USECACHEDCONTENT1);
+      /* TODO: implement test */
+      tr17.appendTcDetail("Not implemented.");
+      tr17.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_useCachedContent2 */
+      /* Details: "Method useCachedContent(): Returns false if cached         */
+      /* content has been set to invalid through the setUseCachedContent      */
+      /* method"                                                              */
+      TestResult tr18 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_USECACHEDCONTENT2);
+      /* TODO: implement test */
+      tr18.appendTcDetail("Not implemented.");
+      tr18.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_useCachedContent3 */
+      /* Details: "Method useCachedContent(): Returns false if the use        */
+      /* cached content indcator has not been set"                            */
+      TestResult tr19 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_USECACHEDCONTENT3);
+      /* TODO: implement test */
+      tr19.appendTcDetail("Not implemented.");
+      tr19.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setUseCachedContent1 */
+      /* Details: "Method setUseCachedContent(boolean): If set to true, the   */
+      /* cached content is valid "                                            */
+      TestResult tr20 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETUSECACHEDCONTENT1);
+      /* TODO: implement test */
+      tr20.appendTcDetail("Not implemented.");
+      tr20.writeTo(writer);
+
+      /* TestCase: V2EnvironmentTests_CacheControl_ApiRender_setUseCachedContent2 */
+      /* Details: "Method setUseCachedContent(boolean): If set to false,      */
+      /* the cached content is invalid "                                      */
+      TestResult tr21 = tcd.getTestResultFailed(V2ENVIRONMENTTESTS_CACHECONTROL_APIRENDER_SETUSECACHEDCONTENT2);
+      /* TODO: implement test */
+      tr21.appendTcDetail("Not implemented.");
+      tr21.writeTo(writer);
+
+   }
+
+}