X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/4c9ad9f4f44521d7eae9ea1e8277cf7f8b577d20..213e031dda6a34c50c04de0d6041f45ab2db0a91:/test/install-mh/test-install-mh?ds=sidebyside diff --git a/test/install-mh/test-install-mh b/test/install-mh/test-install-mh index 5a939617..45a9e2b6 100755 --- a/test/install-mh/test-install-mh +++ b/test/install-mh/test-install-mh @@ -16,6 +16,8 @@ fi setup_test +check_exit '-eq 1' install-mh - + # check with no options, with nmh already installed run_test "install-mh" \ 'install-mh: You already have an nmh profile, use an editor to modify it' @@ -26,7 +28,7 @@ run_test "install-mh -auto" 'install-mh: invocation error' # check -check, with nmh already installed run_test "install-mh -check" '' # make sure exit status is 0 -install-mh -check +run_prog install-mh -check run_test "echo $?" '0' # Remove the nmh installation so that install-mh can install. @@ -36,7 +38,7 @@ rm -rf $MH_TEST_DIR/Mail run_test "install-mh -check" '' # make sure exit status is 1 set +e -install-mh -check +run_prog install-mh -check run_test "echo $?" '1' set -e @@ -47,10 +49,10 @@ echo "n n n $installpath -y" | install-mh >/dev/null +y" | run_prog install-mh >/dev/null -if [ -f $MH_TEST_DIR/Mail/context -a -f $MH_TEST_DIR/Mail/.mh_profile ]; then - install-mh -check +if [ -f $MH_TEST_DIR/Mail/context -a -f "$MH" ]; then + run_prog install-mh -check else failed=`expr ${failed:-0} + 1` fi @@ -61,8 +63,8 @@ fi rm -rf $MH_TEST_DIR/Mail HOME=$MH_TEST_DIR install-mh -auto >/dev/null -if [ -f $MH_TEST_DIR/Mail/context -a -f $MH_TEST_DIR/Mail/.mh_profile ]; then - install-mh -check +if [ -f $MH_TEST_DIR/Mail/context -a -f "$MH" ]; then + run_prog install-mh -check else failed=`expr ${failed:-0} + 1` fi