aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorArun Isaac2019-10-09 02:04:38 +0530
committerArun Isaac2019-10-09 02:04:38 +0530
commit121073cb725aef9baecaac0cfb6cf3f5a287c4e7 (patch)
treef8870bbb9ebc839b8b6df45a42321e65e1e1d4ca /tests
parente0849c498564b4d23df503a34c22fb237551bbc8 (diff)
downloadguile-email-121073cb725aef9baecaac0cfb6cf3f5a287c4e7.tar.gz
guile-email-121073cb725aef9baecaac0cfb6cf3f5a287c4e7.tar.lz
guile-email-121073cb725aef9baecaac0cfb6cf3f5a287c4e7.zip
email: Return keywords header as a list.
* email/email.scm (parse-email-headers): Return keywords header as a list of strings. * tests/email.scm ("keywords header must be a list"): New test.
Diffstat (limited to 'tests')
-rw-r--r--tests/email.scm11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/email.scm b/tests/email.scm
index c82f567..03c3b70 100644
--- a/tests/email.scm
+++ b/tests/email.scm
@@ -365,6 +365,17 @@ copyright =A9")
(content-transfer-encoding . quoted-printable))
"copyright �"))
+(test-alist= "keywords header must be a list"
+ (parse-email-headers
+ "Keywords: foo, bar
+")
+
+ `((keywords " foo" " bar")
+ (content-type (type . text)
+ (subtype . plain)
+ (charset . "utf-8"))
+ (content-transfer-encoding . 7bit)))
+
(test-equal "parse name-addr email address"
(parse-email-address "Foo <foo@example.org>")
'((name . "Foo") (address . "foo@example.org")))