directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fel...@apache.org
Subject svn commit: r919846 - /directory/apacheds/trunk/core-integ/src/test/java/org/apache/directory/server/core/operations/bind/SimpleBindIT.java
Date Sat, 06 Mar 2010 20:40:33 GMT
Author: felixk
Date: Sat Mar  6 20:40:33 2010
New Revision: 919846

URL: http://svn.apache.org/viewvc?rev=919846&view=rev
Log:
Try to fix

Emmanuel:
"Ok, we have some issue when running tests in eclipse. For instance, the core-inteh operations/bind/SimpleITTest.java
:
it takes the wrong errors.properties file (using the one in I18n/test instead of I18n/main),
and has this property file just contains data used for i18n tests, we get a different error
message."

Modified:
    directory/apacheds/trunk/core-integ/src/test/java/org/apache/directory/server/core/operations/bind/SimpleBindIT.java

Modified: directory/apacheds/trunk/core-integ/src/test/java/org/apache/directory/server/core/operations/bind/SimpleBindIT.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core-integ/src/test/java/org/apache/directory/server/core/operations/bind/SimpleBindIT.java?rev=919846&r1=919845&r2=919846&view=diff
==============================================================================
--- directory/apacheds/trunk/core-integ/src/test/java/org/apache/directory/server/core/operations/bind/SimpleBindIT.java
(original)
+++ directory/apacheds/trunk/core-integ/src/test/java/org/apache/directory/server/core/operations/bind/SimpleBindIT.java
Sat Mar  6 20:40:33 2010
@@ -42,6 +42,7 @@
 import org.apache.directory.server.core.integ.AbstractLdapTestUnit;
 import org.apache.directory.server.core.integ.FrameworkRunner;
 import org.apache.directory.server.core.jndi.CoreContextFactory;
+import org.apache.directory.shared.i18n.I18n;
 import org.apache.directory.shared.ldap.constants.JndiPropertyConstants;
 import org.apache.directory.shared.ldap.exception.LdapAuthenticationException;
 import org.apache.directory.shared.ldap.exception.LdapNameNotFoundException;
@@ -189,7 +190,7 @@
         }
         catch ( InvalidNameException ine )
         {
-            assertEquals( "ERR_04201 No more characters available at position 5", ine.getMessage()
);
+        	assertTrue(I18n.err(I18n.ERR_04201), ine.getMessage().startsWith(I18n.ERR_04201));
         }
         catch ( NamingException ne )
         {
@@ -229,7 +230,8 @@
         catch ( LdapAuthenticationException lae )
         {
             lae.printStackTrace();
-            assertEquals( "ERR_229 Cannot authenticate user uid=unknown,ou=system", lae.getMessage()
);
+        	assertTrue(org.apache.directory.server.i18n.I18n.err(org.apache.directory.server.i18n.I18n.ERR_229),

+        			lae.getMessage().startsWith(org.apache.directory.server.i18n.I18n.ERR_229));
         }
         catch ( NamingException ne )
         {



Mime
View raw message