Commit 1a56665e authored by Skip Montanaro's avatar Skip Montanaro

add not-yet-supported Unicode test just so it doesn't get lost.

parent 446ad715
# -*- coding: iso-8859-1 -*-
# Copyright (C) 2001,2002 Python Software Foundation
# csv package unit tests
......@@ -640,6 +641,25 @@ else:
# if writer leaks during write, last delta should be 5 or more
self.assertEqual(delta < 5, True)
# commented out for now - csv module doesn't yet support Unicode
if 0:
from StringIO import StringIO
import csv
class TestUnicode(unittest.TestCase):
def test_unicode_read(self):
import codecs
f = codecs.EncodedFile(StringIO("Martin von Lwis,"
"Marc Andr Lemburg,"
"Guido van Rossum,"
"Franois Pinard\r\n"),
data_encoding='iso-8859-1')
reader = csv.reader(f)
self.assertEqual(list(reader), [[u"Martin von Lwis",
u"Marc Andr Lemburg",
u"Guido van Rossum",
u"Franois Pinardn"]])
def test_main():
mod = sys.modules[__name__]
test_support.run_unittest(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment