[Python-checkins] cpython (3.3): #18503: small cleanups in test_email.
r.david.murray
python-checkins at python.org
Thu Jul 25 18:18:11 CEST 2013
http://hg.python.org/cpython/rev/61d9c561b63d
changeset: 84819:61d9c561b63d
branch: 3.3
parent: 84816:b7ea3f94f6ca
user: R David Murray <rdmurray at bitdance.com>
date: Thu Jul 25 12:11:55 2013 -0400
summary:
#18503: small cleanups in test_email.
Patch by Vajrasky Kok.
files:
Lib/test/test_email/test_email.py | 4 ++--
1 files changed, 2 insertions(+), 2 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
@@ -388,6 +388,7 @@
def test_del_param_on_nonexistent_header(self):
msg = Message()
+ # Deleting param on empty msg should not raise exception.
msg.del_param('filename', 'content-disposition')
def test_del_nonexistent_param(self):
@@ -395,7 +396,7 @@
msg.add_header('Content-Type', 'text/plain', charset='utf-8')
existing_header = msg['Content-Type']
msg.del_param('foobar', header='Content-Type')
- self.assertEqual(msg['Content-Type'], 'text/plain; charset="utf-8"')
+ self.assertEqual(msg['Content-Type'], existing_header)
def test_set_type(self):
eq = self.assertEqual
@@ -2265,7 +2266,6 @@
eq(subpart['subject'], subject)
def test_bad_multipart(self):
- eq = self.assertEqual
msg1 = Message()
msg1['Subject'] = 'subpart 1'
msg2 = Message()
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list