You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Jörg Schaible <jo...@gmx.de> on 2011/05/27 22:59:10 UTC

Fwd: svn commit: r1128448 - /commons/proper/validator/trunk/src/test/java/org/apache/commons/validator/routines/DomainValidatorTest.java

Hi Nick,

--------------- Weitergeleitete Nachricht (Anfang)

Betreff: svn commit: r1128448 - URL: 
http://svn.apache.org/viewvc/commons/proper/validator/trunk/src/test/java/org/apache/commons/validator/routines/DomainValidatorTest.java?rev=1128448&r1=1128447&r2=1128448&view=diff
==============================================================================
--- 
commons/proper/validator/trunk/src/test/java/org/apache/commons/validator/routines/DomainValidatorTest.java 
(original)
+++ 
commons/proper/validator/trunk/src/test/java/org/apache/commons/validator/routines/DomainValidatorTest.java 
Fri May 27 20:39:42 2011
@@ -106,4 +106,8 @@ public class DomainValidatorTest extends
        assertTrue("apache.org should validate", 
allowLocal.isValid("apache.org"));
        assertFalse("domain name with spaces shouldn't validate", 
allowLocal.isValid(" apache.org "));
     }
+    
+    public void testIDN() {
+       assertTrue("bücher.ch in IDN should validate", 
validator.isValid("www.xn--bcher-kva.ch"));
+    }
 }
--------------- Weitergeleitete Nachricht (Ende)

You should not use non-ASCII characters in source code. You have no control 
over the OS encoding used for anyone else that checks out the source 
(Subversion has no idea about encoding) or downloads it from our tarballs. 
Always use \uXXXX encoding.

Cheers,
Jörg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: Fwd: svn commit: r1128448 - /commons/proper/validator/trunk/src/test/java/org/apache/commons/validator /routines/DomainValidatorTest.java

Posted by Nick Burch <ni...@alfresco.com>.
On Fri, 27 May 2011, Jörg Schaible wrote:
> You should not use non-ASCII characters in source code. You have no 
> control over the OS encoding used for anyone else that checks out the 
> source (Subversion has no idea about encoding) or downloads it from our 
> tarballs. Always use \uXXXX encoding.

Thanks for the tip, serves me right for cutting and pasting the test 
string from the IDN example! Should be fixed now

Nick