MCPcopy Index your code
hub / github.com/python/cpython / test_posix_locale

Method test_posix_locale

Lib/test/test_utf8_mode.py:40–46  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

38
39 @unittest.skipIf(MS_WINDOWS, 'Windows has no POSIX locale')
40 def test_posix_locale(self):
41 code = 'import sys; print(sys.flags.utf8_mode)'
42
43 for loc in POSIX_LOCALES:
44 with self.subTest(LC_ALL=loc):
45 out = self.get_output('-c', code, LC_ALL=loc)
46 self.assertEqual(out, '1')
47
48 def test_xoption(self):
49 code = 'import sys; print(sys.flags.utf8_mode)'

Callers

nothing calls this directly

Calls 3

get_outputMethod · 0.95
subTestMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected