summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2014-11-02 17:26:28 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2014-11-02 17:26:28 (GMT)
commitbb019eb4c1fc68cb2c83110306d4b4ff80355cd4 (patch)
treef17f7f24a5c3c8851a3be51b8e0a703278520989 /Lib
parentc1ded29f8ed57b1ace0eff22c36bccb7b8c34887 (diff)
parent6e2db04345b76e6b06ca9c7a604b63ddcaf90cc4 (diff)
downloadcpython-bb019eb4c1fc68cb2c83110306d4b4ff80355cd4.zip
cpython-bb019eb4c1fc68cb2c83110306d4b4ff80355cd4.tar.gz
cpython-bb019eb4c1fc68cb2c83110306d4b4ff80355cd4.tar.bz2
Merge heads
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test___all__.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/test/test___all__.py b/Lib/test/test___all__.py
index 8cc285f..e94d984 100644
--- a/Lib/test/test___all__.py
+++ b/Lib/test/test___all__.py
@@ -72,13 +72,14 @@ class AllTest(unittest.TestCase):
# rlcompleter needs special consideration; it import readline which
# initializes GNU readline which calls setlocale(LC_CTYPE, "")... :-(
+ import locale
+ locale_tuple = locale.getlocale(locale.LC_CTYPE)
try:
import rlcompleter
- import locale
except ImportError:
pass
- else:
- locale.setlocale(locale.LC_CTYPE, 'C')
+ finally:
+ locale.setlocale(locale.LC_CTYPE, locale_tuple)
ignored = []
failed_imports = []