]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Use en_US.UTF-8 locale for tests instead of ru_RU.UTF-8 or ja_JP.UTF-8
authorMichihiro NAKAJIMA <ggcueroad@gmail.com>
Sun, 15 May 2011 14:39:47 +0000 (10:39 -0400)
committerMichihiro NAKAJIMA <ggcueroad@gmail.com>
Sun, 15 May 2011 14:39:47 +0000 (10:39 -0400)
since some platform do not install those locales by default.

SVN-Revision: 3333

libarchive/test/test_gnutar_filename_encoding.c
libarchive/test/test_read_format_cab_filename.c
libarchive/test/test_read_format_cpio_filename.c
libarchive/test/test_read_format_gtar_filename.c
libarchive/test/test_read_format_lha_filename.c
libarchive/test/test_read_format_tar_filename.c
libarchive/test/test_read_format_ustar_filename.c
libarchive/test/test_read_format_zip_filename.c
libarchive/test/test_ustar_filename_encoding.c
libarchive/test/test_zip_filename_encoding.c

index 0433f67495a28783f3d950a1d514b9c528a3ecea..12906867e184a3dfec4a5c480eae862f73d2d05a 100644 (file)
@@ -35,8 +35,8 @@ test_gnutar_filename_encoding_UTF8_CP866()
        char buff[4096];
        size_t used;
 
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
index 3e5deb00d78f77c98315adc3bb6c9c025c6448bb..54374deb9b3710dc665bcc8792e31d726223754d 100644 (file)
@@ -87,10 +87,10 @@ test_read_format_cab_filename_CP932_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read CAB filename in ja_JP.UTF-8 with "hdrcharset=CP932" option.
+        * Read CAB filename in en_US.UTF-8 with "hdrcharset=CP932" option.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
index 7803373b22a07fc257f8617f89ef33f21bd914c4..e347b506844b5100452fd5e8bb1e3c53228c3fdf 100644 (file)
@@ -34,10 +34,10 @@ test_read_format_cpio_filename_eucJP_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read eucJP filename in ja_JP.UTF-8 with "hdrcharset=eucJP" option.
+        * Read eucJP filename in en_US.UTF-8 with "hdrcharset=eucJP" option.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -135,10 +135,10 @@ test_read_format_cpio_filename_UTF8_UTF8_jp(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read UTF-8 filename in ja_JP.UTF-8 without "hdrcharset=UTF-8" option.
+        * Read UTF-8 filename in en_US.UTF-8 without "hdrcharset=UTF-8" option.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -233,10 +233,10 @@ test_read_format_cpio_filename_CP866_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read CP866 filename in ru_RU.UTF-8 with "hdrcharset=CP866" option.
+        * Read CP866 filename in en_US.UTF-8 with "hdrcharset=CP866" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -336,10 +336,10 @@ test_read_format_cpio_filename_KOI8R_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read KOI8-R filename in ru_RU.UTF-8 with "hdrcharset=KOI8-R" option.
+        * Read KOI8-R filename in en_US.UTF-8 with "hdrcharset=KOI8-R" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -491,10 +491,10 @@ test_read_format_cpio_filename_UTF8_UTF8_ru(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read UTF-8 filename in ru_RU.UTF-8 without "hdrcharset=UTF-8" option.
+        * Read UTF-8 filename in en_US.UTF-8 without "hdrcharset=UTF-8" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
index 5feb1e6eb6543562223e32751e8d4d83e63f6319..4b2a88c1ee0bc867b7fab7c2ebf7036338388480 100644 (file)
@@ -34,10 +34,10 @@ test_read_format_gtar_filename_eucJP_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read eucJP filename in ja_JP.UTF-8 with "hdrcharset=eucJP" option.
+        * Read eucJP filename in en_US.UTF-8 with "hdrcharset=eucJP" option.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -136,10 +136,10 @@ test_read_format_gtar_filename_CP866_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read CP866 filename in ru_RU.UTF-8 with "hdrcharset=CP866" option.
+        * Read CP866 filename in en_US.UTF-8 with "hdrcharset=CP866" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -239,10 +239,10 @@ test_read_format_gtar_filename_KOI8R_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read KOI8-R filename in ru_RU.UTF-8 with "hdrcharset=KOI8-R" option.
+        * Read KOI8-R filename in en_US.UTF-8 with "hdrcharset=KOI8-R" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
index 92f09a5d2e91250f8f32ea80473854e267075fb0..e39dfac41ac128130e7d3d829b294d80b396d96c 100644 (file)
@@ -94,10 +94,10 @@ test_read_format_lha_filename_CP932_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read LHA filename in ja_JP.UTF-8.
+        * Read LHA filename in en_US.UTF-8.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
        /*
index b0b03c445038ca0cdd3b7f453125af5522995f59..abec4ec6d6ca309b66a72eca1a18d29cb83e6d41 100644 (file)
@@ -154,11 +154,11 @@ test_read_format_tar_filename_KOI8R_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read filename in ru_RU.UTF-8 with "hdrcharset=KOI8-R" option.
+        * Read filename in en_US.UTF-8 with "hdrcharset=KOI8-R" option.
         * We should correctly read two filenames.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -200,7 +200,7 @@ test_read_format_tar_filename_KOI8R_UTF8(const char *refname)
        assertEqualInt(ARCHIVE_OK, archive_read_free(a));
 
        /*
-        * Read filename in ru_RU.UTF-8 without "hdrcharset=KOI8-R" option.
+        * Read filename in en_US.UTF-8 without "hdrcharset=KOI8-R" option.
         * The filename we can properly read is only second file.
         */
 
index 59ccc8e61d2e6f11a9b9234769ae70ba4cd4fb2a..f2e577d0a3b9f666b4c207028244bc3e8a32f119 100644 (file)
@@ -34,10 +34,10 @@ test_read_format_ustar_filename_eucJP_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read eucJP filename in ja_JP.UTF-8 with "hdrcharset=eucJP" option.
+        * Read eucJP filename in en_US.UTF-8 with "hdrcharset=eucJP" option.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -136,10 +136,10 @@ test_read_format_ustar_filename_CP866_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read CP866 filename in ru_RU.UTF-8 with "hdrcharset=CP866" option.
+        * Read CP866 filename in en_US.UTF-8 with "hdrcharset=CP866" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -239,10 +239,10 @@ test_read_format_ustar_filename_KOI8R_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read KOI8-R filename in ru_RU.UTF-8 with "hdrcharset=KOI8-R" option.
+        * Read KOI8-R filename in en_US.UTF-8 with "hdrcharset=KOI8-R" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
index 9d2c989815a534ad44168e554b71a9fc0174cd0f..e35fe22913aa6ebc3fc463e29935d7914dc8ee6a 100644 (file)
@@ -87,10 +87,10 @@ test_read_format_zip_filename_CP932_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read CP932 filename in ja_JP.UTF-8 with "hdrcharset=CP932" option.
+        * Read CP932 filename in en_US.UTF-8 with "hdrcharset=CP932" option.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -227,12 +227,12 @@ test_read_format_zip_filename_UTF8_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read UTF-8 filename in ja_JP.UTF-8 without charset option
+        * Read UTF-8 filename in en_US.UTF-8 without charset option
         * because the file name in the sample file is UTF-8 and
         * Bit 11 of its general purpose bit flag is set.
         */
-       if (NULL == setlocale(LC_ALL, "ja_JP.UTF-8")) {
-               skipping("ja_JP.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -337,10 +337,10 @@ test_read_format_zip_filename_CP866_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read CP866 filename in ru_RU.UTF-8 with "hdrcharset=CP866" option.
+        * Read CP866 filename in en_US.UTF-8 with "hdrcharset=CP866" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -440,10 +440,10 @@ test_read_format_zip_filename_KOI8R_UTF8(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read KOI8-R filename in ru_RU.UTF-8 with "hdrcharset=KOI8-R" option.
+        * Read KOI8-R filename in en_US.UTF-8 with "hdrcharset=KOI8-R" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -608,12 +608,12 @@ test_read_format_zip_filename_UTF8_UTF8_ru(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read UTF-8 filename in ru_RU.UTF-8 without charset option
+        * Read UTF-8 filename in en_US.UTF-8 without charset option
         * because the file name in the sample file is UTF-8 and
         * Bit 11 of its general purpose bit flag is set.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -1003,10 +1003,10 @@ test_read_format_zip_filename_KOI8R_UTF8_2(const char *refname)
        struct archive_entry *ae;
 
        /*
-        * Read filename in ru_RU.UTF-8 with "hdrcharset=KOI8-R" option.
+        * Read filename in en_US.UTF-8 with "hdrcharset=KOI8-R" option.
         */
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
@@ -1051,7 +1051,7 @@ next_test:
        assertEqualInt(ARCHIVE_OK, archive_read_free(a));
 
        /*
-        * Read filename in ru_RU.UTF-8 without "hdrcharset=KOI8-R" option.
+        * Read filename in en_US.UTF-8 without "hdrcharset=KOI8-R" option.
         * The filename we can properly read is only second file.
         */
        assert((a = archive_read_new()) != NULL);
index dcc656686ea438d80e7cc3999e31937cf484d76e..1391e3697c1e91197e5c58f5efe7b0efce8f385f 100644 (file)
@@ -35,8 +35,8 @@ test_ustar_filename_encoding_UTF8_CP866()
        char buff[4096];
        size_t used;
 
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }
 
index 66d28333249c3cf59fd5af766bdd70a197d7c6ea..30b42e59cbe92f7fbd64ce36b57982b07bcbc678 100644 (file)
@@ -35,8 +35,8 @@ test_zip_filename_encoding_UTF8()
        char buff[4096];
        size_t used;
 
-       if (NULL == setlocale(LC_ALL, "ru_RU.UTF-8")) {
-               skipping("ru_RU.UTF-8 locale not available on this system.");
+       if (NULL == setlocale(LC_ALL, "en_US.UTF-8")) {
+               skipping("en_US.UTF-8 locale not available on this system.");
                return;
        }