Kaydet (Commit) 6327e848 authored tarafından Antoine Pitrou's avatar Antoine Pitrou

Fix more buildbot failures on test_locale.

üst 524f4135
...@@ -224,10 +224,10 @@ class TestCNumberFormatting(CCookedTest, BaseFormattingTest): ...@@ -224,10 +224,10 @@ class TestCNumberFormatting(CCookedTest, BaseFormattingTest):
self._test_format("%9.2f", 12345.67, grouping=True, out=' 12345.67') self._test_format("%9.2f", 12345.67, grouping=True, out=' 12345.67')
if sys.platform != 'sunos5': class TestStringMethods(BaseLocalizedTest):
class TestStringMethods(BaseLocalizedTest):
locale_type = locale.LC_CTYPE locale_type = locale.LC_CTYPE
if sys.platform != 'sunos5' and not sys.platform.startswith("win"):
# Test BSD Rune locale's bug for isctype functions. # Test BSD Rune locale's bug for isctype functions.
def test_isspace(self): def test_isspace(self):
...@@ -275,11 +275,16 @@ class TestMiscellaneous(unittest.TestCase): ...@@ -275,11 +275,16 @@ class TestMiscellaneous(unittest.TestCase):
def test_main(): def test_main():
tests = [TestMiscellaneous, TestEnUSNumberFormatting, TestCNumberFormatting] tests = [
TestMiscellaneous,
TestEnUSNumberFormatting,
TestCNumberFormatting
]
# TestSkipped can't be raised inside unittests, handle it manually instead # TestSkipped can't be raised inside unittests, handle it manually instead
try: try:
get_enUS_locale() get_enUS_locale()
except TestSkipped as e: except TestSkipped as e:
if verbose:
print "Some tests will be disabled: %s" % e print "Some tests will be disabled: %s" % e
else: else:
tests += [TestNumberFormatting, TestStringMethods] tests += [TestNumberFormatting, TestStringMethods]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment