]> diplodocus.org Git - nmh/blobdiff - test/mhbuild/test-header-encode
Replace getcpy() with mh_xstrdup() where the string isn't NULL.
[nmh] / test / mhbuild / test-header-encode
index 5bb08a6da8016556b73f9bec5e6b064dc37b085f..6459bf2a03227f95963b720655964ee8850d71fb 100755 (executable)
@@ -16,13 +16,12 @@ fi
 
 setup_test
 testname="${MH_TEST_DIR}/$$"
 
 setup_test
 testname="${MH_TEST_DIR}/$$"
-backupname="${MH_TEST_DIR}/,$$"
+backupname="${MH_TEST_DIR}/`mhparam sbackup`$$"
 
 #
 # We're going to hardcode UTF-8 for this test.
 #
 
 #
 # We're going to hardcode UTF-8 for this test.
 #
-
-LC_ALL=en_US.UTF-8; export LC_ALL
+require_locale en_US.UTF-8 en_US.UTF8 en_US.utf-8 en_US.utf8
 
 #
 # Basic test of encoding a short subject
 
 #
 # Basic test of encoding a short subject
@@ -45,7 +44,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is a test
 EOF
 
 This is a test
 EOF
 
-mhbuild "${testname}.basic.actual"
+run_prog mhbuild "${testname}.basic.actual"
 
 check "${testname}.basic.actual" "${testname}.basic.expected" 'keep first'
 
 
 check "${testname}.basic.actual" "${testname}.basic.expected" 'keep first'
 
@@ -78,7 +77,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is a test
 EOF
 
 This is a test
 EOF
 
-mhbuild -headerencoding base64 "${testname}.basic.actual"
+run_prog mhbuild -headerencoding base64 "${testname}.basic.actual"
 
 check "${testname}.basic.actual" "${testname}.basic.expected" 'keep first'
 
 
 check "${testname}.basic.actual" "${testname}.basic.expected" 'keep first'
 
@@ -108,7 +107,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is a test
 EOF
 
 This is a test
 EOF
 
-mhbuild "${testname}.autopick.actual"
+run_prog mhbuild "${testname}.autopick.actual"
 
 check "${testname}.autopick.actual" "${testname}.autopick.expected" 'keep first'
 
 
 check "${testname}.autopick.actual" "${testname}.autopick.expected" 'keep first'
 
@@ -143,7 +142,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is a test of a very long subject line.
 EOF
 
 This is a test of a very long subject line.
 EOF
 
-mhbuild "${testname}.longsubject1.actual"
+run_prog mhbuild "${testname}.longsubject1.actual"
 
 check "${testname}.longsubject1.actual" "${testname}.longsubject1.expected" 'keep first'
 
 
 check "${testname}.longsubject1.actual" "${testname}.longsubject1.expected" 'keep first'
 
@@ -179,7 +178,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is a test of a very long subject line using base64.
 EOF
 
 This is a test of a very long subject line using base64.
 EOF
 
-mhbuild "${testname}.longsubject2.actual"
+run_prog mhbuild "${testname}.longsubject2.actual"
 
 check "${testname}.longsubject2.actual" "${testname}.longsubject2.expected" 'keep first'
 
 
 check "${testname}.longsubject2.actual" "${testname}.longsubject2.expected" 'keep first'
 
@@ -214,7 +213,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is another long test.
 EOF
 
 This is another long test.
 EOF
 
-mhbuild "${testname}.longsubject3.actual"
+run_prog mhbuild "${testname}.longsubject3.actual"
 
 check "${testname}.longsubject3.actual" "${testname}.longsubject3.expected" 'keep first'
 
 
 check "${testname}.longsubject3.actual" "${testname}.longsubject3.expected" 'keep first'
 
@@ -244,7 +243,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is another long test.
 EOF
 
 This is another long test.
 EOF
 
-mhbuild "${testname}.longsubject4.actual"
+run_prog mhbuild "${testname}.longsubject4.actual"
 
 check "${testname}.longsubject4.actual" "${testname}.longsubject4.expected" 'keep first'
 
 
 check "${testname}.longsubject4.actual" "${testname}.longsubject4.expected" 'keep first'
 
@@ -274,7 +273,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is important information
 EOF
 
 This is important information
 EOF
 
-mhbuild "${testname}.basicemail1.actual"
+run_prog mhbuild "${testname}.basicemail1.actual"
 
 check "${testname}.basicemail1.actual" "${testname}.basicemail1.expected" 'keep first'
 
 
 check "${testname}.basicemail1.actual" "${testname}.basicemail1.expected" 'keep first'
 
@@ -301,7 +300,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is important information
 EOF
 
 This is important information
 EOF
 
-mhbuild "${testname}.basicemail2.actual"
+run_prog mhbuild "${testname}.basicemail2.actual"
 
 check "${testname}.basicemail2.actual" "${testname}.basicemail2.expected" 'keep first'
 
 
 check "${testname}.basicemail2.actual" "${testname}.basicemail2.expected" 'keep first'
 
@@ -332,7 +331,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is important information
 EOF
 
 This is important information
 EOF
 
-mhbuild "${testname}.basicemail3.actual"
+run_prog mhbuild "${testname}.basicemail3.actual"
 
 check "${testname}.basicemail3.actual" "${testname}.basicemail3.expected" 'keep first'
 
 
 check "${testname}.basicemail3.actual" "${testname}.basicemail3.expected" 'keep first'
 
@@ -359,7 +358,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is important information
 EOF
 
 This is important information
 EOF
 
-mhbuild "${testname}.basicemail4.actual"
+run_prog mhbuild "${testname}.basicemail4.actual"
 
 check "${testname}.basicemail4.actual" "${testname}.basicemail4.expected" 'keep first'
 
 
 check "${testname}.basicemail4.actual" "${testname}.basicemail4.expected" 'keep first'
 
@@ -402,7 +401,7 @@ Content-Type: text/plain; charset="us-ascii"
 This is a lot of people on this email!
 EOF
 
 This is a lot of people on this email!
 EOF
 
-mhbuild "${testname}.complexemail1.actual"
+run_prog mhbuild "${testname}.complexemail1.actual"
 
 check "${testname}.complexemail1.actual" "${testname}.complexemail1.expected" 'keep first'
 
 
 check "${testname}.complexemail1.actual" "${testname}.complexemail1.expected" 'keep first'