bug-guile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#10684: guile-2.0.5 test failures on powerpc-darwin8


From: Ludovic Courtès
Subject: bug#10684: guile-2.0.5 test failures on powerpc-darwin8
Date: Sat, 04 Feb 2012 23:40:37 +0100
User-agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.93 (gnu/linux)

Hello!

I believe commit 13fb25ba0c24a9e7732d2c32dbc882c7d462bce9 (pasted below)
fixes that.  Can you confirm?

Thanks,
Ludo’.

commit 13fb25ba0c24a9e7732d2c32dbc882c7d462bce9 (HEAD, 
refs/remotes/origin/stable-2.0, refs/heads/stable-2.0)
Author: Ludovic Courtès <address@hidden>
Date:   Sat Feb 4 23:38:47 2012 +0100

    i18n: Skips ~h `format' tests when digit grouping info is missing.
    
    * test-suite/tests/i18n.test ("format ~h"): Skip tests when
      `locale-digit-grouping' returns '().

        Modified test-suite/tests/i18n.test
diff --git a/test-suite/tests/i18n.test b/test-suite/tests/i18n.test
index 335f450..ef08dd4 100644
--- a/test-suite/tests/i18n.test
+++ b/test-suite/tests/i18n.test
@@ -495,22 +495,30 @@
 
 (with-test-prefix "format ~h"
 
+  ;; Some systems like Darwin lack the `GROUPING' nl_item, and thus
+  ;; `locale-digit-grouping' defaults to '(); skip the tests in that
+  ;; case.
+
   (with-test-prefix "French"
 
     (pass-if "12345.5678"
       (under-french-locale-or-unresolved
        (lambda ()
-         (string=? "12 345,6789"
-                   (format #f "~:h" 12345.6789 %french-locale))))))
+         (if (null? (locale-digit-grouping %french-locale))
+             (throw 'unresolved)
+             (string=? "12 345,6789"
+                       (format #f "~:h" 12345.6789 %french-locale)))))))
 
   (with-test-prefix "English"
 
     (pass-if "12345.5678"
       (under-american-english-locale-or-unresolved
        (lambda ()
-         (string=? "12,345.6789"
-                   (format #f "~:h" 12345.6789
-                           %american-english-locale)))))))
+         (if (null? (locale-digit-grouping %american-english-locale))
+             (throw 'unresolved)
+             (string=? "12,345.6789"
+                       (format #f "~:h" 12345.6789
+                               %american-english-locale))))))))
 
 (with-test-prefix "monetary-amount->locale-string"

reply via email to

[Prev in Thread] Current Thread [Next in Thread]