about summary refs log tree commit homepage
path: root/t
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2014-09-15 20:58:41 +0000
committerEric Wong <e@80x24.org>2014-09-15 20:58:41 +0000
commit1a4da197b5390141ae338d80199112b256b140ba (patch)
tree61fc84a8bc5d8f1ccfb3c8cdff08e5579e6c20a2 /t
parenta4cea21b8bde2897786a8fab4b33b669b935011c (diff)
downloadpublic-inbox-1a4da197b5390141ae338d80199112b256b140ba.tar.gz
Unix line endings are LF-only, so do not introduce or preserve
CRLF line endings when reading from lynx.
Diffstat (limited to 't')
-rw-r--r--t/filter.t3
1 files changed, 2 insertions, 1 deletions
diff --git a/t/filter.t b/t/filter.t
index e4f6a2b0..7a4bdb19 100644
--- a/t/filter.t
+++ b/t/filter.t
@@ -85,13 +85,14 @@ sub count_body_parts {
                         'Content-Type' => 'text/html',
                         Subject => 'HTML only badness',
                 ],
-                body => "<html><body>bad body</body></html>\n",
+                body => "<html><body>bad body\r\n</body></html>\n",
         );
         is(1, PublicInbox::Filter->run($s), "run was a success");
         unlike($s->as_string, qr/<html>/, "HTML removed");
         is("text/plain", $s->header("Content-Type"),
                 "content-type changed");
         like($s->body, qr/\A\s*bad body\s*\z/, "body");
+        unlike($s->body, qr/\r/, "body has no cr");
         like($s->header("X-Content-Filtered-By"),
                 qr/PublicInbox::Filter/, "XCFB header added");
 }