mail2.0 revision 213738
1203576Sjilles# $FreeBSD: head/tools/regression/bin/sh/parameters/mail2.0 213738 2010-10-12 18:20:38Z obrien $ 2203576Sjilles# Test that an interactive shell accesses $MAIL. 3203576Sjilles 4203576Sjillesgoodfile=/var/empty/sh-test-goodfile 5203576Sjillesmailfile=/var/empty/sh-test-mailfile 6203576SjillesT=$(mktemp sh-test.XXXXXX) || exit 7213738SobrienENV=$goodfile MAIL=$mailfile ktrace -i -f "$T" ${SH} +m -i </dev/null >/dev/null 2>&1 8203576Sjillesif ! grep -q $goodfile "$T"; then 9203576Sjilles # ktrace problem 10203576Sjilles rc=0 11203576Sjilleselif grep -q $mailfile "$T"; then 12203576Sjilles rc=0 13203576Sjillesfi 14203576Sjillesrm "$T" 15203576Sjillesexit ${rc:-3} 16