-# The command will wait for the user to hit return. script seems to do what
-# we want by not waiting when run in the background.
-script -c 'mhparam path last' -f -q "$actual" >/dev/null &
-wait $!
-grep 'Welcome to nmh version ' "$actual" >/dev/null && false
-rm "$actual"
-finish_test
+run_without_input "${actual}" mhparam path
+grep 'Welcome to nmh version ' "${actual}" >/dev/null && false
+# Make sure that version wasn't added to context.
+grep "^${version}$" "${MH_TEST_DIR}/Mail/context" >/dev/null && false
+rm "${actual}"
+
+
+start_test 'Welcome: disable in profile skips the welcome message'
+cp "${MH}" "${MH}-welcome"
+printf 'Welcome: disable\n' >> "${MH}-welcome"
+# Run the function in subshell instead of augmenting the environment
+# for a single command, so that the environment does not retain the
+# MH setting. That can happen when run under distcheck, depending
+# on the user's shell.
+(MH="${MH}-welcome"; run_without_input "${actual}" pick last)
+rm "${MH}-welcome"
+grep 'Welcome to nmh version ' "${actual}" >/dev/null && false
+# Make sure that version wasn't added to context.
+grep "^${version}$" "${MH_TEST_DIR}/Mail/context" >/dev/null && false
+rm "${actual}"