GNU bug report logs -
#62420
29.0.60; fns-tests-collate-strings fails on Cygwin
Previous Next
Reported by: Ken Brown <kbrown <at> cornell.edu>
Date: Fri, 24 Mar 2023 14:59:02 UTC
Severity: normal
Found in version 29.0.60
Done: Ken Brown <kbrown <at> cornell.edu>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
The test in the subject fails on Cygwin as follows:
Test fns-tests-collate-strings condition:
(ert-test-failed
((should-error
(string-collate-equalp "xyzzy" "xyzzy" "en_DE.UTF-8"))
:form
(string-collate-equalp "xyzzy" "xyzzy" "en_DE.UTF-8")
:value t :fail-reason "did not signal an error"))
The reason is that en_DE.UTF-8 is actually a valid locale on Cygwin.
[Cygwin gets its locale information from Windows. The latter supports
the RFC 5646 locale "en-DE", which is called "English (Germany)" in the
"Region" settings.]
The following trivial patch fixes the problem:
--- a/test/src/fns-tests.el
+++ b/test/src/fns-tests.el
@@ -254,7 +254,7 @@ fns-tests-collate-strings
(should (string-collate-equalp "xyzzy" "XYZZY" nil t))
;; Locale must be valid.
- (should-error (string-collate-equalp "xyzzy" "xyzzy" "en_DE.UTF-8")))
+ (should-error (string-collate-equalp "xyzzy" "xyzzy" "en_XY.UTF-8")))
;; There must be a check for valid codepoints. (Check not
implemented yet)
; (should-error
Is this OK for the emacs-29 branch?
[Note: The test will still fail on current Cygwin after this patch; but
that's because of a bug in Cygwin, which has been fixed in the
development sources for Cygwin 3.5.]
Ken
This bug report was last modified 2 years and 59 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.