From: Andrew Svetlov Date: Sun, 12 Aug 2012 11:49:59 +0000 (+0300) Subject: fix doctest for email.header docs X-Git-Tag: v3.3.0rc1~138 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=199b78d41ae81ee33928bedbbc0910b98d4edc27;p=python fix doctest for email.header docs --- diff --git a/Doc/library/email.header.rst b/Doc/library/email.header.rst index 7d2dc2e61e..346d23fc8c 100644 --- a/Doc/library/email.header.rst +++ b/Doc/library/email.header.rst @@ -31,8 +31,8 @@ For example:: >>> msg = Message() >>> h = Header('p\xf6stal', 'iso-8859-1') >>> msg['Subject'] = h - >>> print(msg.as_string()) - Subject: =?iso-8859-1?q?p=F6stal?= + >>> msg.as_string() + 'Subject: =?iso-8859-1?q?p=F6stal?=\n\n' @@ -176,7 +176,7 @@ The :mod:`email.header` module also provides the following convenient functions. >>> from email.header import decode_header >>> decode_header('=?iso-8859-1?q?p=F6stal?=') - [('p\xf6stal', 'iso-8859-1')] + [(b'p\xf6stal', 'iso-8859-1')] .. function:: make_header(decoded_seq, maxlinelen=None, header_name=None, continuation_ws=' ')