diff options
Diffstat (limited to 'Lib/test/test_email/test_email.py')
-rw-r--r-- | Lib/test/test_email/test_email.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Lib/test/test_email/test_email.py b/Lib/test/test_email/test_email.py index c3ecd0ab..227110f 100644 --- a/Lib/test/test_email/test_email.py +++ b/Lib/test/test_email/test_email.py @@ -3389,6 +3389,12 @@ class TestFeedParsers(TestEmailBase): feedparser.feed(chunk) return feedparser.close() + def test_empty_header_name_handled(self): + # Issue 19996 + msg = self.parse("First: val\n: bad\nSecond: val") + self.assertEqual(msg['First'], 'val') + self.assertEqual(msg['Second'], 'val') + def test_newlines(self): m = self.parse(['a:\nb:\rc:\r\nd:\n']) self.assertEqual(m.keys(), ['a', 'b', 'c', 'd']) |