Added fast alternate io.BytesIO implementation and its test suite.

Removed old test suite for StringIO.
Modified truncate() to imply a seek to given argument value.
This commit is contained in:
Alexandre Vassalotti 2008-05-06 19:48:38 +00:00
parent 5d8da20dd1
commit 77250f4df7
10 changed files with 1245 additions and 193 deletions

View file

@ -58,7 +58,7 @@ class MimeToolsTest(unittest.TestCase):
s.add(nb)
def test_message(self):
msg = mimetools.Message(io.StringIO(msgtext1))
msg = mimetools.Message(io.StringIO(str(msgtext1)))
self.assertEqual(msg.gettype(), "text/plain")
self.assertEqual(msg.getmaintype(), "text")
self.assertEqual(msg.getsubtype(), "plain")