]> diplodocus.org Git - nmh/blobdiff - test/common.sh.in
Finished replacing mh_strcasecmp() with strcasecmp(). Removed
[nmh] / test / common.sh.in
index b791a7f04be7357f9aab58bf627172ffa4d36647..1f52004aae3c59b245d0312dedd53b28203a91c5 100644 (file)
@@ -13,6 +13,7 @@ test -z "$auxexecdir"  &&  auxexecdir="@libdir@"
 test -z "$bindir"  &&  bindir="@bindir@"
 test -z "$mandir"  &&  mandir="@mandir@"
 test -z "$sysconfdir"  &&  sysconfdir="@sysconfdir@"
+test -z "$supported_locks"  &&  supported_locks="@supported_locks@"
 test -z "$MULTIBYTE_ENABLED"  &&  MULTIBYTE_ENABLED="@MULTIBYTE_ENABLED@"
 test -z "$ICONV_ENABLED"  &&  ICONV_ENABLED="@ICONV_ENABLED@"
 export MH_TEST_DIR auxexecdir bindir mandir sysconfdir
@@ -21,9 +22,13 @@ export MULTIBYTE_ENABLED ICONV_ENABLED
 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
 
+#### 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
@@ -90,7 +95,7 @@ if [ -t 1 ] ; then
     # note \r so next update will overwrite
     printf '%3d%%\r' $PERC
   }
-  
+
   progress_done ()
   {
     printf '100%%\n'
@@ -163,9 +168,8 @@ setup_test ()
 {
   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}"
-  export MH MHMTSCONF MH_LIB_DIR PATH
+  export MH MHMTSCONF MH_LIB_DIR
 
   #
   # Only install once
@@ -190,6 +194,10 @@ setup_test ()
         "${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
@@ -215,7 +223,7 @@ EOF
     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