diff options
author | R David Murray <rdmurray@bitdance.com> | 2013-07-25 16:15:28 (GMT) |
---|---|---|
committer | R David Murray <rdmurray@bitdance.com> | 2013-07-25 16:15:28 (GMT) |
commit | 4d0f808c2463d583ac6274e3f8ab92eb40f53265 (patch) | |
tree | 0698125e61ebad7137f9258b4b82ebd283bf03fd | |
parent | c985d08e51128903479aa389a14a4b123cd36f2f (diff) | |
parent | 271ade87acbe7b89653ea4faebb80812f27c12c3 (diff) | |
download | cpython-4d0f808c2463d583ac6274e3f8ab92eb40f53265.zip cpython-4d0f808c2463d583ac6274e3f8ab92eb40f53265.tar.gz cpython-4d0f808c2463d583ac6274e3f8ab92eb40f53265.tar.bz2 |
#18503: small cleanups in test_email.
Patch by Vajrasky Kok.
-rw-r--r-- | 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 index 8757924..4c82952 100644 --- a/Lib/test/test_email/test_email.py +++ b/Lib/test/test_email/test_email.py @@ -388,6 +388,7 @@ class TestMessageAPI(TestEmailBase): 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 @@ class TestMessageAPI(TestEmailBase): 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 @@ class TestMIMEMessage(TestEmailBase): eq(subpart['subject'], subject) def test_bad_multipart(self): - eq = self.assertEqual msg1 = Message() msg1['Subject'] = 'subpart 1' msg2 = Message() |