summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_locale.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_locale.py')
-rw-r--r--Lib/test/test_locale.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/test/test_locale.py b/Lib/test/test_locale.py
index 7fc6372..c77dc55 100644
--- a/Lib/test/test_locale.py
+++ b/Lib/test/test_locale.py
@@ -1,4 +1,4 @@
-from test.support import run_unittest, TestSkipped, verbose
+from test.support import run_unittest, verbose
import unittest
import locale
import sys
@@ -9,7 +9,7 @@ enUS_locale = None
def get_enUS_locale():
global enUS_locale
if sys.platform == 'darwin':
- raise TestSkipped("Locale support on MacOSX is minimal")
+ raise unittest.SkipTest("Locale support on MacOSX is minimal")
if sys.platform.startswith("win"):
tlocs = ("En", "English")
else:
@@ -22,7 +22,7 @@ def get_enUS_locale():
continue
break
else:
- raise TestSkipped(
+ raise unittest.SkipTest(
"Test locale not supported (tried %s)" % (', '.join(tlocs)))
enUS_locale = tloc
locale.setlocale(locale.LC_NUMERIC, oldlocale)
@@ -318,10 +318,10 @@ def test_main():
TestCNumberFormatting,
TestFrFRNumberFormatting,
]
- # TestSkipped can't be raised inside unittests, handle it manually instead
+ # SkipTest can't be raised inside unittests, handle it manually instead
try:
get_enUS_locale()
- except TestSkipped as e:
+ except unittest.SkipTest as e:
if verbose:
print("Some tests will be disabled: %s" % e)
else: