Test not the standard utf-8 codec but gb18030 which is the most complex

codec in multibytecodec consumers.
This commit is contained in:
Hye-Shik Chang 2004-01-20 09:11:48 +00:00
parent 1301892715
commit a5e719e081
1 changed files with 4 additions and 4 deletions

View File

@ -62,12 +62,12 @@ class Test_StreamWriter(unittest.TestCase):
pass
def test_nullcoding(self):
self.assertEqual(''.decode('utf-8'), u'')
self.assertEqual(unicode('', 'utf-8'), u'')
self.assertEqual(u''.encode('utf-8'), '')
self.assertEqual(''.decode('gb18030'), u'')
self.assertEqual(unicode('', 'gb18030'), u'')
self.assertEqual(u''.encode('gb18030'), '')
def test_str_decode(self):
self.assertEqual('abcd'.encode('utf-8'), 'abcd')
self.assertEqual('abcd'.encode('gb18030'), 'abcd')
def test_main():
suite = unittest.TestSuite()