directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r231534 - /directory/shared/ldap/trunk/common/src/test/org/apache/ldap/common/name/DnParserTest.java
Date Thu, 11 Aug 2005 22:53:25 GMT
Author: akarasulu
Date: Thu Aug 11 15:53:23 2005
New Revision: 231534

URL: http://svn.apache.org/viewcvs?rev=231534&view=rev
Log:
emmanuels test fails as expected

Modified:
    directory/shared/ldap/trunk/common/src/test/org/apache/ldap/common/name/DnParserTest.java

Modified: directory/shared/ldap/trunk/common/src/test/org/apache/ldap/common/name/DnParserTest.java
URL: http://svn.apache.org/viewcvs/directory/shared/ldap/trunk/common/src/test/org/apache/ldap/common/name/DnParserTest.java?rev=231534&r1=231533&r2=231534&view=diff
==============================================================================
--- directory/shared/ldap/trunk/common/src/test/org/apache/ldap/common/name/DnParserTest.java
(original)
+++ directory/shared/ldap/trunk/common/src/test/org/apache/ldap/common/name/DnParserTest.java
Thu Aug 11 15:53:23 2005
@@ -224,4 +224,25 @@
                 "SN=Lu\\C4\\8Di\\C4\\87",
                 nameRFC2253_6.toString() );
     }
+
+
+    /**
+     * Class under test for Name parse(String)
+     *
+     * @throws NamingException if anything goes wrong
+     */
+    public final void testParseInvalidString() throws NamingException
+    {
+        DnParser parser = new DnParser();
+
+        try
+        {
+            Name invalid = parser.parse( "ś=śrasulu,dc=example,dc=com"
);
+            fail( "the invalid name should never succeed in a parse" );
+        }
+        catch ( Exception e )
+        {
+            assertNotNull(e);
+        }
+    }
 }  // end class DnParserTest



Mime
View raw message