summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_locale.py
Commit message (Collapse)AuthorAgeFilesLines
* GH-124108: Skip test_locale.test_strcoll_with_diacritic() on NetBSD (#124110)Furkan Onder2024-09-161-0/+4
| | | | | Skip test_strcoll_with_diacritic() and test_strxfrm_with_diacritic() of test_locale on NetBSD due to lack of UTF-8 LC_COLLATE support.
* gh-104783: locale.getencoding() fallback uses FS encoding (#105381)Victor Stinner2023-06-061-0/+11
| | | | | The locale.getencoding() function now uses sys.getfilesystemencoding() if _locale.getencoding() is missing, instead of calling locale.getdefaultlocale().
* gh-94226: Remove the locale.format() function (#94229)Victor Stinner2022-06-261-71/+47
| | | | | | | Remove the locale.format() function, deprecated in Python 3.7: use locale.format_string() instead. Remove TestFormatPatternArg test case: it is irrelevant for locale.format_string() which accepts complex formats.
* gh-90473: Skip tests that don't apply to Emscripten and WASI (GH-92846)Christian Heimes2022-05-161-3/+9
|
* gh-91156: Use `locale.getencoding()` instead of getpreferredencoding (GH-91732)Inada Naoki2022-04-221-1/+9
| | | Co-authored-by: Victor Stinner <vstinner@python.org>
* bpo-40280: Skip more tests on Emscripten (GH-31947)Christian Heimes2022-03-171-1/+3
| | | | | | - lchmod, lchown are not fully implemented - skip umask tests - cannot fstat unlinked or renamed files yet - ignore musl libc issues that affect Emscripten
* bpo-46659: Deprecate locale.getdefaultlocale() (GH-31206)Victor Stinner2022-02-221-1/+2
| | | | | | The locale.getdefaultlocale() function is deprecated and will be removed in Python 3.13. Use locale.setlocale(), locale.getpreferredencoding(False) and locale.getlocale() functions instead.
* Fix typos in the Lib directory (GH-28775)Christian Clauss2021-10-061-1/+1
| | | | | Fix typos in the Lib directory as identified by codespell. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-34311: Add locale.localize (GH-15275)Cédric Krier2021-04-121-0/+28
| | | | * Add method localize to the locale module * Update the documentation of the locale module
* bpo-37945: Fix test_locale.test_getsetlocale_issue1813() (#25110)Victor Stinner2021-03-311-1/+7
| | | Skip the test if setlocale() fails.
* bpo-40275: Use new test.support helper submodules in tests (GH-21412)Hai Shi2020-07-091-1/+2
|
* bpo-38536: locale: Remove trailing space in formatted currency (GH-16864)Inada Naoki2020-01-201-2/+1
|
* bpo-18378: Recognize "UTF-8" as a valid name in locale._parse_localename ↵Ronald Oussoren2019-08-291-0/+36
| | | | (GH-14736)
* Remove unused imports in tests (GH-14518)Victor Stinner2019-07-011-1/+1
|
* Revert "bpo-33671: Add support.MS_WINDOWS and support.MACOS (GH-7800)" (GH-7919)Victor Stinner2018-06-261-10/+9
| | | This reverts commit 8fbbdf0c3107c3052659e166f73990b466eacbb0.
* bpo-33671: Add support.MS_WINDOWS and support.MACOS (GH-7800)Victor Stinner2018-06-221-9/+10
| | | | | | | | * Add support.MS_WINDOWS: True if Python is running on Microsoft Windows. * Add support.MACOS: True if Python is running on Apple macOS. * Replace support.is_android with support.ANDROID * Replace support.is_jython with support.JYTHON * Cleanup code to initialize unix_shell
* bpo-20087: Update locale alias mapping with glibc 2.27 supported locales. ↵Serhiy Storchaka2018-05-061-1/+1
| | | | (ПР-6708)
* [security] bpo-13617: Reject embedded null characters in wchar* strings. (#2302)Serhiy Storchaka2017-06-281-0/+5
| | | | | | | Based on patch by Victor Stinner. Add private C API function _PyUnicode_AsUnicode() which is similar to PyUnicode_AsUnicode(), but checks for null characters.
* bpo-29972: Skip tests known to fail on AIX (#979)Victor Stinner2017-04-041-0/+4
| | | | | | | | | | | | | | | | | | | | | | * bpo-29972: Fix test_eintr on AIX On AIX, sigtimedwait(0.2) sleeps 199.8 ms, whereas the test expects 200 ms or longer. * bpo-29972: Skip some inet_pton() tests on AIX Skip some inet_pton() tests of test_socket on AIX. inet_pton() on AIX is less strict than on Linux and doesn't reject some invalid IP addresses. The unit tests test more the libc than Python itself. * bpo-29972: Skip tests known to fail on AIX * test_locale.test_strcoll_with_diacritic() * test_locale.test_strxfrm_with_diacritic() * test_strptime.test_week_of_year_and_day_of_week_calculation() * test_tools.test_POT_Creation_Date()
* test_locale now ignores the DeprecationWarning (#977)Victor Stinner2017-04-031-11/+13
| | | | | Don't fail anymore if test run with python3 -Werror. Fix also deprecation message: add a space.
* bpo-10379: add 'monetary' to format_string, deprecate formatGarvit Khatri2017-03-281-0/+5
| | | | | | | Add the 'monetary' parameter to format_string so that all uses of format can be converted to format_string. Adjust the documentation accordingly, and add a deprecation warning when format is used.
* bpo-20087: Revert "make the glibc alias table take precedence over the X11 ↵Benjamin Peterson2017-03-201-4/+1
| | | | | one (#422)" (#713) This reverts commit 02371e0ed1ee82ec73e7d363bcf2ed40cde1397a.
* make the glibc alias table take precedence over the X11 one (#422)Benjamin Peterson2017-03-081-1/+4
| | | bpo-20087
* Issue #28996: Skip two tests that fail on Android with the locale strcoll() andXavier de Gaye2016-12-191-2/+2
| | | | strxfrm() functions.
* Issue #23474: Enhanced locale testing.Serhiy Storchaka2015-02-181-1/+1
|\
| * Issue #23474: Enhanced locale testing.Serhiy Storchaka2015-02-181-1/+1
| |
* | Issue #13918: Provide a locale.delocalize() function which can removeAntoine Pitrou2014-10-231-0/+54
|/ | | | | locale-specific number formatting from a string representing a number, without then converting it to a specific type. Patch by Cédric Krier.
* Issue #20079: Fixed tests.Serhiy Storchaka2014-10-021-1/+1
|
* Issue #20046: Locale alias table no longer contains entities which can beSerhiy Storchaka2013-12-261-0/+39
| | | | calculated. Generalized support of the euro modifier.
* Issue #20027: Fixed locale aliases for devanagari locales.Serhiy Storchaka2013-12-261-0/+14
|\
| * Issue #20027: Fixed locale aliases for devanagari locales.Serhiy Storchaka2013-12-261-0/+14
| |
| * Don't use sebTest() in tests for issue #5815.Serhiy Storchaka2013-12-191-2/+1
| |
| * Issue #5815: Fixed support for locales with modifiers. Fixed support forSerhiy Storchaka2013-12-191-0/+58
| | | | | | | | locale encodings with hyphens.
* | Issue #5815: Fixed support for locales with modifiers. Fixed support forSerhiy Storchaka2013-12-191-0/+58
|/ | | | locale encodings with hyphens.
* Issue #17767: test_locale now works with unittest test discovery.Serhiy Storchaka2013-07-171-58/+36
| | | | Original patch by Zachary Ware.
* Issue #15118: Change return value of os.uname() and os.times() fromLarry Hastings2012-06-241-1/+1
| | | | | plain tuples to immutable iterable objects with named attributes (structseq objects).
* Issue #1813: merge changeset that reverts a glibc workaround for theStefan Krah2012-02-021-3/+0
|\ | | | | | | Fedora buildbot.
| * Issue #1813: Revert workaround for a glibc bug on the Fedora buildbot.Stefan Krah2012-02-021-3/+0
| |
* | Issue #13441: Reenable strxfrm() tests on SolarisVictor Stinner2011-11-211-4/+0
| |
* | Issue #13441: Disable temporary strxfrm() tests on SolarisVictor Stinner2011-11-211-0/+4
| |
* | Issue #3067: Fix the error raised by locale.setlocale()Petri Lehtinen2011-11-041-0/+8
|\ \ | |/
| * Issue #3067: Fix the error raised by locale.setlocale()Petri Lehtinen2011-11-041-0/+8
| |
* | Merge 68b5f87566fbStefan Krah2011-08-011-0/+3
|\ \ | |/
| * Skip test_getsetlocale_issue1813() on Fedora due to setlocale() bug.Stefan Krah2011-08-011-0/+3
| | | | | | | | See: https://bugzilla.redhat.com/show_bug.cgi?id=726536
| * Backport 0398f07d4827 (fix for weird buildbot failures)Antoine Pitrou2011-07-261-3/+3
| |
* | Try to fix weird buildbot failuresAntoine Pitrou2011-07-261-3/+3
| |
* | Add debug output for failing buildbotAntoine Pitrou2011-07-261-0/+2
|/
* Add a test for issue #1813: getlocale() failing under a Turkish localeAntoine Pitrou2011-07-241-0/+13
| | | | (not a problem under 3.x)
* Issue #9868: locale was left changed after TestEnUSCollation#setUp raisedHirokazu Yamamoto2010-09-231-1/+1
| | | | TestSkip exception.
* Merged revisions 80512 via svnmerge fromR. David Murray2010-04-271-0/+20
| | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r80512 | r.david.murray | 2010-04-26 17:17:14 -0400 (Mon, 26 Apr 2010) | 7 lines Issue #6656: fix locale.format_string to handle escaped percents and mappings. Refactors format_string. Includes tests for the two problems noted in the issue, but as far as I can see there are no other tests that confirm that format_string conforms to normal % formatting rules. ........