directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seelm...@apache.org
Subject svn commit: r895537 - /directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/name/FastLdapDnParserTest.java
Date Mon, 04 Jan 2010 03:07:16 GMT
Author: seelmann
Date: Mon Jan  4 03:07:15 2010
New Revision: 895537

URL: http://svn.apache.org/viewvc?rev=895537&view=rev
Log:
added some checks

Modified:
    directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/name/FastLdapDnParserTest.java

Modified: directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/name/FastLdapDnParserTest.java
URL: http://svn.apache.org/viewvc/directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/name/FastLdapDnParserTest.java?rev=895537&r1=895536&r2=895537&view=diff
==============================================================================
--- directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/name/FastLdapDnParserTest.java
(original)
+++ directory/shared/branches/shared-schema/ldap/src/test/java/org/apache/directory/shared/ldap/name/FastLdapDnParserTest.java
Mon Jan  4 03:07:15 2010
@@ -158,8 +158,22 @@
     public void testLdapDNSimple() throws NamingException
     {
         NameParser dnParser = FastLdapDnParser.getNameParser();
-        assertEquals( "a = b", ( ( LdapDN ) dnParser.parse( "a = b" ) ).getName() );
-        assertEquals( "a=b", ( ( LdapDN ) dnParser.parse( "a = b" ) ).toString() );
+        LdapDN dn = ( LdapDN ) dnParser.parse( "a = b" );
+
+        assertEquals( "a = b", dn.getName() );
+        assertEquals( "a=b", dn.getNormName() );
+        assertEquals( "a=b", dn.toString() );
+
+        assertEquals( "a = b", dn.getRdn().getUpName() );
+        assertEquals( "a=b", dn.getRdn().getNormName() );
+
+        assertEquals( "a = b", dn.getRdn().getAtav().getUpName() );
+        assertEquals( "a=b", dn.getRdn().getAtav().getNormName() );
+
+        assertEquals( "a", dn.getRdn().getAtav().getUpType() );
+        assertEquals( "a", dn.getRdn().getAtav().getNormType() );
+        assertEquals( "b", dn.getRdn().getAtav().getUpValue().get() );
+        assertEquals( "b", dn.getRdn().getAtav().getNormValue().get() );
     }
 
 



Mime
View raw message