portals-pluto-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From asfgr...@apache.org
Subject portals-pluto git commit: PLUTO-665 TCK: V3ResourceParametersTests copy+paste error leaves tests unimplemented
Date Wed, 08 Nov 2017 22:02:43 GMT
Repository: portals-pluto
Updated Branches:
  refs/heads/master 0efe7097e -> 202a28205


PLUTO-665 TCK: V3ResourceParametersTests copy+paste error leaves tests unimplemented


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

Branch: refs/heads/master
Commit: 202a28205cc7e8c93772745a549614009ce0085c
Parents: 0efe709
Author: Neil Griffin <neil.griffin.scm@gmail.com>
Authored: Wed Nov 8 17:02:05 2017 -0500
Committer: Neil Griffin <neil.griffin.scm@gmail.com>
Committed: Wed Nov 8 17:02:05 2017 -0500

----------------------------------------------------------------------
 .../PortletParametersTests_SPEC11_1.java        |   2 +
 .../PortletParametersTests_SPEC11_3.java        |   6 +-
 .../PortletParametersTests_SPEC11_4.java        |  91 +--
 .../PortletParametersTests_SPEC11_4A.java       | 579 +++++++++++++++++++
 .../portlet/tck/util/ModuleTestCaseDetails.java |  25 +
 .../resources/xml-resources/additionalPages.xml |   5 +-
 .../resources/xml-resources/additionalTCs.xml   |  12 +
 7 files changed, 680 insertions(+), 40 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/202a2820/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_1.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_1.java b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_1.java
index 2e29e50..0fa5aaf 100644
--- a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_1.java
+++ b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_1.java
@@ -54,6 +54,8 @@ import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTE
 
 @PortletApplication(
         publicParams = {
+                @PublicRenderParameterDefinition(identifier = "myPRP1", qname = @PortletQName(localPart = "myPRP1", namespaceURI = "")),
+                @PublicRenderParameterDefinition(identifier = "myPRP2", qname = @PortletQName(localPart = "myPRP2", namespaceURI = "")),
                 @PublicRenderParameterDefinition(identifier = "names_public1", qname = @PortletQName(localPart = "names_public1", namespaceURI = ""))
         })
 @PortletConfiguration(portletName = "PortletParametersTests_SPEC11_1", publicParams = {"names_public1"})

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/202a2820/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_3.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_3.java b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_3.java
index b63cb46..8f4ffe9 100644
--- a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_3.java
+++ b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_3.java
@@ -218,7 +218,7 @@ public class PortletParametersTests_SPEC11_3 implements Portlet {
                 result.setTcSuccess(false);
             }
             else {
-                result.appendTcDetail("Found correct count of Render parameters.");
+                result.appendTcDetail("Found correct count of Action parameters.");
             }
             PortletSession session = portletReq.getPortletSession();
             session.setAttribute(SPEC_11_3_SIZE_STATUS, result.isTcSuccess());
@@ -282,8 +282,8 @@ public class PortletParametersTests_SPEC11_3 implements Portlet {
         ModuleTestCaseDetails tcd = new ModuleTestCaseDetails();
 
         {
-            RenderParameters actionParams = portletReq.getRenderParameters();
-            if (actionParams.isEmpty()) {
+            RenderParameters renderParams = portletReq.getRenderParameters();
+            if (renderParams.isEmpty()) {
                 ActionURL actionURL = portletResp.createActionURL();
                 MutableActionParameters mutableActionParameters = actionURL.getActionParameters();
                 // Setup Private Tests

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/202a2820/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4.java b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4.java
index 5d2c314..77ba253 100644
--- a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4.java
+++ b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4.java
@@ -18,11 +18,9 @@
 
 package javax.portlet.tck.portlets;
 
-import javax.portlet.ActionParameters;
 import javax.portlet.ActionRequest;
 import javax.portlet.ActionResponse;
-import javax.portlet.ActionURL;
-import javax.portlet.MutableActionParameters;
+import javax.portlet.MutableResourceParameters;
 import javax.portlet.Portlet;
 import javax.portlet.PortletConfig;
 import javax.portlet.PortletException;
@@ -30,9 +28,13 @@ import javax.portlet.PortletSession;
 import javax.portlet.RenderParameters;
 import javax.portlet.RenderRequest;
 import javax.portlet.RenderResponse;
+import javax.portlet.ResourceParameters;
+import javax.portlet.ResourceRequest;
+import javax.portlet.ResourceResponse;
+import javax.portlet.ResourceServingPortlet;
+import javax.portlet.ResourceURL;
 import javax.portlet.annotations.PortletConfiguration;
 import javax.portlet.tck.beans.TestResult;
-import javax.portlet.tck.beans.TestSetupLink;
 import javax.portlet.tck.util.ModuleTestCaseDetails;
 import java.io.IOException;
 import java.io.PrintWriter;
@@ -52,7 +54,7 @@ import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTE
  */
 
 @PortletConfiguration(portletName = "PortletParametersTests_SPEC11_4", publicParams = {"names_public1"})
-public class PortletParametersTests_SPEC11_4 implements Portlet {
+public class PortletParametersTests_SPEC11_4 implements Portlet, ResourceServingPortlet {
 
     private PortletConfig portletConfig = null;
 
@@ -77,14 +79,18 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
     }
 
     @Override
-    public void processAction(ActionRequest portletReq, ActionResponse portletResp) throws PortletException, IOException {
+    public void processAction(ActionRequest request, ActionResponse response) throws PortletException, IOException {
+    }
+
+    @Override
+    public void serveResource(ResourceRequest resourceRequest, ResourceResponse resourceResponse) throws PortletException, IOException {
         ModuleTestCaseDetails tcd = new ModuleTestCaseDetails();
 
         /* TestCase: V3PortletParametersTests_SPEC11_4_getNames                        */
         /* Details: "Returns a set of strings representing the resource parameter names */
         {
             TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4_GETNAMES);
-            ActionParameters resourceParameters = portletReq.getActionParameters();
+            ResourceParameters resourceParameters = resourceRequest.getResourceParameters();
             if (!resourceParameters.isEmpty()) {
                 boolean valid = true;
                 if (!resourceParameters.getNames().contains("names_private1")) {
@@ -108,10 +114,10 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
                     valid = false;
                 }
                 if (valid) {
-                    result.appendTcDetail("successfully set and read ACTION parameter names");
+                    result.appendTcDetail("successfully set and read RESOURCE parameter names");
                     result.setTcSuccess(true);
                 }
-                PortletSession session = portletReq.getPortletSession();
+                PortletSession session = resourceRequest.getPortletSession();
                 session.setAttribute(SPEC_11_4_GETNAMES_STATUS, result.isTcSuccess());
                 session.setAttribute(SPEC_11_4_GETNAMES_MESSAGE, result.getTcDetail());
             }
@@ -121,7 +127,7 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
         /* Details: "Returns a resource parameter value as a string for a given name    */
         {
             TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4_GETVALUE);
-            ActionParameters resourceParameters = portletReq.getActionParameters();
+            ResourceParameters resourceParameters = resourceRequest.getResourceParameters();
             if (!resourceParameters.isEmpty()) {
                 boolean valid = true;
                 String trPrivate = resourceParameters.getValue("names_private1");
@@ -158,7 +164,7 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
                     result.appendTcDetail("successfully getValue on resource parameters");
                     result.setTcSuccess(true);
                 }
-                PortletSession session = portletReq.getPortletSession();
+                PortletSession session = resourceRequest.getPortletSession();
                 session.setAttribute(SPEC_11_4_GETVALUE_STATUS, result.isTcSuccess());
                 session.setAttribute(SPEC_11_4_GETVALUE_MESSAGE, result.getTcDetail());
             }
@@ -168,7 +174,7 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
         /* Details: "Returns all resource parameter values as a string array for a name */
         {
             TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4_GETVALUES);
-            ActionParameters resourceParams = portletReq.getActionParameters();
+            ResourceParameters resourceParams = resourceRequest.getResourceParameters();
             if (!resourceParams.isEmpty()) {
                 boolean valid = true;
                 String[] values = resourceParams.getValues("names_private1");
@@ -201,7 +207,7 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
                     result.appendTcDetail("successfully getValues on resource parameters");
                     result.setTcSuccess(true);
                 }
-                PortletSession session = portletReq.getPortletSession();
+                PortletSession session = resourceRequest.getPortletSession();
                 session.setAttribute(SPEC_11_4_GETVALUES_STATUS, result.isTcSuccess());
                 session.setAttribute(SPEC_11_4_GETVALUES_MESSAGE, result.getTcDetail());
             }
@@ -211,16 +217,16 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
         /* Details: "Returns the number of resource parameters available"              */
         {
             TestResult result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4_SIZE);
-            ActionParameters resourceParams = portletReq.getActionParameters();
+            ResourceParameters resourceParams = resourceRequest.getResourceParameters();
             int expectedCount = (resourceParams.isEmpty()) ? 0 : 7;
             if (expectedCount != resourceParams.size()) {
-                result.appendTcDetail("Failed to get correct Action Parameters count, expected: " + expectedCount + ", found: " + resourceParams.size());
+                result.appendTcDetail("Failed to get correct Resource Parameters count, expected: " + expectedCount + ", found: " + resourceParams.size());
                 result.setTcSuccess(false);
             }
             else {
                 result.appendTcDetail("Found correct count of Render parameters.");
             }
-            PortletSession session = portletReq.getPortletSession();
+            PortletSession session = resourceRequest.getPortletSession();
             session.setAttribute(SPEC_11_4_SIZE_STATUS, result.isTcSuccess());
             session.setAttribute(SPEC_11_4_SIZE_MESSAGE, result.getTcDetail());
         }
@@ -229,8 +235,8 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
         /* Details: "Clones the given resource parameters returning a mutable copy of  */
         /* the parameters"                                                            */
         {
-            ActionParameters resourceParams = portletReq.getActionParameters();
-            MutableActionParameters mrp = resourceParams.clone();
+            ResourceParameters resourceParams = resourceRequest.getResourceParameters();
+            MutableResourceParameters mrp = resourceParams.clone();
             TestResult result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4_CLONE);
             // check that original and clone have same parameters
             if (resourceParams.size() == mrp.size()) {
@@ -266,9 +272,9 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
                 }
             }
             if (result.isTcSuccess()) {
-                result.setTcDetail("Clone on Action parameters successful");
+                result.setTcDetail("Clone on Resource parameters successful");
             }
-            PortletSession session = portletReq.getPortletSession();
+            PortletSession session = resourceRequest.getPortletSession();
             session.setAttribute(SPEC_11_4_CLONE_STATUS, result.isTcSuccess());
             session.setAttribute(SPEC_11_4_CLONE_MESSAGE, result.getTcDetail());
         }
@@ -284,27 +290,40 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
         {
             RenderParameters resourceParams = portletReq.getRenderParameters();
             if (resourceParams.isEmpty()) {
-                ActionURL resourceURL = portletResp.createActionURL();
-                MutableActionParameters mutableActionParameters = resourceURL.getActionParameters();
+                ResourceURL resourceURL = portletResp.createResourceURL();
+                MutableResourceParameters mutableResourceParameters = resourceURL.getResourceParameters();
                 // Setup Private Tests
-                mutableActionParameters.setValue("names_private1", "one");
-                mutableActionParameters.setValue("names_private2", "two");
-                mutableActionParameters.setValues("names_multi", "a", "b", "c");
+                mutableResourceParameters.setValue("names_private1", "one");
+                mutableResourceParameters.setValue("names_private2", "two");
+                mutableResourceParameters.setValues("names_multi", "a", "b", "c");
                 // Setup Public Test
-                mutableActionParameters.setValue("names_public1", "three");
-                mutableActionParameters.setValue("names_nullok1", null);
-                mutableActionParameters.setValues("names_nullsok2", null, "notnull", null);
+                mutableResourceParameters.setValue("names_public1", "three");
+                mutableResourceParameters.setValue("names_nullok1", null);
+                mutableResourceParameters.setValues("names_nullsok2", null, "notnull", null);
                 // Setup Encoding Test
-                mutableActionParameters.setValue("names_encode1", "url&enco ded");
-                TestSetupLink tb = new TestSetupLink(
-                        V3PORTLETPARAMETERSTESTS_SPEC11_4_GETNAMES,
-                        resourceURL);
-                tb.writeTo(writer);
+                mutableResourceParameters.setValue("names_encode1", "url&enco ded");
+
+                writer.write(
+                    "<div id=\"PortletParametersTests_SPEC11_4_Resource\">no resource output.</div>\n");
+                writer.write("<script>\n");
+                writer.write("(function () {\n");
+                writer.write("   var xhr = new XMLHttpRequest();\n");
+                writer.write("   xhr.onreadystatechange=function() {\n");
+                writer.write("      if (xhr.readyState==4 && xhr.status==200) {\n");
+                writer.write(
+                    "         document.getElementById(\"PortletParametersTests_SPEC11_4_Resource\").innerHTML=xhr.responseText;\n");
+                writer.write("      }\n");
+                writer.write("   };\n");
+                writer.write(
+                    "   xhr.open(\"GET\",\"" + resourceURL.toString() + "\",true);\n");
+                writer.write("   xhr.send();\n");
+                writer.write("})();\n");
+                writer.write("</script>\n");
 
                 // Setup NULL Tests
                 boolean exceptionCaught = false;
                 try {
-                    mutableActionParameters.setValue(null, "bad");
+                    mutableResourceParameters.setValue(null, "bad");
                 } catch (RuntimeException e) {
                     exceptionCaught = true;
                 }
@@ -315,7 +334,7 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
             }
         }
 
-        /* TestCase: V3ActionParametersTests_SPEC11_4_getNames                        */
+        /* TestCase: V3ResourceParametersTests_SPEC11_4_getNames                        */
         /* Details: "Returns a set of strings representing the portlet parameter names */
         {
             TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4_GETNAMES);
@@ -396,7 +415,7 @@ public class PortletParametersTests_SPEC11_4 implements Portlet {
             }
             else {
                 result.setTcSuccess(true);
-                result.setTcDetail("Action Clone test is setup and ready to run");
+                result.setTcDetail("Resource Clone test is setup and ready to run");
                 result.writeTo(writer);
             }
         }

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/202a2820/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4A.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4A.java b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4A.java
new file mode 100644
index 0000000..031dac0
--- /dev/null
+++ b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/portlets/PortletParametersTests_SPEC11_4A.java
@@ -0,0 +1,579 @@
+/*  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 javax.portlet.ActionParameters;
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.ActionURL;
+import javax.portlet.HeaderPortlet;
+import javax.portlet.HeaderRequest;
+import javax.portlet.HeaderResponse;
+import javax.portlet.MutableActionParameters;
+import javax.portlet.MutableRenderParameters;
+import javax.portlet.MutableResourceParameters;
+import javax.portlet.Portlet;
+import javax.portlet.PortletConfig;
+import javax.portlet.PortletException;
+import javax.portlet.PortletRequest;
+import javax.portlet.PortletSession;
+import javax.portlet.RenderParameters;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.ResourceParameters;
+import javax.portlet.ResourceRequest;
+import javax.portlet.ResourceResponse;
+import javax.portlet.ResourceServingPortlet;
+import javax.portlet.ResourceURL;
+import javax.portlet.annotations.PortletConfiguration;
+import javax.portlet.tck.beans.TestCaseDetails;
+import javax.portlet.tck.beans.TestResult;
+import javax.portlet.tck.beans.TestSetupButton;
+import javax.portlet.tck.beans.TestSetupLink;
+import javax.portlet.tck.util.ModuleTestCaseDetails;
+import java.io.IOException;
+import java.io.PrintWriter;
+import java.util.Set;
+
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETNAMES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETVALUES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_SIZE;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETNAMES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_SIZE;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETVALUES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETNAMES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_SIZE;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETVALUES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETNAMES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETVALUES;
+import static javax.portlet.tck.util.ModuleTestCaseDetails.V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_SIZE;
+
+/**
+ * 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.
+ */
+
+@PortletConfiguration(portletName = "PortletParametersTests_SPEC11_4A", publicParams = {"myPRP1", "myPRP2"})
+public class PortletParametersTests_SPEC11_4A implements Portlet,
+    HeaderPortlet, ResourceServingPortlet {
+
+    private PortletConfig portletConfig = null;
+
+    private final static String SPEC_11_4A_ACTION_PHASE_GETNAMES_STATUS = "SPEC_11_4A_ACTION_PHASE_GETNAMES_STATUS";
+    private final static String SPEC_11_4A_ACTION_PHASE_GETNAMES_MESSAGE = "SPEC_11_4A_ACTION_PHASE_GETNAMES_MESSAGE";
+    private final static String SPEC_11_4A_ACTION_PHASE_GETVALUES_STATUS = "SPEC_11_4A_ACTION_PHASE_GETVALUES_STATUS";
+    private final static String SPEC_11_4A_ACTION_PHASE_GETVALUES_MESSAGE = "SPEC_11_4A_ACTION_PHASE_GETVALUES_MESSAGE";
+    private final static String SPEC_11_4A_ACTION_PHASE_SIZE_STATUS = "SPEC_11_4A_ACTION_PHASE_SIZE_STATUS";
+    private final static String SPEC_11_4A_ACTION_PHASE_SIZE_MESSAGE = "SPEC_11_4A_ACTION_PHASE_SIZE_MESSAGE";
+    private final static String SPEC_11_4A_HEADER_PHASE_GETNAMES_STATUS = "SPEC_11_4A_HEADER_PHASE_GETNAMES_STATUS";
+    private final static String SPEC_11_4A_HEADER_PHASE_GETNAMES_MESSAGE = "SPEC_11_4A_HEADER_PHASE_GETNAMES_MESSAGE";
+    private final static String SPEC_11_4A_HEADER_PHASE_GETVALUES_STATUS = "SPEC_11_4A_HEADER_PHASE_GETVALUES_STATUS";
+    private final static String SPEC_11_4A_HEADER_PHASE_GETVALUES_MESSAGE = "SPEC_11_4A_HEADER_PHASE_GETVALUES_MESSAGE";
+    private final static String SPEC_11_4A_HEADER_PHASE_SIZE_STATUS = "SPEC_11_4A_HEADER_PHASE_SIZE_STATUS";
+    private final static String SPEC_11_4A_HEADER_PHASE_SIZE_MESSAGE = "SPEC_11_4A_HEADER_PHASE_SIZE_MESSAGE";
+
+    @Override
+    public void init(PortletConfig config) throws PortletException {
+        this.portletConfig = config;
+    }
+
+    @Override
+    public void destroy() {
+    }
+
+    @Override
+    public void processAction(ActionRequest actionRequest, ActionResponse actionResponse) throws PortletException, IOException {
+        ModuleTestCaseDetails tcd = new ModuleTestCaseDetails();
+
+        /* TestCase: V3PortletParametersTests_SPEC11_4A_actionPhaseGetNames */
+        /* Details: "Returns one set of strings containing the action parameter names and another containing the render parameter names */
+        {
+            TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETNAMES);
+            ActionParameters actionParameters = actionRequest.getActionParameters();
+            RenderParameters renderParameters = actionRequest.getRenderParameters();
+            if (!actionParameters.isEmpty()) {
+                boolean valid = true;
+                Set<String> actionParameterNames = actionParameters.getNames();
+                if (!actionParameterNames.contains("myActionParam1")) {
+                    result.appendTcDetail("action parameter myActionParam1 not found");
+                    valid = false;
+                }
+                if (!actionParameterNames.contains("myPRP1")) {
+                    result.appendTcDetail("action parameter myPRP1 (same name as public render parameter) not found");
+                    valid = false;
+                }
+                Set<String> renderParameterNames = renderParameters.getNames();
+                if (!renderParameterNames.contains("myRenderParam1") || renderParameters.isPublic("myRenderParam1")) {
+                    result.appendTcDetail("private render parameter myRenderParam1 not found");
+                    valid = false;
+                }
+                if (!renderParameterNames.contains("myPRP1") || !renderParameters.isPublic("myPRP1")) {
+                    result.appendTcDetail("public render parameter myPRP1 not found");
+                    valid = false;
+                }
+                if (!renderParameterNames.contains("myPRP2") || !renderParameters.isPublic("myPRP2")) {
+                    result.appendTcDetail("public render parameter myPRP2 not found");
+                    valid = false;
+                }
+                if (valid) {
+                    result.appendTcDetail("successfully set and read ACTION and RENDER parameter names");
+                    result.setTcSuccess(true);
+                }
+                PortletSession session = actionRequest.getPortletSession();
+                session.setAttribute(SPEC_11_4A_ACTION_PHASE_GETNAMES_STATUS, result.isTcSuccess());
+                session.setAttribute(SPEC_11_4A_ACTION_PHASE_GETNAMES_MESSAGE, result.getTcDetail());
+            }
+        }
+
+        /* TestCase: V3PortletParametersTests_SPEC11_4A_actionPhaseGetValues */
+        /* Details: "Returns one string array of action parameter values for a given name, and another with render parameter values for a different name */
+        {
+            TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETVALUES);
+            ActionParameters actionParameters = actionRequest.getActionParameters();
+            RenderParameters renderParameters = actionRequest.getRenderParameters();
+            if (!actionParameters.isEmpty() && !renderParameters.isEmpty()) {
+                boolean valid = true;
+                String[] trPrivate = actionParameters.getValues("myActionParam1");
+                if (trPrivate == null || (trPrivate.length != 3) || !trPrivate[0].equals("a") || !trPrivate[1].equals("b") || !trPrivate[2].equals("c")) {
+                    result.appendTcDetail("failed to get action parameter values for myActionParam1");
+                    valid = false;
+                }
+                trPrivate = actionRequest.getParameterValues("myPRP1");
+                if (trPrivate == null || (trPrivate.length != 4) || !trPrivate[0].equals("actionParamValue") || !trPrivate[1].equals("x") || !trPrivate[2].equals("y") || !trPrivate[3].equals("z")) {
+                    result.appendTcDetail("failed to get combined PRP+ACTION parameter values for myPRP1");
+                    valid = false;
+                }
+                String[] myRenderParam1 = renderParameters.getValues("myRenderParam1");
+                if (myRenderParam1 == null || (myRenderParam1.length != 1) || renderParameters.isPublic("myRenderParam1") || !myRenderParam1[0].equals("abc")) {
+                    result.appendTcDetail("failed to get public render parameter value for myRenderParam1");
+                    valid = false;
+                }
+                String[] myPRP1 = renderParameters.getValues("myPRP1");
+                if (myPRP1 == null || (myPRP1.length != 3) || !renderParameters.isPublic("myPRP1") || !myPRP1[0].equals("x") || !myPRP1[1].equals("y") || !myPRP1[2].equals("z")) {
+                    result.appendTcDetail("failed to get public render parameter value for myPRP1");
+                    valid = false;
+                }
+                String[] myPRP2 = renderParameters.getValues("myPRP2");
+                if (myPRP2 == null || (myPRP2.length != 1) || !renderParameters.isPublic("myPRP2") || !myPRP2[0].equals("xyz")) {
+                    result.appendTcDetail("failed to get public render parameter value for myPRP2");
+                    valid = false;
+                }
+                if (valid) {
+                    result.appendTcDetail("successfully getValues on action and render parameters");
+                    result.setTcSuccess(true);
+                }
+                PortletSession session = actionRequest.getPortletSession();
+                session.setAttribute(SPEC_11_4A_ACTION_PHASE_GETVALUES_STATUS, result.isTcSuccess());
+                session.setAttribute(SPEC_11_4A_ACTION_PHASE_GETVALUES_MESSAGE, result.getTcDetail());
+            }
+        }
+
+        /* TestCase: V3PortletParametersTests_SPEC11_4A_actionPhaseSize */
+        /* Details: "Returns the number of action and render parameters available" */
+        {
+            TestResult result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_SIZE);
+            ActionParameters actionParams = actionRequest.getActionParameters();
+            RenderParameters renderParams = actionRequest.getRenderParameters();
+            int expectedActionCount = 3; // myActionParam1, inputval, and myPRP1
+            int expectedRenderCount = 3; // myRenderParm1, myPRP1, and myPRP2
+            if (expectedActionCount != actionParams.size()) {
+                result.appendTcDetail("Failed to get correct Action Parameters count, expected: " + expectedActionCount + ", found: " + actionParams.size());
+                result.setTcSuccess(false);
+            }
+            else if (expectedRenderCount != renderParams.size()) {
+                result.appendTcDetail("Failed to get correct Render Parameters count, expected: " + expectedRenderCount + ", found: " + renderParams.size());
+                result.setTcSuccess(false);
+            }
+            else {
+                result.appendTcDetail("Found correct count of Action and Render parameters.");
+            }
+            PortletSession session = actionRequest.getPortletSession();
+            session.setAttribute(SPEC_11_4A_ACTION_PHASE_SIZE_STATUS, result.isTcSuccess());
+            session.setAttribute(SPEC_11_4A_ACTION_PHASE_SIZE_MESSAGE, result.getTcDetail());
+        }
+
+        MutableRenderParameters mutableRenderParameters = actionResponse.getRenderParameters();
+        mutableRenderParameters.setValue("myPRP2", "valueFromActionPhase");
+    }
+
+    @Override
+    public void renderHeaders(
+        HeaderRequest headerRequest, HeaderResponse headerResponse)
+        throws PortletException, IOException {
+        {
+            RenderParameters renderParameters =
+                headerRequest.getRenderParameters();
+            if (!renderParameters.isEmpty()) {
+                TestCaseDetails tcd = new ModuleTestCaseDetails();
+                executeHeaderRenderTests(tcd, headerRequest, PortletRequest.HEADER_PHASE, renderParameters, null);
+            }
+        }
+    }
+
+    @Override
+    public void render(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException, IOException {
+
+        PrintWriter writer = renderResponse.getWriter();
+
+        {
+            RenderParameters renderParameters = renderRequest.getRenderParameters();
+            if (renderParameters.isEmpty()) {
+                ActionURL actionURL = renderResponse.createActionURL();
+                MutableActionParameters mutableActionParameters = actionURL.getActionParameters();
+                // Setup Action Parameter Tests
+                mutableActionParameters.setValues("myActionParam1", "a", "b", "c");
+                mutableActionParameters.setValues("myPRP1", "actionParamValue");
+                // Setup Public Render Parameter Test
+                MutableRenderParameters mutableRenderParameters = actionURL.getRenderParameters();
+                mutableRenderParameters.setValues("myRenderParam1", "abc");
+                mutableRenderParameters.setValues("myPRP1", "x", "y", "z");
+                mutableRenderParameters.setValues("myPRP2", "xyz");
+                TestSetupButton tb = new TestSetupButton(
+                    V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETNAMES,
+                    actionURL);
+                tb.writeTo(writer);
+            }
+            else {
+
+                // Setup ResourceURL, XHR, and DOM replacement for the RESOURCE_PHASE
+                writer.write(
+                    "<div id=\"PortletParametersTests_SPEC11_4A_ResourcePhase\">no resource output.</div>\n");
+                ResourceURL resourceURL = renderResponse.createResourceURL();
+                MutableResourceParameters mutableResourceParameters =
+                    resourceURL.getResourceParameters();
+                mutableResourceParameters.setValues("myResourceParam1", "1", "2", "3");
+                mutableResourceParameters.setValues("myPRP2", "valueFromResourcePhase");
+                writer.write("<script>\n");
+                writer.write("(function () {\n");
+                writer.write("   var xhr = new XMLHttpRequest();\n");
+                writer.write("   xhr.onreadystatechange=function() {\n");
+                writer.write("      if (xhr.readyState==4 && xhr.status==200) {\n");
+                writer.write(
+                    "         document.getElementById(\"PortletParametersTests_SPEC11_4A_ResourcePhase\").innerHTML=xhr.responseText;\n");
+                writer.write("      }\n");
+                writer.write("   };\n");
+                writer.write(
+                    "   xhr.open(\"GET\",\"" + resourceURL.toString() + "\",true);\n");
+                writer.write("   xhr.send();\n");
+                writer.write("})();\n");
+                writer.write("</script>\n");
+
+                TestCaseDetails tcd = new ModuleTestCaseDetails();
+
+                writer.write("<hr />");
+
+                /* TestCase: V3PortletParametersTests_SPEC11_4A_headerPhaseGetNames         */
+                /* Details: "Returns a set of strings containing the render parameter names */
+                tcd.getTestResultFailed(
+                    V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETNAMES);
+                TestResult result;
+                result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETNAMES);
+                PortletSession session = renderRequest.getPortletSession();
+                Boolean success = (Boolean) session.getAttribute(SPEC_11_4A_HEADER_PHASE_GETNAMES_STATUS);
+                String message = (String) session.getAttribute(SPEC_11_4A_HEADER_PHASE_GETNAMES_MESSAGE);
+                result.setTcSuccess(success);
+                result.setTcDetail(message);
+                result.writeTo(writer);
+                session.removeAttribute(SPEC_11_4A_HEADER_PHASE_GETNAMES_STATUS);
+                session.removeAttribute(SPEC_11_4A_HEADER_PHASE_GETNAMES_MESSAGE);
+
+                /* TestCase: V3PortletParametersTests_SPEC11_4A_headerPhaseGetValues            */
+                /* Details: "Returns a string array of render parameter values for a given name */
+                result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETVALUES);
+                session = renderRequest.getPortletSession();
+                success = (Boolean) session.getAttribute(SPEC_11_4A_HEADER_PHASE_GETVALUES_STATUS);
+                message = (String) session.getAttribute(SPEC_11_4A_HEADER_PHASE_GETVALUES_MESSAGE);
+                result.setTcSuccess(success);
+                result.setTcDetail(message);
+                result.writeTo(writer);
+                session.removeAttribute(SPEC_11_4A_HEADER_PHASE_GETVALUES_STATUS);
+                session.removeAttribute(SPEC_11_4A_HEADER_PHASE_GETVALUES_MESSAGE);
+
+                /* TestCase: V3PortletParametersTests_SPEC11_4A_headerPhaseSize            */
+                /* Details: "Returns the number of action and render parameters available" */
+                result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_SIZE);
+                session = renderRequest.getPortletSession();
+                success = (Boolean) session.getAttribute(SPEC_11_4A_HEADER_PHASE_SIZE_STATUS);
+                message = (String) session.getAttribute(SPEC_11_4A_HEADER_PHASE_SIZE_MESSAGE);
+                result.setTcSuccess(success);
+                result.setTcDetail(message);
+                result.writeTo(writer);
+                session.removeAttribute(SPEC_11_4A_HEADER_PHASE_SIZE_STATUS);
+                session.removeAttribute(SPEC_11_4A_HEADER_PHASE_SIZE_MESSAGE);
+
+                executeHeaderRenderTests(tcd, renderRequest, PortletRequest.RENDER_PHASE, renderParameters, writer);
+
+                /* TestCase: V3PortletParametersTests_SPEC11_4A_actionPhaseGetNames            */
+                /* Details: "Returns a set of strings representing the portlet parameter names */
+                tcd.getTestResultFailed(
+                    V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETNAMES);
+                writer.write("<hr />");
+                result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETNAMES);
+                session = renderRequest.getPortletSession();
+                success = (Boolean) session.getAttribute(SPEC_11_4A_ACTION_PHASE_GETNAMES_STATUS);
+                message = (String) session.getAttribute(SPEC_11_4A_ACTION_PHASE_GETNAMES_MESSAGE);
+                result.setTcSuccess(success);
+                result.setTcDetail(message);
+                result.writeTo(writer);
+                session.removeAttribute(SPEC_11_4A_ACTION_PHASE_GETNAMES_STATUS);
+                session.removeAttribute(SPEC_11_4A_ACTION_PHASE_GETNAMES_MESSAGE);
+
+                /* TestCase: V3PortletParametersTests_SPEC11_4A_actionPhaseGetValues          */
+                /* Details: "Returns all action parameter values as a string array for a name */
+                result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETVALUES);
+                session = renderRequest.getPortletSession();
+                success = (Boolean) session.getAttribute(SPEC_11_4A_ACTION_PHASE_GETVALUES_STATUS);
+                message = (String) session.getAttribute(SPEC_11_4A_ACTION_PHASE_GETVALUES_MESSAGE);
+                result.setTcSuccess(success);
+                result.setTcDetail(message);
+                result.writeTo(writer);
+                session.removeAttribute(SPEC_11_4A_ACTION_PHASE_GETVALUES_STATUS);
+                session.removeAttribute(SPEC_11_4A_ACTION_PHASE_GETVALUES_MESSAGE);
+
+                /* TestCase: V3PortletParametersTests_SPEC11_4A_actionPhaseSize            */
+                /* Details: "Returns the number of action and render parameters available" */
+                result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_SIZE);
+                session = renderRequest.getPortletSession();
+                success = (Boolean) session.getAttribute(SPEC_11_4A_ACTION_PHASE_SIZE_STATUS);
+                message = (String) session.getAttribute(SPEC_11_4A_ACTION_PHASE_SIZE_MESSAGE);
+                result.setTcSuccess(success);
+                result.setTcDetail(message);
+                result.writeTo(writer);
+                session.removeAttribute(SPEC_11_4A_ACTION_PHASE_SIZE_STATUS);
+                session.removeAttribute(SPEC_11_4A_ACTION_PHASE_SIZE_MESSAGE);
+            }
+        }
+    }
+
+    private void executeHeaderRenderTests(TestCaseDetails tcd, RenderRequest renderRequest, String lifecyclePhase,
+                                          RenderParameters renderParameters, PrintWriter writer)
+        throws IOException {
+
+        boolean headerPhase = PortletRequest.HEADER_PHASE.equals(lifecyclePhase);
+
+        if (writer != null) {
+            writer.write("<hr />");
+        }
+
+        Set<String> renderParameterNames = renderParameters.getNames();
+        TestResult result;
+        if (headerPhase) {
+            /* TestCase: V3PortletParametersTests_SPEC11_4A_headerPhaseGetNames */
+            /* Details: "Returns a set of strings containing the render parameter names */
+            result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETNAMES);
+        }
+        else {
+            /* TestCase: V3PortletParametersTests_SPEC11_4A_renderPhaseGetNames */
+            /* Details: "Returns a set of strings containing the render parameter names */
+            result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETNAMES);
+        }
+        if (!renderParameterNames.contains("myRenderParam1") || renderParameters.isPublic("myRenderParam1")) {
+            result.appendTcDetail("private render parameter myRenderParam1 not found");
+            result.setTcSuccess(false);
+        }
+        else if (!renderParameterNames.contains("myPRP1") || !renderParameters.isPublic("myPRP1")) {
+            result.appendTcDetail("public render parameter myPRP1 not found");
+            result.setTcSuccess(false);
+        }
+        else if (!renderParameterNames.contains("myPRP2") || !renderParameters.isPublic("myPRP2")) {
+            result.appendTcDetail("public render parameter myPRP2 not found");
+            result.setTcSuccess(false);
+        }
+        else {
+            result.appendTcDetail("successfully read RENDER parameter names");
+        }
+        if (headerPhase) {
+            PortletSession session = renderRequest.getPortletSession();
+            session.setAttribute(SPEC_11_4A_HEADER_PHASE_GETNAMES_STATUS, result.isTcSuccess());
+            session.setAttribute(SPEC_11_4A_HEADER_PHASE_GETNAMES_MESSAGE, result.getTcDetail());
+        }
+        else {
+            result.writeTo(writer);
+        }
+
+        if (headerPhase) {
+            /* TestCase: V3PortletParametersTests_SPEC11_4A_headerPhaseGetValues */
+            /* Details: "Returns a string array of render parameter values for a given name */
+            result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETVALUES);
+        }
+        else {
+            /* TestCase: V3PortletParametersTests_SPEC11_4A_renderPhaseGetValues */
+            /* Details: "Returns a string array of render parameter values for a given name */
+            result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETVALUES);
+        }
+        String[] myRenderParam1 = renderParameters.getValues("myRenderParam1");
+        String[] myPRP1 = renderParameters.getValues("myPRP1");
+        String[] myPRP2 = renderParameters.getValues("myPRP2");
+        if ((myRenderParam1 == null) || (myRenderParam1.length != 1) || renderParameters.isPublic("myRenderParam1") || !myRenderParam1[0].equals("abc")) {
+            result.appendTcDetail("failed to get public render parameter value for myRenderParam1");
+            result.setTcSuccess(false);
+        }
+        else if (myPRP1 == null || (myPRP1.length != 3) || !renderParameters.isPublic("myPRP1") || !myPRP1[0].equals("x") || !myPRP1[1].equals("y") || !myPRP1[2].equals("z")) {
+            result.appendTcDetail("failed to get public render parameter value for myPRP1");
+            result.setTcSuccess(false);
+        }
+        else if ((myPRP2 == null) || (myPRP2.length != 1) || !renderParameters.isPublic("myPRP2") || !myPRP2[0].equals("valueFromActionPhase")) {
+            result.appendTcDetail("failed to get public render parameter value for myPRP2");
+            result.setTcSuccess(false);
+        }
+        else {
+            result.appendTcDetail("successfully getValues on render parameters");
+        }
+        if (headerPhase) {
+            PortletSession session = renderRequest.getPortletSession();
+            session.setAttribute(SPEC_11_4A_HEADER_PHASE_GETVALUES_STATUS, result.isTcSuccess());
+            session.setAttribute(SPEC_11_4A_HEADER_PHASE_GETVALUES_MESSAGE, result.getTcDetail());
+        }
+        else {
+            result.writeTo(writer);
+        }
+
+        if (headerPhase) {
+            /* TestCase: V3PortletParametersTests_SPEC11_4A_headerPhaseSize */
+            /* Details: "Returns the number of action and render parameters available" */
+            result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_SIZE);
+        }
+        else {
+            /* TestCase: V3PortletParametersTests_SPEC11_4A_renderPhaseSize */
+            /* Details: "Returns the number of action and render parameters available" */
+            result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_SIZE);
+        }
+        int expectedCount = 3; // myRenderParam1, myPRP1, and myPRP2
+        if (expectedCount != renderParameters.size()) {
+            result.appendTcDetail("Failed to get correct Render Parameters count, expected: " + expectedCount + ", found: " + renderParameters.size());
+            result.setTcSuccess(false);
+        }
+        else {
+            result.appendTcDetail("Found correct count of Render parameters.");
+        }
+        if (headerPhase) {
+            PortletSession session = renderRequest.getPortletSession();
+            session.setAttribute(SPEC_11_4A_HEADER_PHASE_SIZE_STATUS, result.isTcSuccess());
+            session.setAttribute(SPEC_11_4A_HEADER_PHASE_SIZE_MESSAGE, result.getTcDetail());
+        }
+        else {
+            result.writeTo(writer);
+        }
+    }
+
+    @Override
+    public void serveResource(
+        ResourceRequest resourceRequest, ResourceResponse resourceResponse)
+        throws PortletException, IOException {
+
+        PrintWriter writer = resourceResponse.getWriter();
+        ModuleTestCaseDetails tcd = new ModuleTestCaseDetails();
+
+        /* TestCase: V3PortletParametersTests_SPEC11_4A_resourcePhaseGetNames */
+        /* Details: "Returns one set of strings containing the resource parameter names and another containing the render parameter names */
+        {
+            TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETNAMES);
+            ResourceParameters resourceParameters = resourceRequest.getResourceParameters();
+            RenderParameters renderParameters = resourceRequest.getRenderParameters();
+            if (!resourceParameters.isEmpty()) {
+                boolean valid = true;
+                Set<String> resourceParameterNames = resourceParameters.getNames();
+                if (!resourceParameterNames.contains("myResourceParam1")) {
+                    result.appendTcDetail("resource parameter myResourceParam1 not found");
+                    valid = false;
+                }
+                Set<String> renderParameterNames = renderParameters.getNames();
+                if (!renderParameterNames.contains("myPRP1") || !renderParameters.isPublic("myPRP1")) {
+                    result.appendTcDetail("public render parameter myPRP1 not found");
+                    valid = false;
+                }
+                if (valid) {
+                    result.appendTcDetail("successfully set and read RESOURCE and RENDER parameter names");
+                    result.setTcSuccess(true);
+                }
+            }
+            result.writeTo(writer);
+        }
+
+        /* TestCase: V3PortletParametersTests_SPEC11_4A_resourcePhaseGetValues */
+        /* Details: "Returns one string array of resource parameter values for a given name, and another with render parameter values for a different name */
+        {
+            TestResult result = tcd.getTestResultFailed(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETVALUES);
+            ResourceParameters resourceParameters = resourceRequest.getResourceParameters();
+            RenderParameters renderParameters = resourceRequest.getRenderParameters();
+            if (!resourceParameters.isEmpty() && !renderParameters.isEmpty()) {
+                boolean valid = true;
+                String[] trPrivate = resourceParameters.getValues("myResourceParam1");
+                if (trPrivate == null || (trPrivate.length != 3) || !trPrivate[0].equals("1") || !trPrivate[1].equals("2") || !trPrivate[2].equals("3")) {
+                    result.appendTcDetail("failed to get resource parameter values for myResourceParam1");
+                    valid = false;
+                }
+                String[] myPRP2 = resourceParameters.getValues("myPRP2");
+                if (myPRP2 == null || (myPRP2.length != 1) || !myPRP2[0].equals("valueFromResourcePhase")) {
+                    result.appendTcDetail("failed to get RESOURCE parameter value for myPRP2");
+                    valid = false;
+                }
+                myPRP2 = resourceRequest.getParameterValues("myPRP2");
+                if (myPRP2 == null || (myPRP2.length != 2) || !myPRP2[0].equals("valueFromResourcePhase") || !myPRP2[1].equals("valueFromActionPhase")) {
+                    result.appendTcDetail("failed to get combined PRP+RESOURCE parameter values for myPRP2");
+                    valid = false;
+                }
+                String[] myRenderParam1 = renderParameters.getValues("myRenderParam1");
+                if (myRenderParam1 == null || (myRenderParam1.length != 1) || renderParameters.isPublic("myRenderParam1") || !myRenderParam1[0].equals("abc")) {
+                    result.appendTcDetail("failed to get public render parameter value for myRenderParam1");
+                    valid = false;
+                }
+                String[] myPRP1 = renderParameters.getValues("myPRP1");
+                if (myPRP1 == null || (myPRP1.length != 3) || !renderParameters.isPublic("myPRP1") || !myPRP1[0].equals("x") || !myPRP1[1].equals("y") || !myPRP1[2].equals("z")) {
+                    result.appendTcDetail("failed to get public render parameter value for myPRP1");
+                    valid = false;
+                }
+                myPRP2 = renderParameters.getValues("myPRP2");
+                if (myPRP2 == null || (myPRP2.length != 1) || !renderParameters.isPublic("myPRP2") || !myPRP2[0].equals("valueFromActionPhase")) {
+                    result.appendTcDetail("failed to get public render parameter value for myPRP2");
+                    valid = false;
+                }
+                if (valid) {
+                    result.appendTcDetail("successfully getValues on resource and render parameters");
+                    result.setTcSuccess(true);
+                }
+            }
+            result.writeTo(writer);
+        }
+
+        /* TestCase: V3PortletParametersTests_SPEC11_4A_resourcePhaseSize */
+        /* Details: "Returns the number of resource and render parameters available" */
+        {
+            TestResult result = tcd.getTestResultSucceeded(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_SIZE);
+            ResourceParameters resourceParams = resourceRequest.getResourceParameters();
+            RenderParameters renderParams = resourceRequest.getRenderParameters();
+            int expectedResourceCount = 2; // myResourceParam1, and myPRP2=valueFromResourcePhase
+            int expectedRenderCount = 3; // myRenderParam1, myPRP1, and myPRP2=valueFromActionPhase
+            if (expectedResourceCount != resourceParams.size()) {
+                result.appendTcDetail("Failed to get correct Resource Parameters count, expected: " + expectedResourceCount + ", found: " + resourceParams.size());
+                result.setTcSuccess(false);
+            }
+            else if (expectedRenderCount != renderParams.size()) {
+                result.appendTcDetail("Failed to get correct Render Parameters count, expected: " + expectedRenderCount + ", found: " + renderParams.size());
+                result.setTcSuccess(false);
+            }
+            else {
+                result.appendTcDetail("Found correct count of Resource and Render parameters.");
+            }
+            result.writeTo(writer);
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/202a2820/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/util/ModuleTestCaseDetails.java
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/util/ModuleTestCaseDetails.java b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/util/ModuleTestCaseDetails.java
index 32e220b..5a2b9b5 100644
--- a/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/util/ModuleTestCaseDetails.java
+++ b/portlet-tck_3.0/V3PortletParametersTests/src/main/java/javax/portlet/tck/util/ModuleTestCaseDetails.java
@@ -52,6 +52,19 @@ public class ModuleTestCaseDetails extends TestCaseDetails {
     public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4_SIZE = "V3PortletParametersTests_SPEC11_4_size";
     public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4_CLONE = "V3PortletParametersTests_SPEC11_4_clone";
 
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETNAMES = "V3PortletParametersTests_SPEC11_4A_actionPhaseGetNames";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETVALUES = "V3PortletParametersTests_SPEC11_4A_actionPhaseGetValues";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_SIZE = "V3PortletParametersTests_SPEC11_4A_actionPhaseSize";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETNAMES = "V3PortletParametersTests_SPEC11_4A_headerPhaseGetNames";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETVALUES = "V3PortletParametersTests_SPEC11_4A_headerPhaseGetValues";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_SIZE = "V3PortletParametersTests_SPEC11_4A_headerPhaseSize";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETNAMES = "V3PortletParametersTests_SPEC11_4A_renderPhaseGetNames";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETVALUES = "V3PortletParametersTests_SPEC11_4A_renderPhaseGetValues";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_SIZE = "V3PortletParametersTests_SPEC11_4A_renderPhaseSize";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETNAMES = "V3PortletParametersTests_SPEC11_4A_resourcePhaseGetNames";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETVALUES = "V3PortletParametersTests_SPEC11_4A_resourcePhaseGetValues";
+    public final static String V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_SIZE = "V3PortletParametersTests_SPEC11_4A_resourcePhaseSize";
+
     private final static Map<String, String> tcd = new HashMap<String, String>();
 
     static {
@@ -74,6 +87,18 @@ public class ModuleTestCaseDetails extends TestCaseDetails {
         tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4_SIZE, "Returns the number of resource parameters available");
         tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4_CLONE, "Clones the given resource parameters returning a mutable copy of the parameters");
 
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETNAMES, "Returns one set of strings containing the action parameter names and another containing the render parameter names");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_GETVALUES, "Returns one string array of action parameter values for a given name, and another with render parameter values for a different name");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_ACTION_PHASE_SIZE, "Returns the number of action and render parameters available");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETNAMES, "Returns a set of strings containing the render parameter names");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_GETVALUES, "Returns a string array of render parameter values for a given name");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_HEADER_PHASE_SIZE, "Returns the number of action and render parameters available");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETNAMES, "Returns a set of strings containing the render parameter names");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_GETVALUES, "Returns a string array of render parameter values for a given name");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RENDER_PHASE_SIZE, "Returns the number of action and render parameters available");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETNAMES, "Returns one set of strings containing the resource parameter names and another containing the render parameter names");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_GETVALUES, "Returns one string array of resource parameter values for a given name, and another with render parameter values for a different name");
+        tcd.put(V3PORTLETPARAMETERSTESTS_SPEC11_4A_RESOURCE_PHASE_SIZE, "Returns the number of resource and render parameters available");
     }
 
     /**

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/202a2820/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalPages.xml
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalPages.xml b/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalPages.xml
index 3ce09f5..37b400f 100644
--- a/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalPages.xml
+++ b/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalPages.xml
@@ -32,7 +32,7 @@
 </supports>
 <render-config default="About Apache Pluto">
 <page xmlns="" name="V3PortletParametersTests" uri="/WEB-INF/themes/pluto-default-theme.jsp">
-<portlet context="/${project.artifactId}-${project.version}" name="PortletParametersTests_SPEC11_1"/>
+    <portlet context="/${project.artifactId}-${project.version}" name="PortletParametersTests_SPEC11_1"/>
 </page>
 <page xmlns="" name="V3ActionParametersTests" uri="/WEB-INF/themes/pluto-default-theme.jsp">
     <portlet context="/${project.artifactId}-${project.version}" name="PortletParametersTests_SPEC11_3"/>
@@ -40,5 +40,8 @@
 <page xmlns="" name="V3ResourceParametersTests" uri="/WEB-INF/themes/pluto-default-theme.jsp">
     <portlet context="/${project.artifactId}-${project.version}" name="PortletParametersTests_SPEC11_4"/>
 </page>
+<page xmlns="" name="V3ResourceParametersAddlTests" uri="/WEB-INF/themes/pluto-default-theme.jsp">
+    <portlet context="/${project.artifactId}-${project.version}" name="PortletParametersTests_SPEC11_4A"/>
+</page>
 </render-config>
 </pluto-portal-driver>

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/202a2820/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalTCs.xml
----------------------------------------------------------------------
diff --git a/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalTCs.xml b/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalTCs.xml
index 7280b6c..8005f77 100644
--- a/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalTCs.xml
+++ b/portlet-tck_3.0/V3PortletParametersTests/src/main/resources/xml-resources/additionalTCs.xml
@@ -35,4 +35,16 @@
 <entry key="V3PortletParametersTests_SPEC11_4_getValues">V3ResourceParametersTests</entry>
 <entry key="V3PortletParametersTests_SPEC11_4_size">V3ResourceParametersTests</entry>
 <entry key="V3PortletParametersTests_SPEC11_4_clone">V3ResourceParametersTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_actionPhaseGetNames">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_actionPhaseGetValues">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_actionPhaseSize">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_headerPhaseGetNames">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_headerPhaseGetValues">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_headerPhaseSize">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_renderPhaseGetNames">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_renderPhaseGetValues">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_renderPhaseSize">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_resourcePhaseGetNames">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_resourcePhaseGetValues">V3ResourceParametersAddlTests</entry>
+<entry key="V3PortletParametersTests_SPEC11_4A_resourcePhaseSize">V3ResourceParametersAddlTests</entry>
 </properties>


Mime
View raw message