X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=t%2Fmid.t;h=8c307c825d22a7e2747c8f35fb1df0909c798dcb;hb=0ef5872cee83f07c9ae7afceb2e92257507dc3ca;hp=223be798c47704f7a1823e6f59037ead36c840c6;hpb=cfb8d16578e7f2f2e300f9f436205e4a8fc7f322;p=public-inbox.git diff --git a/t/mid.t b/t/mid.t index 223be798..8c307c82 100644 --- a/t/mid.t +++ b/t/mid.t @@ -25,6 +25,17 @@ is(mid_escape('foo%!@(bar)'), 'foo%25!@(bar)'); $mime->header_set('In-Reply-To', ''); is_deeply(['hello', 'world', 'weld'], references($mime->header_obj), 'references combines with In-Reply-To'); + + $mime->header_set('References', "\n\t"); + $mime->header_set('In-Reply-To'); + is_deeply(references($mime->header_obj), ['hello', 'world'], + 'multiline References OK'); + $mime->header_set('References', ""); + is_deeply(references($mime->header_obj), ['helloworld'], + 'drop \t in References <656C30A1EFC89F6B2082D9B6@localhost>'); + $mime->header_set('Message-ID', ""); + is_deeply(mids($mime->header_obj), ['helloworld'], + 'drop \t in Message-ID'); } done_testing();