diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-05-07 14:38:44 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-05-07 14:38:44 (GMT) |
commit | d8bebc9a8f94efc1f3d9f5cbe98365cf8d0efe23 (patch) | |
tree | 0198c3d533e0affc9a12d07acd15fc9f6328dd16 /tests/utf.test | |
parent | 74330f28739f9f3c3020e7245ccf6710251534ae (diff) | |
parent | 13faf8b1d4ae63413f8d1c301c422aeab3eb977b (diff) | |
download | tcl-d8bebc9a8f94efc1f3d9f5cbe98365cf8d0efe23.zip tcl-d8bebc9a8f94efc1f3d9f5cbe98365cf8d0efe23.tar.gz tcl-d8bebc9a8f94efc1f3d9f5cbe98365cf8d0efe23.tar.bz2 |
Merge 8.6
Diffstat (limited to 'tests/utf.test')
-rw-r--r-- | tests/utf.test | 64 |
1 files changed, 29 insertions, 35 deletions
diff --git a/tests/utf.test b/tests/utf.test index 285b71b..0522674 100644 --- a/tests/utf.test +++ b/tests/utf.test @@ -103,19 +103,16 @@ test utf-2.6 {Tcl_UtfToUniChar: lead (3-byte) followed by 1 trail} testbytestrin test utf-2.7 {Tcl_UtfToUniChar: lead (3-byte) followed by 2 trail} testbytestring { string length [testbytestring \xE4\xB9\x8E] } 1 -test utf-2.8.0 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} {testbytestring ucs2} { +test utf-2.8.0 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} {testbytestring utf16} { string length [testbytestring \xF0\x90\x80\x80] -} 4 +} 2 test utf-2.8.1 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} {testbytestring ucs4} { string length [testbytestring \xF0\x90\x80\x80] } 1 -test utf-2.8.2 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} {testbytestring utf16} { - string length [testbytestring \xF0\x90\x80\x80] -} 2 test utf-2.9.0 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} {testbytestring ucs2} { string length [testbytestring \xF4\x8F\xBF\xBF] } 4 -test utf-2.9.1 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} {Uesc ucs4} { +test utf-2.9.1 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} ucs4 { string length \U10FFFF } 1 test utf-2.9.2 {Tcl_UtfToUniChar: lead (4-byte) followed by 3 trail} utf16 { @@ -169,15 +166,12 @@ test utf-4.10 {Tcl_NumUtfChars: #u0000, calc len, overcomplete} {testnumutfchars test utf-4.11 {Tcl_NumUtfChars: 3 bytes of 4-byte UTF-8 characater} {testnumutfchars testbytestring} { testnumutfchars [testbytestring \xF0\x9F\x92\xA9] end-1 } 3 -test utf-4.12.0 {Tcl_NumUtfChars: #4-byte UTF-8 character} {testnumutfchars testbytestring ucs2} { +test utf-4.12.0 {Tcl_NumUtfChars: #4-byte UTF-8 character} {testnumutfchars testbytestring utf16} { testnumutfchars [testbytestring \xF0\x9F\x92\xA9] end -} 4 +} 2 test utf-4.12.1 {Tcl_NumUtfChars: #4-byte UTF-8 character} {testnumutfchars testbytestring ucs4} { testnumutfchars [testbytestring \xF0\x9F\x92\xA9] end } 1 -test utf-4.12.2 {Tcl_NumUtfChars: #4-byte UTF-8 character} {testnumutfchars testbytestring utf16} { - testnumutfchars [testbytestring \xF0\x9F\x92\xA9] end -} 2 test utf-5.1 {Tcl_UtfFindFirst} {testfindfirst testbytestring} { testfindfirst [testbytestring abcbc] 98 @@ -189,7 +183,7 @@ test utf-5.2 {Tcl_UtfFindLast} {testfindlast testbytestring} { test utf-6.1 {Tcl_UtfNext} {testutfnext testbytestring} { # This takes the pointer one past the terminating NUL. # This is really an invalid call. - testutfnext [testbytestring {}] + testutfnext {} } 1 test utf-6.2 {Tcl_UtfNext} testutfnext { testutfnext A @@ -392,7 +386,7 @@ test utf-6.67 {Tcl_UtfNext} {testutfnext testbytestring} { test utf-6.68 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xA0\xA0]G } 1 -test utf-6.69.0 {Tcl_UtfNext} {testutfnext utf16} { +test utf-6.69.0 {Tcl_UtfNext} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF2\xA0\xA0\xA0] } 4 test utf-6.69.1 {Tcl_UtfNext} {testutfnext ucs4} { @@ -410,40 +404,40 @@ test utf-6.72 {Tcl_UtfNext} {testutfnext testbytestring} { test utf-6.73 {Tcl_UtfNext} {testutfnext testbytestring} { testutfnext [testbytestring \xF2\xA0\xA0\xF8] } 1 -test utf-6.74.0 {Tcl_UtfNext} {testutfnext utf16} { +test utf-6.74.0 {Tcl_UtfNext} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF2\xA0\xA0\xA0]G } 4 -test utf-6.74.1 {Tcl_UtfNext} {testutfnext ucs4} { +test utf-6.74.1 {Tcl_UtfNext} {testutfnext testbytestring ucs4} { testutfnext [testbytestring \xF2\xA0\xA0\xA0]G } 4 -test utf-6.75.0 {Tcl_UtfNext} {testutfnext utf16} { +test utf-6.75.0 {Tcl_UtfNext} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xA0] } 4 -test utf-6.75.1 {Tcl_UtfNext} {testutfnext ucs4} { +test utf-6.75.1 {Tcl_UtfNext} {testutfnext testbytestring ucs4} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xA0] } 4 -test utf-6.76.0 {Tcl_UtfNext} {testutfnext utf16} { +test utf-6.76.0 {Tcl_UtfNext} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xD0] } 4 -test utf-6.76.1 {Tcl_UtfNext} {testutfnext ucs4} { +test utf-6.76.1 {Tcl_UtfNext} {testutfnext testbytestring ucs4} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xD0] } 4 -test utf-6.77.0 {Tcl_UtfNext} {testutfnext utf16} { +test utf-6.77.0 {Tcl_UtfNext} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xE8] } 4 -test utf-6.77.1 {Tcl_UtfNext} {testutfnext ucs4} { +test utf-6.77.1 {Tcl_UtfNext} {testutfnext testbytestring ucs4} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xE8] } 4 -test utf-6.78.0 {Tcl_UtfNext} {testutfnext utf16} { +test utf-6.78.0 {Tcl_UtfNext} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xF2] } 4 -test utf-6.78.1 {Tcl_UtfNext} {testutfnext ucs4} { +test utf-6.78.1 {Tcl_UtfNext} {testutfnext testbytestring ucs4} { testutfnext [testbytestring \xF2\xA0\xA0\xA0\xF2] } 4 -test utf-6.79.0 {Tcl_UtfNext} {testutfnext utf16} { +test utf-6.79.0 {Tcl_UtfNext} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF2\xA0\xA0\xA0G\xF8] } 4 -test utf-6.79.1 {Tcl_UtfNext} {testutfnext ucs4} { +test utf-6.79.1 {Tcl_UtfNext} {testutfnext testbytestring ucs4} { testutfnext [testbytestring \xF2\xA0\xA0\xA0G\xF8] } 4 test utf-6.80 {Tcl_UtfNext - overlong sequences} {testutfnext testbytestring} { @@ -467,10 +461,10 @@ test utf-6.85 {Tcl_UtfNext - overlong sequences} {testutfnext testbytestring} { test utf-6.86 {Tcl_UtfNext - overlong sequences} {testutfnext testbytestring} { testutfnext [testbytestring \xF0\x80\x80\x80] } 1 -test utf-6.87.0 {Tcl_UtfNext - overlong sequences} {testutfnext utf16} { +test utf-6.87.0 {Tcl_UtfNext - overlong sequences} {testutfnext testbytestring utf16} { testutfnext [testbytestring \xF0\x90\x80\x80] } 4 -test utf-6.87.1 {Tcl_UtfNext - overlong sequences} {testutfnext ucs4} { +test utf-6.87.1 {Tcl_UtfNext - overlong sequences} {testutfnext testbytestring ucs4} { testutfnext [testbytestring \xF0\x90\x80\x80] } 4 test utf-6.88 {Tcl_UtfNext, pointing to 2th byte of 3-byte valid sequence} {testutfnext testbytestring} { @@ -804,25 +798,25 @@ test utf-7.47.1 {Tcl_UtfPrev, pointing to 3th byte of 3-byte valid sequence} {te test utf-7.47.2 {Tcl_UtfPrev, pointing to 3th byte of 3-byte invalid sequence} {testutfprev testbytestring} { testutfprev [testbytestring \xE8\xA0\x00] 2 } 0 -test utf-7.48.0 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring utf16} { +test utf-7.48.0 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev utf16} { testutfprev A\uDBFF\uDFFF } 2 -test utf-7.48.1 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring ucs4} { +test utf-7.48.1 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev ucs4} { testutfprev A\U10FFFF } 1 -test utf-7.48.2 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring utf16} { +test utf-7.48.2 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev utf16} { testutfprev A\uDBFF\uDFFF 4 } 1 -test utf-7.48.3 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring ucs4} { +test utf-7.48.3 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev ucs4} { testutfprev A\U10FFFF 4 } 1 -test utf-7.48.4 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring utf16} { +test utf-7.48.4 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev utf16} { testutfprev A\uDBFF\uDFFF 3 } 1 -test utf-7.48.5 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring ucs4} { +test utf-7.48.5 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev ucs4} { testutfprev A\U10FFFF 3 } 1 -test utf-7.48.6 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring} { +test utf-7.48.6 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev fullutf} { testutfprev A\U10FFFF 2 } 1 test utf-7.49.0 {Tcl_UtfPrev, validity check [493dccc2de]} {testutfprev testbytestring utf16} { @@ -852,7 +846,7 @@ test utf-8.3 {Tcl_UniCharAtIndex: index > 0} { } c test utf-8.4 {Tcl_UniCharAtIndex: index > 0} { string index \u4E4E\u25A\xFF\u543 2 -} \uFF +} \xFF test utf-8.5.0 {Tcl_UniCharAtIndex: high surrogate} ucs2 { string index \uD842 0 } \uD842 |