4
(luna-define-class test-rfc2368 (lunit-test-case))
6
(luna-define-method test-rfc2368-parse-mailto-url-1 ((case test-rfc2368))
10
'(("To" . "chris@example.com"))
11
(rfc2368-parse-mailto-url "mailto:chris@example.com"))))
13
(luna-define-method test-rfc2368-parse-mailto-url-2 ((case test-rfc2368))
14
"RFC2368 example in 2. Syntax of a mailto URL "
17
(rfc2368-parse-mailto-url "mailto:addr1%2C%20addr2")
18
(rfc2368-parse-mailto-url "mailto:?to=addr1%2C%20addr2")))
21
(rfc2368-parse-mailto-url "mailto:?to=addr1%2C%20addr2")
22
(rfc2368-parse-mailto-url "mailto:addr1?to=addr2"))))
24
(luna-define-method test-rfc2368-parse-mailto-url-3 ((case test-rfc2368))
28
'(("To" . "infobot@example.com")
29
("Subject" . "current-issue"))
30
(rfc2368-parse-mailto-url
31
"mailto:infobot@example.com?subject=current-issue"))))
33
(luna-define-method test-rfc2368-parse-mailto-url-4 ((case test-rfc2368))
34
"Space in Subject field."
37
'(("To" . "infobot@example.com")
38
("Body" . "send current-issue"))
39
(rfc2368-parse-mailto-url
40
"mailto:infobot@example.com?body=send%20current-issue"))))
42
(luna-define-method test-rfc2368-parse-mailto-url-5 ((case test-rfc2368))
46
'(("To" . "infobot@example.com")
47
("Body" . "send current-issue\nsend index"))
48
(rfc2368-parse-mailto-url
49
(concat "mailto:infobot@example.com?body=send%20current-\n"
50
"issue%0D%0Asend%20index")))))