X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;f=org.argeo.enterprise%2Fext%2Ftest%2Forg%2Fargeo%2Fosgi%2Fuseradmin%2FLdifParserTest.java;h=75bfe11ff294c6789372d86ea96011f9a210d231;hb=9885228c89ca6da1835c1c3e098c92589d76301e;hp=e7c94609f1c724ee14ea20caf2e82c29989594a6;hpb=77a5498dd5d10d2442127022efd6501a7dbddbae;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.enterprise/ext/test/org/argeo/osgi/useradmin/LdifParserTest.java b/org.argeo.enterprise/ext/test/org/argeo/osgi/useradmin/LdifParserTest.java index e7c94609f..75bfe11ff 100644 --- a/org.argeo.enterprise/ext/test/org/argeo/osgi/useradmin/LdifParserTest.java +++ b/org.argeo.enterprise/ext/test/org/argeo/osgi/useradmin/LdifParserTest.java @@ -10,9 +10,10 @@ import javax.naming.directory.Attribute; import javax.naming.directory.Attributes; import javax.naming.ldap.LdapName; -import junit.framework.TestCase; +import org.argeo.naming.LdapAttrs; +import org.argeo.naming.LdifParser; -import org.argeo.util.naming.LdifParser; +import junit.framework.TestCase; public class LdifParserTest extends TestCase implements BasicTestConstants { public void testBasicLdif() throws Exception { @@ -23,9 +24,9 @@ public class LdifParserTest extends TestCase implements BasicTestConstants { Attributes rootAttributes = res.get(rootDn); assertNotNull(rootAttributes); assertEquals("Superuser", - rootAttributes.get(LdifName.description.name()).get()); + rootAttributes.get(LdapAttrs.description.name()).get()); byte[] rawPwEntry = (byte[]) rootAttributes.get( - LdifName.userPassword.name()).get(); + LdapAttrs.userPassword.name()).get(); assertEquals("{SHA}ieSV55Qc+eQOaYDRSha/AjzNTJE=", new String(rawPwEntry)); byte[] hashedPassword = DigestUtils.sha1("demo".getBytes()); @@ -35,7 +36,7 @@ public class LdifParserTest extends TestCase implements BasicTestConstants { LdapName adminDn = new LdapName(ADMIN_GROUP_DN); Attributes adminAttributes = res.get(adminDn); assertNotNull(adminAttributes); - Attribute memberAttribute = adminAttributes.get(LdifName.member.name()); + Attribute memberAttribute = adminAttributes.get(LdapAttrs.member.name()); assertNotNull(memberAttribute); NamingEnumeration members = memberAttribute.getAll(); List users = new ArrayList();