groovy965_bug.groovy
来自「Groovy动态语言 运行在JVM中的动态语言 可以方便的处理业务逻辑变化大的业」· GROOVY 代码 · 共 38 行
GROOVY
38 行
package groovy.bug/** * A test case to ensure that Groovy can compile class names and variable names with non-ASCII * characters and that non-ASCII characters in Strings do the right thing. * * <p>Unfortunately, we cannot actually have this test in the Subversion store since it * requires having an encoding. Java internally uses UTF-16. Most Linux/UNIX/Mac OS X users * use UTF-8 (or if they haven't caught up yet ISO-8859-{1..15], in Europe anyway). Windows * internally is UTF-16 LE but it appears that the Europe region defaults to ISO-8859-1 which * is very silly. All in all we cannot gurantee an ecoding so we cannot have the tests.</p> * * <p>If anyone spots any errors in the rationale or finds a way to fix things please update at * will.</p> * * @suthor Russel Winder * @version $LastChangedRevision: 3988 $ $LastChangedDate: 2006-08-18 11:15:33 +0200 (Fr, 18 Aug 2006) $ */class Groovy965_Bug extends GroovyTestCase { /* void test to avoid assertion failure because of the lack of test method in the class */ void testVoid() {} /* void testUnicodeVariableNamesAndStrings ( ) { def âøñè = 'âøñè' assertEquals ( 'âøñè' , âøñè ) } void testUnicodeMëthødName ( ) { } void testUnicodeClassName ( ) { def object = new Bläh ( ) assert true } */}/*class Bläh { }*/
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?