diff options
Diffstat (limited to 'Lib/test/test_email/test_headerregistry.py')
-rw-r--r-- | Lib/test/test_email/test_headerregistry.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/Lib/test/test_email/test_headerregistry.py b/Lib/test/test_email/test_headerregistry.py index 25347ef..bb7ca8d 100644 --- a/Lib/test/test_email/test_headerregistry.py +++ b/Lib/test/test_email/test_headerregistry.py @@ -1237,6 +1237,26 @@ class TestAddressHeader(TestHeaderBase): 'example.com', None), + 'name_ending_with_dot_without_space': + ('John X.<jxd@example.com>', + [errors.ObsoleteHeaderDefect], + '"John X." <jxd@example.com>', + 'John X.', + 'jxd@example.com', + 'jxd', + 'example.com', + None), + + 'name_starting_with_dot': + ('. Doe <jxd@example.com>', + [errors.InvalidHeaderDefect, errors.ObsoleteHeaderDefect], + '". Doe" <jxd@example.com>', + '. Doe', + 'jxd@example.com', + 'jxd', + 'example.com', + None), + } # XXX: Need many more examples, and in particular some with names in |