diff options
author | Hye-Shik Chang <hyeshik@gmail.com> | 2006-07-06 15:21:52 (GMT) |
---|---|---|
committer | Hye-Shik Chang <hyeshik@gmail.com> | 2006-07-06 15:21:52 (GMT) |
commit | 84392bee485cbec871b7c13ee4d4d38c9348948a (patch) | |
tree | b9888abe52ba89b18eac70a4be3e067faa20d687 /Lib | |
parent | 653f23cc81adc6db1ce1aed8a9c97f90d9b2ef22 (diff) | |
download | cpython-84392bee485cbec871b7c13ee4d4d38c9348948a.zip cpython-84392bee485cbec871b7c13ee4d4d38c9348948a.tar.gz cpython-84392bee485cbec871b7c13ee4d4d38c9348948a.tar.bz2 |
Add a testcase for r47086 which fixed a bug in codec_getstreamcodec().
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_multibytecodec.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/Lib/test/test_multibytecodec.py b/Lib/test/test_multibytecodec.py index 276b9af..78326b5 100644 --- a/Lib/test/test_multibytecodec.py +++ b/Lib/test/test_multibytecodec.py @@ -6,7 +6,8 @@ from test import test_support from test import test_multibytecodec_support -import unittest, StringIO, codecs, sys +from test.test_support import TESTFN +import unittest, StringIO, codecs, sys, os class Test_MultibyteCodec(unittest.TestCase): @@ -25,6 +26,13 @@ class Test_MultibyteCodec(unittest.TestCase): self.assertRaises(IndexError, dec, 'apple\x92ham\x93spam', 'test.cjktest') + def test_codingspec(self): + print >> open(TESTFN, 'w'), '# coding: euc-kr' + try: + exec open(TESTFN) + finally: + os.unlink(TESTFN) + class Test_IncrementalEncoder(unittest.TestCase): def test_stateless(self): |