This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
lib/locale.t: Improve debug info
authorKarl Williamson <khw@cpan.org>
Sat, 21 Jun 2014 19:23:42 +0000 (13:23 -0600)
committerKarl Williamson <khw@cpan.org>
Sat, 21 Jun 2014 19:51:49 +0000 (13:51 -0600)
I find myself needing to get the percentage of locales failing when
looking at field reports with debugging on.  This commit adds that
information.

lib/locale.t

index 2d668c4..c8741c3 100644 (file)
@@ -2228,12 +2228,14 @@ foreach $test_num ($first_locales_test_number..$final_locales_test_number) {
                     print "# problem is not likely to be Perl's\n";
                 }
             }
-            elsif ($debug) {
+            if ($debug) {
                 print "# $percent_fail% of locales (",
                       scalar(keys $Problem{$test_num}),
                       " of ",
                       scalar(@Locale),
-                      ") fail the following test\n";
+                      ") fail the above test (TODO cut-off is ",
+                      $acceptable_failure_percentage,
+                      "%)\n";
             }
         }
         print "#\n";