diff options
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/coding20731.py | 4 | ||||
-rw-r--r-- | Lib/test/test_coding.py | 9 |
2 files changed, 12 insertions, 1 deletions
diff --git a/Lib/test/coding20731.py b/Lib/test/coding20731.py new file mode 100644 index 0000000..ca4962e --- /dev/null +++ b/Lib/test/coding20731.py @@ -0,0 +1,4 @@ +#coding:latin1 + + + diff --git a/Lib/test/test_coding.py b/Lib/test/test_coding.py index 989c7a8..7606767 100644 --- a/Lib/test/test_coding.py +++ b/Lib/test/test_coding.py @@ -1,6 +1,6 @@ import unittest from test.support import TESTFN, unlink, unload -import importlib, os, sys +import importlib, os, sys, subprocess class CodingTest(unittest.TestCase): def test_bad_coding(self): @@ -58,6 +58,13 @@ class CodingTest(unittest.TestCase): self.assertTrue(c.exception.args[0].startswith(expected), msg=c.exception.args[0]) + def test_20731(self): + sub = subprocess.Popen([sys.executable, + os.path.join(os.path.dirname(__file__), + 'coding20731.py')], + stderr=subprocess.PIPE) + err = sub.communicate()[1] + self.assertEquals(err, b'') if __name__ == "__main__": unittest.main() |