Created
November 3, 2012 10:37
-
-
Save asvetlov/4006970 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def test_non_utf8(self): | |
# Issue #16218 | |
with temp_dir() as script_dir: | |
script_basename = '\udcf1\udcea\udcf0\udce8\udcef\udcf2' | |
source = 'print("test output")\n' | |
script_name = _make_test_script(script_dir, script_basename, source) | |
if not __debug__: | |
run_args = ('-' + 'O' * sys.flags.optimize, script_name) | |
else: | |
run_args = (script_name,) | |
rc, out, _ = assert_python_ok(*run_args) | |
self.assertEqual(0, rc) | |
self.assertEqual(b"test output\n", out) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment