Subject: | PATCH: Most tests in 07locale.t are being skipped on most machines |
Unless the platform has an Afghan locale, the loop searching for locales exits immediately without having found a locale with a comma radix, and so just about all the tests in the file end up being skipped. Patch attached
Subject: | 0017-cpan-version-t-07locale.t-Tests-were-likely-skipped.patch |
From 2f7ac53abacdba16ca3930b5b039e62a6df2df74 Mon Sep 17 00:00:00 2001
From: Karl Williamson <public@khwilliamson.com>
Date: Tue, 17 Dec 2013 12:25:31 -0700
Subject: [PATCH 17/18] cpan/version/t/07locale.t: Tests were likely skipped
The logic was wrong in the loop exit, so that on the many machines that
don't have an Afghan locale, most tests in the file are skipped. The
problem is that it wasn't testing if changing to the trial locale
actually worked.
---
cpan/version/t/07locale.t | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cpan/version/t/07locale.t b/cpan/version/t/07locale.t
index 93662ed..76d60aa 100644
--- a/cpan/version/t/07locale.t
+++ b/cpan/version/t/07locale.t
@@ -36,7 +36,7 @@ SKIP: {
while (<DATA>) {
chomp;
$loc = setlocale( LC_ALL, $_);
- last if localeconv()->{decimal_point} eq ',';
+ last if $loc && localeconv()->{decimal_point} eq ',';
}
skip 'Cannot test locale handling without a comma locale', 5
unless $loc and localeconv()->{decimal_point} eq ',';
--
1.8.1.3