Set the name when instantiating a MockRequestParameter
When using the MockSlingHttpServletRequest#setParameterMap then calling SlingHttpServletRequest#getRequestParameterList the name in each of the RequestParameter values is null...
diff --git a/src/main/java/org/apache/sling/servlethelpers/MockRequestParameter.java b/src/main/java/org/apache/sling/servlethelpers/MockRequestParameter.java
index 2c77e3b..2951e6a 100644
--- a/src/main/java/org/apache/sling/servlethelpers/MockRequestParameter.java
+++ b/src/main/java/org/apache/sling/servlethelpers/MockRequestParameter.java
@@ -36,6 +36,7 @@
private byte[] content;
public MockRequestParameter(String name, String value) {
+ this.name = name;
this.value = value;
this.content = null;
}