From: Pádraig Brady
Date: Fri, 8 Feb 2013 16:05:25 +0000 (+0000)
Subject: tests: skip numfmt grouping tests on some systems
X-Git-Tag: v8.21~9
X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=54deb54db989dde759410af9918802961c43bc58;p=platform%2Fupstream%2Fcoreutils.git
tests: skip numfmt grouping tests on some systems
* tests/misc/numfmt.pl: When the system locale grouping doesn't
match our expected format for grouping 1234 in the fr_FR locale,
reset the locale to 'C' so as to skip all locale tests.
---
diff --git a/tests/misc/numfmt.pl b/tests/misc/numfmt.pl
index c542483..b46e4d5 100644
--- a/tests/misc/numfmt.pl
+++ b/tests/misc/numfmt.pl
@@ -883,7 +883,21 @@ my @Locale_Tests =
{ENV=>"LC_ALL=$locale"}],
);
-push @Tests, @Locale_Tests if $locale ne "C";
+if ($locale ne 'C')
+ {
+ # Reset locale to 'C' if LOCALE_FR_UTF8 doesn't output as expected
+ # as determined by the separate printf program.
+ open(LOC_NUM, "LC_ALL=$locale printf \"%'d\" 1234|")
+ or die "Can't fork command: $!";
+ my $loc_num =