jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ang...@apache.org
Subject svn commit: r1562027 - /jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/CopyTest.java
Date Tue, 28 Jan 2014 10:37:32 GMT
Author: angela
Date: Tue Jan 28 10:37:32 2014
New Revision: 1562027

URL: http://svn.apache.org/r1562027
Log:
OAK-919: test-case
OAK-915: enable tests

Modified:
    jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/CopyTest.java

Modified: jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/CopyTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/CopyTest.java?rev=1562027&r1=1562026&r2=1562027&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/CopyTest.java
(original)
+++ jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/CopyTest.java
Tue Jan 28 10:37:32 2014
@@ -70,7 +70,6 @@ public class CopyTest extends AbstractRe
         assertTrue(testNode.hasNode("target/copied"));
     }
 
-    @Ignore("OAK-915") // FIXME
     @Test
     public void testCopyReferenceableNode() throws Exception {
         Session session = getAdminSession();
@@ -89,7 +88,6 @@ public class CopyTest extends AbstractRe
         assertFalse(copy.getUUID().equals(testNode.getNode("source/node").getUUID()));
     }
 
-    @Ignore("OAK-915") // FIXME
     @Test
     public void testCopyReferenceableChildNode() throws Exception {
         Session session = getAdminSession();
@@ -142,14 +140,17 @@ public class CopyTest extends AbstractRe
         session.save();
 
         session.getWorkspace().getLockManager().lock(toCopy.getPath(), true, true, Long.MAX_VALUE,
"my");
-        session.getWorkspace().copy(TEST_PATH + "/source/node", TEST_PATH + "/target/copied");
+        assertTrue(toCopy.isLocked());
+        assertTrue(toCopy.hasProperty(JcrConstants.JCR_LOCKISDEEP));
+        assertTrue(toCopy.hasProperty(JcrConstants.JCR_LOCKOWNER));
 
+        session.getWorkspace().copy(TEST_PATH + "/source/node", TEST_PATH + "/target/copied");
         assertTrue(testNode.hasNode("source/node"));
         assertTrue(testNode.hasNode("target/copied"));
 
         Node copy = testNode.getNode("target/copied");
-
-        assertFalse(copy.isNodeType(JcrConstants.MIX_LOCKABLE));
+        assertTrue(copy.isNodeType(JcrConstants.MIX_LOCKABLE));
+        assertFalse(copy.isLocked());
         assertFalse(copy.hasProperty(JcrConstants.JCR_LOCKISDEEP));
         assertFalse(copy.hasProperty(JcrConstants.JCR_LOCKOWNER));
     }



Mime
View raw message