]> diplodocus.org Git - nmh/blobdiff - test/mhfixmsg/test-mhfixmsg
Remove SYNOPSIS from nmh(7).
[nmh] / test / mhfixmsg / test-mhfixmsg
index 10ac24ec2978fcb0d954b9559bc58b6642a0d06f..3bffa9a8be06e75e3189adb01c4092c3873be658 100755 (executable)
@@ -666,9 +666,14 @@ d><td align=3D"right"><font face=3D"Arial, Helvetica, sans-serif" color=3D"=
 </html>
 EOF
 
-#### lynx inserts multiple blank lines, so use uniq to squeeze them.
-mhfixmsg last -outfile - | uniq >"$actual"
-check "$expected" "$actual" 'ignore space'
+if [ $can_reformat_texthtml -eq 1 ]; then
+  #### lynx inserts multiple blank lines, so use uniq to squeeze them.
+  mhfixmsg last -outfile - | uniq >"$actual"
+  check "$expected" "$actual" 'ignore space'
+else
+  cp -p "$MH_TEST_DIR/Mail/inbox/15" "$MH_TEST_DIR/Mail/inbox/15.backup"
+  rm -f "$expected"
+fi
 
 
 # check -textcodeset
@@ -869,6 +874,7 @@ else
   rm -f "$expected"
 fi
 
+
 # check handling of rfc822 message type
 cat >"$expected" <<EOF
 From: Test <test@example.com>
@@ -932,6 +938,33 @@ run_test 'mhfixmsg last -outfile '"$actual" ''
 check "$expected" "$actual"
 
 
+# check stripping of CRs from ASCII text context
+cat >"$expected" <<EOF
+MIME-Version: 1.0
+From: sender@example.com
+To: recipient@example.com
+Subject: message with CR's
+Date: Mon, 29 Apr 2013 11:51:45 -0400
+
+There are two CR-LF pairs at the end of this sentence.
+
+EOF
+
+cat >`mhpath new` <<'EOF'
+MIME-Version: 1.0
+From: sender@example.com
+To: recipient@example.com
+Subject: message with CR's
+Date: Mon, 29 Apr 2013 11:51:45 -0400
+
+There are two CR-LF pairs at the end of this sentence.\r
+\r
+EOF
+
+mhfixmsg last -outfile "$actual"
+check "$expected" "$actual"
+
+
 # check rmmproc
 cat >"$MH_TEST_DIR/Mail/rmmproc" <<'EOF'
 mv "$1" "$1.backup"