]> diplodocus.org Git - nmh/blobdiff - test/common.sh.in
In InitMultiPart(), always set bogus_mp_content if boundaries
[nmh] / test / common.sh.in
index b791a7f04be7357f9aab58bf627172ffa4d36647..2264d469dd304ede3b58a6ce6e065b50da5bc1a1 100644 (file)
@@ -21,9 +21,13 @@ export MULTIBYTE_ENABLED ICONV_ENABLED
 test -z "$MH_INST_DIR"  &&  MH_INST_DIR="${MH_TEST_DIR}/inst"
 export MH_INST_DIR
 
 test -z "$MH_INST_DIR"  &&  MH_INST_DIR="${MH_TEST_DIR}/inst"
 export MH_INST_DIR
 
-unset MHBUILD MHCONTEXT MHMTSUSERCONF MHN MHSHOW MHSTORE MHTMPDIR
+unset MHBUILD MHCONTEXT MHMTSUSERCONF MHN MHSHOW MHSTORE
 unset MHLDEBUG MHPDEBUG MHWDEBUG MM_CHARSET PAGER
 
 unset MHLDEBUG MHPDEBUG MHWDEBUG MM_CHARSET PAGER
 
+#### Use a test dir for tmp files when MHTMPDIR applies.
+MHTMPDIR=$MH_TEST_DIR/Mail
+export MHTMPDIR
+
 output_md5()
 {
   #### Output just the checksum.  If the filename needs to appear on
 output_md5()
 {
   #### Output just the checksum.  If the filename needs to appear on
@@ -90,7 +94,7 @@ if [ -t 1 ] ; then
     # note \r so next update will overwrite
     printf '%3d%%\r' $PERC
   }
     # note \r so next update will overwrite
     printf '%3d%%\r' $PERC
   }
-  
+
   progress_done ()
   {
     printf '100%%\n'
   progress_done ()
   {
     printf '100%%\n'
@@ -163,9 +167,8 @@ setup_test ()
 {
   MH="${MH_TEST_DIR}/Mail/.mh_profile"
   MHMTSCONF="${MH_INST_DIR}${sysconfdir}/mts.conf"
 {
   MH="${MH_TEST_DIR}/Mail/.mh_profile"
   MHMTSCONF="${MH_INST_DIR}${sysconfdir}/mts.conf"
-  PATH="${MH_INST_DIR}${bindir}:${PATH}"
   MH_LIB_DIR="${MH_INST_DIR}${auxexecdir}"
   MH_LIB_DIR="${MH_INST_DIR}${auxexecdir}"
-  export MH MHMTSCONF MH_LIB_DIR PATH
+  export MH MHMTSCONF MH_LIB_DIR
 
   #
   # Only install once
 
   #
   # Only install once
@@ -190,6 +193,10 @@ setup_test ()
         "${MHMTSCONF}.old" >"${MHMTSCONF}"
   fi
 
         "${MHMTSCONF}.old" >"${MHMTSCONF}"
   fi
 
+  #### On Solaris, must set PATH after the install!
+  PATH="${MH_INST_DIR}${bindir}:${PATH}"
+  export PATH
+
   # clean old test data
   trap "rm -rf '$MH_TEST_DIR/Mail'" 0
   # setup test data
   # clean old test data
   trap "rm -rf '$MH_TEST_DIR/Mail'" 0
   # setup test data
@@ -215,7 +222,7 @@ EOF
     cp "${MH_INST_DIR}${sysconfdir}/${f}" "${MH_TEST_DIR}/Mail" || exit 1
   done
 
     cp "${MH_INST_DIR}${sysconfdir}/${f}" "${MH_TEST_DIR}/Mail" || exit 1
   done
 
-  $MH_TEST_DIR/inst/$prefix/bin/folder -create +inbox > /dev/null
+  folder -create +inbox > /dev/null
   # create 10 basic messages
   for i in 1 2 3 4 5 6 7 8 9 10;
   do
   # create 10 basic messages
   for i in 1 2 3 4 5 6 7 8 9 10;
   do