[Python-checkins] cpython (merge 3.2 -> default): Merge #11589: add additional tests for the email quoprimime module. (original) (raw)

r.david.murray python-checkins at python.org
Wed Mar 23 19:34:36 CET 2011


http://hg.python.org/cpython/rev/2f4865834695 changeset: 68872:2f4865834695 parent: 68869:ead9c1b9f547 parent: 68871:04c9c831803b user: R David Murray <rdmurray at bitdance.com> date: Wed Mar 23 14:29:49 2011 -0400 summary: Merge #11589: add additional tests for the email quoprimime module.

files: Lib/test/test_email/test_email.py | 194 ++++++++++++++++- 1 files changed, 179 insertions(+), 15 deletions(-)

diff --git a/Lib/test/test_email/test_email.py b/Lib/test/test_email/test_email.py --- a/Lib/test/test_email/test_email.py +++ b/Lib/test/test_email/test_email.py @@ -3344,21 +3344,185 @@ c = chr(x) self.assertEqual(quoprimime.unquote(quoprimime.quote(c)), c) - def test_header_encode(self): - eq = self.assertEqual - he = quoprimime.header_encode - eq(he(b'hello'), '=?iso-8859-1?q?hello?=') - eq(he(b'hello', charset='iso-8859-2'), '=?iso-8859-2?q?hello?=') - eq(he(b'hello\nworld'), '=?iso-8859-1?q?hello=0Aworld?=') - # Test a non-ASCII character - eq(he(b'hello\xc7there'), '=?iso-8859-1?q?hello=C7there?=')

-- Repository URL: http://hg.python.org/cpython



More information about the Python-checkins mailing list