summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_decimal.py
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2024-10-08 08:40:02 (GMT)
committerGitHub <noreply@github.com>2024-10-08 08:40:02 (GMT)
commit19984fe024bfd90649f1c36b78c9abf3ed72b27d (patch)
tree71518f45b3db2d8ccaaaffb03151c27006c89839 /Lib/test/test_decimal.py
parent7c4b6a68f263320a2dd19cd5ff63b35c964b1fa8 (diff)
downloadcpython-19984fe024bfd90649f1c36b78c9abf3ed72b27d.zip
cpython-19984fe024bfd90649f1c36b78c9abf3ed72b27d.tar.gz
cpython-19984fe024bfd90649f1c36b78c9abf3ed72b27d.tar.bz2
gh-53203: Improve tests for strptime() (GH-125090)
Run them with different locales and different date and time. Add the @run_with_locales() decorator to run the test with multiple locales. Improve the run_with_locale() context manager/decorator -- it now catches only expected exceptions and reports the test as skipped if no appropriate locale is available.
Diffstat (limited to 'Lib/test/test_decimal.py')
-rw-r--r--Lib/test/test_decimal.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_decimal.py b/Lib/test/test_decimal.py
index c591fd5..d1e7e69 100644
--- a/Lib/test/test_decimal.py
+++ b/Lib/test/test_decimal.py
@@ -1253,7 +1253,7 @@ class FormatTest:
self.assertRaises(ValueError, format, h, '10Nf')
self.assertRaises(ValueError, format, h, 'Nx')
- @run_with_locale('LC_ALL', 'ps_AF')
+ @run_with_locale('LC_ALL', 'ps_AF', '')
def test_wide_char_separator_decimal_point(self):
# locale with wide char separator and decimal point
Decimal = self.decimal.Decimal