jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r1486944 - /jackrabbit/oak/trunk/oak-mongomk/src/test/java/org/apache/jackrabbit/mongomk/ConflictTest.java
Date Tue, 28 May 2013 14:53:14 GMT
Author: mreutegg
Date: Tue May 28 14:53:14 2013
New Revision: 1486944

URL: http://svn.apache.org/r1486944
Log:
OAK-846: Branch conflicts not detected by MongoMK
- Adding ignored test

Modified:
    jackrabbit/oak/trunk/oak-mongomk/src/test/java/org/apache/jackrabbit/mongomk/ConflictTest.java

Modified: jackrabbit/oak/trunk/oak-mongomk/src/test/java/org/apache/jackrabbit/mongomk/ConflictTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-mongomk/src/test/java/org/apache/jackrabbit/mongomk/ConflictTest.java?rev=1486944&r1=1486943&r2=1486944&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-mongomk/src/test/java/org/apache/jackrabbit/mongomk/ConflictTest.java
(original)
+++ jackrabbit/oak/trunk/oak-mongomk/src/test/java/org/apache/jackrabbit/mongomk/ConflictTest.java
Tue May 28 14:53:14 2013
@@ -17,6 +17,7 @@
 package org.apache.jackrabbit.mongomk;
 
 import org.apache.jackrabbit.mk.api.MicroKernelException;
+import org.junit.Ignore;
 import org.junit.Test;
 
 import static org.junit.Assert.fail;
@@ -327,6 +328,26 @@ public class ConflictTest extends BaseMo
         }
     }
 
+    @Ignore("OAK-846")
+    @Test
+    public void changeChangedPropertyTwoBranches(){
+        String rev = mk.commit("/", "+\"foo\":{\"prop\":\"value\"}", null, null);
+
+        String b1 = mk.branch(rev);
+        String b2 = mk.branch(rev);
+
+        b1 = mk.commit("/foo", "^\"prop\":\"bar\"", b1, null);
+        mk.merge(b1, null);
+
+        b2 = mk.commit("/foo", "^\"prop\":\"baz\"", b2, null);
+        try {
+            mk.merge(b2, null);
+            fail("Must fail with conflict for changeChangedProperty");
+        } catch (MicroKernelException e) {
+            // expected
+        }
+    }
+
     @Test
     public void addExistingNode() {
         String rev = mk.commit("/", "+\"foo\":{}", null, null);



Mime
View raw message