jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ang...@apache.org
Subject svn commit: r1479906 - in /jackrabbit/oak/trunk: oak-core/src/main/java/org/apache/jackrabbit/oak/security/user/MembershipProvider.java oak-jcr/pom.xml oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/security/user/UserImportBestEffortTest.java
Date Tue, 07 May 2013 13:44:02 GMT
Author: angela
Date: Tue May  7 13:44:01 2013
New Revision: 1479906

URL: http://svn.apache.org/r1479906
Log:
OAK-414 : UserImporter (include more tests)
OAK-50 : Implement User Management  (minor adjustment to fix UserImporter)

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/user/MembershipProvider.java
    jackrabbit/oak/trunk/oak-jcr/pom.xml
    jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/security/user/UserImportBestEffortTest.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/user/MembershipProvider.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/user/MembershipProvider.java?rev=1479906&r1=1479905&r2=1479906&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/user/MembershipProvider.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/user/MembershipProvider.java
Tue May  7 13:44:01 2013
@@ -16,19 +16,16 @@
  */
 package org.apache.jackrabbit.oak.security.user;
 
-import static org.apache.jackrabbit.oak.api.Type.STRINGS;
-import static org.apache.jackrabbit.oak.api.Type.WEAKREFERENCE;
-
 import java.util.Collections;
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.Set;
-
 import javax.annotation.Nonnull;
 import javax.annotation.Nullable;
 
 import com.google.common.base.Function;
 import com.google.common.base.Predicate;
+import com.google.common.base.Predicates;
 import com.google.common.collect.Iterables;
 import com.google.common.collect.Iterators;
 import org.apache.jackrabbit.commons.iterator.RangeIteratorAdapter;
@@ -45,6 +42,9 @@ import org.apache.jackrabbit.oak.util.Pr
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+import static org.apache.jackrabbit.oak.api.Type.STRINGS;
+import static org.apache.jackrabbit.oak.api.Type.WEAKREFERENCE;
+
 /**
  * {@code MembershipProvider} implementation storing group membership information
  * with the {@code Tree} associated with a given {@link org.apache.jackrabbit.api.security.user.Group}.
@@ -130,12 +130,12 @@ class MembershipProvider extends Authori
             PropertyState property = groupTree.getProperty(REP_MEMBERS);
             if (property != null) {
                 Iterable<String> vs = property.getValue(STRINGS);
-                memberPaths = Iterables.transform(vs, new Function<String, String>()
{
+                memberPaths = Iterables.filter(Iterables.transform(vs, new Function<String,
String>() {
                     @Override
                     public String apply(@Nullable String value) {
                         return identifierManager.getPath(PropertyStates.createProperty("",
value, WEAKREFERENCE));
                     }
-                });
+                }), Predicates.<String>notNull());
             }
         }
 

Modified: jackrabbit/oak/trunk/oak-jcr/pom.xml
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/pom.xml?rev=1479906&r1=1479905&r2=1479906&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/pom.xml (original)
+++ jackrabbit/oak/trunk/oak-jcr/pom.xml Tue May  7 13:44:01 2013
@@ -291,7 +291,6 @@
       org.apache.jackrabbit.oak.jcr.security.authorization.AccessControlImporterTest#testImportACLRemoveACE
<!-- OAK-414 -->
       org.apache.jackrabbit.oak.jcr.security.authorization.AccessControlImporterTest#testImportACLUnknown
  <!-- OAK-414 -->
       org.apache.jackrabbit.oak.jcr.security.authorization.AccessControlImporterTest#testImportPolicyExists
<!-- OAK-414 -->
-      org.apache.jackrabbit.oak.jcr.security.user.UserImportBestEffortTest#testImportNonExistingMemberBestEffort
  <!-- OAK-414 -->
       org.apache.jackrabbit.oak.jcr.security.user.UserImportBestEffortTest#testImportNonExistingMemberBestEffort2
 <!-- OAK-414 -->
       org.apache.jackrabbit.oak.jcr.security.user.MemberNodeImportTest                  
                   <!-- OAK-414, OAK-482 -->
 

Modified: jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/security/user/UserImportBestEffortTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/security/user/UserImportBestEffortTest.java?rev=1479906&r1=1479905&r2=1479906&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/security/user/UserImportBestEffortTest.java
(original)
+++ jackrabbit/oak/trunk/oak-jcr/src/test/java/org/apache/jackrabbit/oak/jcr/security/user/UserImportBestEffortTest.java
Tue May  7 13:44:01 2013
@@ -48,7 +48,6 @@ public class UserImportBestEffortTest ex
         return ImportBehavior.NAME_BESTEFFORT;
     }
 
-    @Ignore("OAK-414") // FIXME
     @Test
     public void testImportNonExistingMemberBestEffort() throws Exception {
         List<String> invalid = new ArrayList<String>();



Mime
View raw message