APItest/t/utf8_warn_base.pl: Rename and modify test
authorKarl Williamson <khw@cpan.org>
Mon, 19 Jun 2017 17:01:54 +0000 (11:01 -0600)
committerKarl Williamson <khw@cpan.org>
Thu, 13 Jul 2017 03:14:25 +0000 (21:14 -0600)
This test is testing the first code point that requires 13 UTF-8 bytes
to represent on ASCII platforms.  Change the name from its previous
vague one to one that indicates this.  And don't test for it on EBCDIC
platforms, as it isn't an edge case there.

ext/XS-APItest/t/utf8_warn_base.pl

index f2d13d0..7e3d2ef 100644 (file)
@@ -304,17 +304,13 @@ my @tests;
     }
 
     if ($::is64bit) {
-        push @tests,
-            [ "More than 32 bits",
-                (isASCII)
-                ?       "\xff\x80\x80\x80\x80\x80\x81\x80\x80\x80\x80\x80\x80"
-                : I8_to_native(
-                        "\xff\xa0\xa0\xa0\xa0\xa0\xa2\xa0\xa0\xa0\xa0\xa0\xa0\xa0"),
-                0x1000000000,
-                (isASCII) ? 1 : 7,
-            ];
         if (isASCII) {
             push @tests,
+                [ "Lowest code point requiring 13 bytes to represent",
+                    "\xff\x80\x80\x80\x80\x80\x81\x80\x80\x80\x80\x80\x80",
+                    0x1000000000,
+                    1,
+                ],
                 [ "overflow that old algorithm failed to detect",
                     "\xff\x80\x90\x90\x90\xbf\xbf\xbf\xbf\xbf\xbf\xbf\xbf",
                     -1,