From: Guido van Rossum Date: Thu, 30 Aug 2007 14:02:43 +0000 (+0000) Subject: Two changes (not enough to make the test pass though) having to do with X-Git-Tag: v3.0a1~89 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5a23cc5a01458c74f8c849f41c2aea0151716668;p=python Two changes (not enough to make the test pass though) having to do with the bytes() constructor when passing str. --- diff --git a/Lib/test/test_smtplib.py b/Lib/test/test_smtplib.py index c2bd1965ac..e0dcc86cad 100644 --- a/Lib/test/test_smtplib.py +++ b/Lib/test/test_smtplib.py @@ -400,7 +400,8 @@ class SMTPSimTests(TestCase): for email, name in sim_users.items(): expected_known = (250, bytes('%s %s' % - (name, smtplib.quoteaddr(email)))) + (name, smtplib.quoteaddr(email)), + "ascii")) self.assertEqual(smtp.vrfy(email), expected_known) u = 'nobody@nowhere.com' @@ -416,7 +417,7 @@ class SMTPSimTests(TestCase): users = [] for m in members: users.append('%s %s' % (sim_users[m], smtplib.quoteaddr(m))) - expected_known = (250, bytes('\n'.join(users))) + expected_known = (250, bytes('\n'.join(users), "ascii")) self.assertEqual(smtp.expn(listname), expected_known) u = 'PSU-Members-List'