X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/d722ee2a5489b9cfcb28903d8b564863099917bf..b43e55a89e0fd66e1bf968fed25feacfbd045514:/test/mhfixmsg/test-mhfixmsg diff --git a/test/mhfixmsg/test-mhfixmsg b/test/mhfixmsg/test-mhfixmsg index 6536029f..d60b9d76 100755 --- a/test/mhfixmsg/test-mhfixmsg +++ b/test/mhfixmsg/test-mhfixmsg @@ -22,7 +22,6 @@ actual_err="$MH_TEST_DIR/test-mhfixmsg$$.actual_err" #### Make sure that html-to-text conversion is what we expect. LC_ALL=en_US.UTF-8; export LC_ALL -set +e if grep mhfixmsg-format-text/html "${MH_TEST_DIR}/Mail/mhn.defaults" \ >/dev/null; then can_reformat_texthtml=1 @@ -39,7 +38,6 @@ else echo "$0: skipping -reformat check because no text browser was found" can_reformat_texthtml=0 fi -set -e # check -help @@ -49,7 +47,7 @@ Usage: mhfixmsg [+folder] [msgs] [switches] switches are: -decodetext 8bit|7bit -nodecodetext - -[no]textcodeset + -[no]textcharset -[no]reformat -[no]replacetextplain -[no]fixboundary @@ -569,7 +567,7 @@ MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----- =_aaaaaaaaaa0" ------- =_aaaaaaaaaa0 -Content-Type: text/plain; charset="iso-8859-1"; name="square.txt" +Content-Type: text/plain; charset="iso-8859-1"; name="nul+square.txt" Content-Transfer-Encoding: base64 AL2yPbwK @@ -578,9 +576,7 @@ AL2yPbwK EOF cp -p `mhpath last` "$expected" -set +e run_prog mhfixmsg last -set -e check `mhpath last` "$expected" 'keep first' @@ -592,7 +588,7 @@ MIME-Version: 1.0 Content-Type: multipart/mixed; boundary=\"----- =_aaaaaaaaaa0\" ------- =_aaaaaaaaaa0 -Content-Type: text/plain; charset=\"iso-8859-1\"; name=\"square.txt\" +Content-Type: text/plain; charset=\"iso-8859-1\"; name=\"nul+square.txt\" Content-Transfer-Encoding: binary " " @@ -678,13 +674,13 @@ else fi -# check -textcodeset +# check -textcharset # Also checks preservation of attributes after one (charset) that is # modified. cat >"$expected" <`mhpath new` <"$actual.err" -if grep "mhfixmsg: Can't convert .* to .* without iconv" "$actual.err" \ - >/dev/null; then - echo "$0: skipping -textcodeset check because nmh was built without iconv" - rm -f "$expected" "$actual" "$actual.err" -else +if test "$ICONV_ENABLED" -eq 1; then + run_prog mhfixmsg last -textcharset utf-8 -outfile "$actual" 2>&1 check "$expected" "$actual" - rm "$actual.err" +else + echo "$0: skipping -textcharset check because nmh was built without iconv" + rm -f "$expected" fi -set -e # check -nofixboundary @@ -778,7 +770,7 @@ fi cat >"$expected" <