aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/email.scm27
1 files changed, 25 insertions, 2 deletions
diff --git a/tests/email.scm b/tests/email.scm
index a2b6361..8a7be9b 100644
--- a/tests/email.scm
+++ b/tests/email.scm
@@ -190,6 +190,31 @@ Hi everyone.")
(message-id . "5678.21-Nov-1997@example.com"))
"Hi everyone."))
+(test-email= "RFC5322 A.6.1. Obsolete addressing"
+ (parse-email
+ (string->bytevector
+ "From: Joe Q. Public <john.q.public@example.com>
+To: Mary Smith <@node.test:mary@example.net>, , jdoe@test . example
+Date: Tue, 1 Jul 2003 10:52:37 +0200
+Message-ID: <5678.21-Nov-1997@example.com>
+
+Hi everyone.
+"
+ "utf-8"))
+ (make-email
+ `((from ((name . "Joe Q. Public")
+ (address . "john.q.public@example.com")))
+ (to ((name . "Mary Smith")
+ (address . "mary@example.net"))
+ ((address . "jdoe@test . example")))
+ (date . ,(make-date 0 37 52 10 1 7 2003 7200))
+ (message-id . "5678.21-Nov-1997@example.com")
+ (content-type (type . text)
+ (subtype . plain)
+ (charset . "utf-8"))
+ (content-transfer-encoding . 7bit))
+ "Hi everyone."))
+
(test-email= "RFC2046 5.1.1. Common syntax"
(parse-email
(string->bytevector
@@ -410,8 +435,6 @@ copyright =A9")
(parse-email-address "foo@example.org (Foo)")
'((name . "Foo") (address . "foo@example.org")))
-(test-expect-fail "parse email addresses with period in name")
-
(test-equal "parse email addresses with period in name"
(parse-email-address "Foo P. Bar <foo@example.com>")
'((name . "Foo P. Bar") (address . "foo@example.com")))