+if [ "$readline" = 0 ]; then
+cat >"$expected" <<EOF
+whatnow: attach command requires file argument(s).
+whatnow: attach command requires file argument(s).
+Attaching ${MH_TEST_DIR}/Mail/context as a text/plain
+EOF
+else
+cat >"$expected" <<EOF
+at
+whatnow: attach command requires file argument(s).
+at -v
+whatnow: attach command requires file argument(s).
+at -v Mail/context
+Attaching ${MH_TEST_DIR}/Mail/context as a text/plain
+quit -delete
+EOF
+fi
+
+printf '%s\n' \
+ 'at' \
+ 'at -v' \
+ 'at -v Mail/context' \
+ 'quit -delete' | whatnow -prompt '' 2>&1 | \
+ sed -e 's/; charset=us-ascii//' >"$actual"
+
+check "$expected" "$actual"
+