From: Bruno Haible Date: Mon, 9 Dec 2024 08:51:01 +0000 (+0100) Subject: quotearg tests: Fix test failure (regression yesterday). X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=d3d8e7c935ea1fdc9387c24a836bc0b22d3bcc21;p=gnulib.git quotearg tests: Fix test failure (regression yesterday). * tests/testlocale/fr/LC_MESSAGES/gnulib.po: Renamed from tests/testlocale/fr/LC_MESSAGES/test-quotearg.po. * tests/testlocale/fr/LC_MESSAGES/gnulib.mo: Renamed from tests/testlocale/fr/LC_MESSAGES/test-quotearg.mo. * tests/test-quotearg.c (main): Use bindtextdomain for the domain "gnulib", not "test-quotearg". * tests/test-quotearg.sh: Fix typo in comments. * modules/quotearg-tests (Files): Update. --- diff --git a/ChangeLog b/ChangeLog index 322b1bac99..e740515f06 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,15 @@ +2024-12-09 Bruno Haible + + quotearg tests: Fix test failure (regression yesterday). + * tests/testlocale/fr/LC_MESSAGES/gnulib.po: Renamed from + tests/testlocale/fr/LC_MESSAGES/test-quotearg.po. + * tests/testlocale/fr/LC_MESSAGES/gnulib.mo: Renamed from + tests/testlocale/fr/LC_MESSAGES/test-quotearg.mo. + * tests/test-quotearg.c (main): Use bindtextdomain for the domain + "gnulib", not "test-quotearg". + * tests/test-quotearg.sh: Fix typo in comments. + * modules/quotearg-tests (Files): Update. + 2024-12-08 Bruno Haible Document the new approach for gnulib localization. diff --git a/modules/quotearg-tests b/modules/quotearg-tests index d297f0b0aa..22223a9534 100644 --- a/modules/quotearg-tests +++ b/modules/quotearg-tests @@ -6,8 +6,8 @@ tests/test-quotearg.sh tests/test-quotearg.c tests/test-quotearg.h tests/macros.h -tests/testlocale/fr/LC_MESSAGES/test-quotearg.po -tests/testlocale/fr/LC_MESSAGES/test-quotearg.mo +tests/testlocale/fr/LC_MESSAGES/gnulib.po +tests/testlocale/fr/LC_MESSAGES/gnulib.mo m4/locale-fr.m4 m4/codeset.m4 diff --git a/tests/test-quotearg.c b/tests/test-quotearg.c index 0283f1ca1c..84bead7402 100644 --- a/tests/test-quotearg.c +++ b/tests/test-quotearg.c @@ -82,8 +82,7 @@ main (_GL_UNUSED int argc, char *argv[]) fputs ("Skipping test: no french Unicode locale is installed\n", stderr); return 77; } - textdomain ("test-quotearg"); - bindtextdomain ("test-quotearg", getenv ("LOCALEDIR")); + bindtextdomain ("gnulib", getenv ("LOCALEDIR")); set_quoting_style (NULL, locale_quoting_style); compare_strings (use_quotearg_buffer, &locale_results[0].group1, false); diff --git a/tests/test-quotearg.sh b/tests/test-quotearg.sh index e11b66783a..3d895a1534 100755 --- a/tests/test-quotearg.sh +++ b/tests/test-quotearg.sh @@ -14,7 +14,7 @@ fi # Work around a limitation of gettext() on native Windows in gettext 0.18.1: # the locale identifiers in the environment variables LC_ALL etc. have to -# be in Unix conventions, not in native Window conventions. +# be in Unix conventions, not in native Windows conventions. if test $locale = French_France.65001; then locale=fr_FR.UTF-8 fi diff --git a/tests/testlocale/fr/LC_MESSAGES/gnulib.mo b/tests/testlocale/fr/LC_MESSAGES/gnulib.mo new file mode 100644 index 0000000000..87e97e1e1f Binary files /dev/null and b/tests/testlocale/fr/LC_MESSAGES/gnulib.mo differ diff --git a/tests/testlocale/fr/LC_MESSAGES/gnulib.po b/tests/testlocale/fr/LC_MESSAGES/gnulib.po new file mode 100644 index 0000000000..1ea251f459 --- /dev/null +++ b/tests/testlocale/fr/LC_MESSAGES/gnulib.po @@ -0,0 +1,20 @@ +# Message catalog that maps the ASCII replacements for single-quote characters +# to real single-quote characters. +# The header entry is commented out on purpose, so that gettext() performs no +# no character set conversion from the PO file's encoding to the locale +# encoding. This allows us to use the same PO file in various locales. +#msgid "" +#msgstr "" +#"Project-Id-Version: GNU gnulib\n" +#"PO-Revision-Date: 2009-01-26 01:02+01:00\n" +#"Last-Translator: Eric Blake \n" +#"Language-Team: Undetermined \n" +#"MIME-Version: 1.0\n" +#"Content-Type: text/plain; charset=UTF-8\n" +#"Content-Transfer-Encoding: 8bit\n" + +msgid "`" +msgstr "\302\253" + +msgid "'" +msgstr "\302\273" diff --git a/tests/testlocale/fr/LC_MESSAGES/test-quotearg.mo b/tests/testlocale/fr/LC_MESSAGES/test-quotearg.mo deleted file mode 100644 index 87e97e1e1f..0000000000 Binary files a/tests/testlocale/fr/LC_MESSAGES/test-quotearg.mo and /dev/null differ diff --git a/tests/testlocale/fr/LC_MESSAGES/test-quotearg.po b/tests/testlocale/fr/LC_MESSAGES/test-quotearg.po deleted file mode 100644 index 1ea251f459..0000000000 --- a/tests/testlocale/fr/LC_MESSAGES/test-quotearg.po +++ /dev/null @@ -1,20 +0,0 @@ -# Message catalog that maps the ASCII replacements for single-quote characters -# to real single-quote characters. -# The header entry is commented out on purpose, so that gettext() performs no -# no character set conversion from the PO file's encoding to the locale -# encoding. This allows us to use the same PO file in various locales. -#msgid "" -#msgstr "" -#"Project-Id-Version: GNU gnulib\n" -#"PO-Revision-Date: 2009-01-26 01:02+01:00\n" -#"Last-Translator: Eric Blake \n" -#"Language-Team: Undetermined \n" -#"MIME-Version: 1.0\n" -#"Content-Type: text/plain; charset=UTF-8\n" -#"Content-Transfer-Encoding: 8bit\n" - -msgid "`" -msgstr "\302\253" - -msgid "'" -msgstr "\302\273"