[Python-checkins] cpython: Issue #14113: Fix a test_strptime failure caused by changes to LC_ALL.

stefan.krah python-checkins at python.org
Mon Feb 27 10:20:45 CET 2012


http://hg.python.org/cpython/rev/1ea466240792
changeset:   75307:1ea466240792
user:        Stefan Krah <skrah at bytereef.org>
date:        Mon Feb 27 10:18:51 2012 +0100
summary:
  Issue #14113: Fix a test_strptime failure caused by changes to LC_ALL.

files:
  Lib/test/test_format.py |  3 ++-
  1 files changed, 2 insertions(+), 1 deletions(-)


diff --git a/Lib/test/test_format.py b/Lib/test/test_format.py
--- a/Lib/test/test_format.py
+++ b/Lib/test/test_format.py
@@ -285,7 +285,8 @@
 
     def test_locale(self):
         try:
-            oldloc = locale.setlocale(locale.LC_ALL, '')
+            oldloc = locale.setlocale(locale.LC_ALL)
+            locale.setlocale(locale.LC_ALL, '')
         except locale.Error as err:
             self.skipTest("Cannot set locale: {}".format(err))
         try:

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list