SLING-6350 - clarify a few cases and expose the problem

git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1773021 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/src/test/java/org/apache/sling/api/resource/path/PathTest.java b/src/test/java/org/apache/sling/api/resource/path/PathTest.java
index 29f45ad..fa80b4e 100644
--- a/src/test/java/org/apache/sling/api/resource/path/PathTest.java
+++ b/src/test/java/org/apache/sling/api/resource/path/PathTest.java
@@ -54,6 +54,7 @@
         assertTrue(path_1.matches("/apps/project/a.html"));
         assertTrue(path_1.matches("/apps/project/1/a.html"));
         assertTrue(path_1.matches("/apps/project/1/2/a.html"));
+        assertTrue(path_1.matches("/apps/project/1/2/3/4/5/6/7/8/9/a.html"));
         assertFalse(path_1.matches("/apps/a.html"));
         assertFalse(path_1.matches("/apps/project/a.html/b"));
 
@@ -68,6 +69,9 @@
         assertTrue(path_3.matches("/a/m-p/$structure/1/[cmp]/.html"));
         assertFalse(path_3.matches("/a/m-p/$structure/1/[cmp]/html"));
         assertFalse(path_3.matches("/a/m-p/$structure/[cmp]/test.html"));
+        
+        // TODO this should be assertTrue?? as per SLING-6350
+        assertFalse(path_3.matches("/a/m-p/$structure/1/2/3/4/5/6[cmp]/test.html"));
     }
 
     @Test public void testPatternRootMatching() {
@@ -84,6 +88,14 @@
         assertTrue(path.matches("glob:/*/myproject"));
         assertTrue(path.matches("glob:/*/*project"));
         assertTrue(path.matches("glob:/*/*project/**.html"));
+        assertTrue(path.matches("glob:/**/myproject"));
+        assertTrue(path.matches("glob:/**/myproject/*.jsp"));
+        
+        // TODO this should be assertTrue?? as per SLING-6350
+        assertFalse(path.matches("glob:/**"));
+        
+        // TODO this should be assertTrue?? as per SLING-6350
+        assertFalse(path.matches("glob:/**/*.jsp"));
     }
 
     @Test public void testIllegalArgumentException() {