incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bdelacre...@apache.org
Subject svn commit: r1396663 - in /sling/trunk/launchpad: builder/src/main/bundles/ integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/issues/ integration-tests/src/main/resources/integration-test/issues/sling2617/
Date Wed, 10 Oct 2012 16:10:09 GMT
Author: bdelacretaz
Date: Wed Oct 10 16:10:08 2012
New Revision: 1396663

URL: http://svn.apache.org/viewvc?rev=1396663&view=rev
Log:
SLING-2617 - integration tests

Added:
    sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/issues/SLING2617Test.java
    sling/trunk/launchpad/integration-tests/src/main/resources/integration-test/issues/sling2617/
    sling/trunk/launchpad/integration-tests/src/main/resources/integration-test/issues/sling2617/bean-set-get.jsp
Modified:
    sling/trunk/launchpad/builder/src/main/bundles/list.xml

Modified: sling/trunk/launchpad/builder/src/main/bundles/list.xml
URL: http://svn.apache.org/viewvc/sling/trunk/launchpad/builder/src/main/bundles/list.xml?rev=1396663&r1=1396662&r2=1396663&view=diff
==============================================================================
--- sling/trunk/launchpad/builder/src/main/bundles/list.xml (original)
+++ sling/trunk/launchpad/builder/src/main/bundles/list.xml Wed Oct 10 16:10:08 2012
@@ -146,7 +146,7 @@
         <bundle>
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.jcr.classloader</artifactId>
-            <version>3.1.8</version>
+            <version>3.1.9-SNAPSHOT</version>
         </bundle>
         <bundle>
             <groupId>org.apache.sling</groupId>

Added: sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/issues/SLING2617Test.java
URL: http://svn.apache.org/viewvc/sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/issues/SLING2617Test.java?rev=1396663&view=auto
==============================================================================
--- sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/issues/SLING2617Test.java
(added)
+++ sling/trunk/launchpad/integration-tests/src/main/java/org/apache/sling/launchpad/webapp/integrationtest/issues/SLING2617Test.java
Wed Oct 10 16:10:08 2012
@@ -0,0 +1,55 @@
+/*
+ * 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 org.apache.sling.launchpad.webapp.integrationtest.issues;
+
+import javax.servlet.http.HttpServletResponse;
+
+import org.apache.sling.commons.testing.integration.HttpTestBase;
+
+public class SLING2617Test extends HttpTestBase {
+    
+    private final String TEST_PATH = "/" + getClass().getSimpleName();
+
+    public void testDateBeanProperties() throws Exception {
+        final String [] mustContain = { 
+                "New time (123456)",
+                "JSP should have access to org.apache.sling.scripting.jsp.jasper.JasperException:
YES",
+                "All good!" 
+        };
+
+        final TestNode tn = new TestNode(HTTP_BASE_URL + TEST_PATH, null);
+
+        String toDelete = null;
+        try {
+            toDelete = uploadTestScript(tn.scriptPath, "issues/sling2617/bean-set-get.jsp",
"html.jsp");
+            final String content = getContent(tn.nodeUrl + ".html", CONTENT_TYPE_HTML,
+                    null, HttpServletResponse.SC_OK);
+
+            for(String str : mustContain) {
+                assertTrue("Content must contain " + str + " (" + content + ")", content.contains(str));
+            }
+
+        } finally {
+            if (toDelete != null) {
+                testClient.delete(toDelete);
+            }
+            tn.delete();
+        }
+    }
+}

Added: sling/trunk/launchpad/integration-tests/src/main/resources/integration-test/issues/sling2617/bean-set-get.jsp
URL: http://svn.apache.org/viewvc/sling/trunk/launchpad/integration-tests/src/main/resources/integration-test/issues/sling2617/bean-set-get.jsp?rev=1396663&view=auto
==============================================================================
--- sling/trunk/launchpad/integration-tests/src/main/resources/integration-test/issues/sling2617/bean-set-get.jsp
(added)
+++ sling/trunk/launchpad/integration-tests/src/main/resources/integration-test/issues/sling2617/bean-set-get.jsp
Wed Oct 10 16:10:08 2012
@@ -0,0 +1,26 @@
+/*
+ * 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.
+ */
+ 
+<%-- used by SLING2617Test --%>
+<jsp:useBean id="date" scope="page" class="java.util.Date" /> 
+Old time (<jsp:getProperty name="date" property="time"/>) 
+<jsp:setProperty name="date" property="time" value="123456"/> 
+New time (<jsp:getProperty name="date" property="time"/>)
+JSP should have access to <%= new org.apache.sling.scripting.jsp.jasper.JasperException("YES")
%> 
+All good!
\ No newline at end of file



Mime
View raw message