From: markus schnalke <meillo@marmaro.de> Date: Mon, 9 Nov 2015 21:08:51 +0000 (+0100) Subject: Adjust the tests to less tolerant m_getfld2() X-Git-Tag: mmh-0.3~39^2~23 X-Git-Url: http://git.marmaro.de/?a=commitdiff_plain;h=5ed626079bc1aaba6d0daea2b32c43cb463244bb;p=mmh Adjust the tests to less tolerant m_getfld2() We require the header and body to be separated by an empty line. We require header lines to end with a newline. m_getfld2() does not try to guess as much as the old m_getfld() did. --- diff --git a/test/tests/bad-input/test-header b/test/tests/bad-input/test-header index 6b826a00..cb9202f3 100644 --- a/test/tests/bad-input/test-header +++ b/test/tests/bad-input/test-header @@ -32,16 +32,7 @@ runandcheck "scan $msgnum" <<! # check show runandcheck "show $msgnum" <<! -Date: Sun, 18 Dec 2005 00:52:39 +0100 -From: foo@example.edu -To: bar@example.edu -Subject: test - -part text/plain 70 - -This is a multi-part message in MIME format. - -I am a stupid spammer. +show: message format error in component #5 ! diff --git a/test/tests/mhparam/test-mhparam b/test/tests/mhparam/test-mhparam index c2fc5dec..7f21be3a 100755 --- a/test/tests/mhparam/test-mhparam +++ b/test/tests/mhparam/test-mhparam @@ -120,10 +120,22 @@ runandcheck "mhparam -debug >/dev/null; echo \$?" <<! 0 ! +# check with folded header +cat >>"$MMHP" <<! +Alternate-Mailboxes: alice@example.org, + bob@example.net, + charly@example.comp +! +runandcheck 'mhparam alternate-mailboxes' <<! +alice@example.org, bob@example.net, charly@example.comp +! + + # check with text file that does not end with newline +# in mmh this is invalid printf 'Editor: emacs' >>"$MMHP" runandcheck 'mhparam -nocomponent editor' <<! -emacs +mhparam: `cat test-temp-dir`/.mmh/profile2 is poorly formatted !