summaryrefslogtreecommitdiff
path: root/comsat/tests/testsuite.at
diff options
context:
space:
mode:
Diffstat (limited to 'comsat/tests/testsuite.at')
-rw-r--r--comsat/tests/testsuite.at62
1 files changed, 15 insertions, 47 deletions
diff --git a/comsat/tests/testsuite.at b/comsat/tests/testsuite.at
index 45f3b1e46..db2dbd02f 100644
--- a/comsat/tests/testsuite.at
+++ b/comsat/tests/testsuite.at
@@ -25,3 +25,3 @@ dnl comsatcmd
m4_pushdef([comsatcmd],[comsatd --no-site-config --file ./biff.rc dnl
- --set logging.syslog=no --test])
+ --set logging.syslog=no --test=output])
@@ -36,4 +36,6 @@ AT_SETUP([comsatd: $1])
AT_KEYWORDS([comsatd $2])
+AT_CHECK([test -w / && AT_SKIP_TEST
+cwd=`pwd`
$3
-AT_CHECK([test -w / && AT_SKIP_TEST; $4],[0],[$5],[$6])
+],[0],[$4],[$5])
AT_CLEANUP])
@@ -47,12 +49,5 @@ MUT_VERSION(comsatd)
BIFFTEST([default commands],[comsatd00],
-[cwd=`pwd`
+[
MUT_MBCOPY($abs_top_srcdir/testsuite/spool/teaparty.mbox, mailbox)
-cat > biff.rc <<EOT
-tty $cwd/output
-default
-EOT
-chmod 600 biff.rc
-> $cwd/output
-],
-[comsatcmd $cwd/mailbox 0
+comsatcmd $cwd/mailbox 0
sed '1s/^Mail to .*/Mail to test user/' output
@@ -71,12 +66,5 @@ Have some wine
BIFFTEST([non-zero qid],[comsatd01],
-[cwd=`pwd`
+[
MUT_MBCOPY($abs_top_srcdir/testsuite/spool/teaparty.mbox, mailbox)
-cat > biff.rc <<EOT
-tty $cwd/output
-default
-EOT
-chmod 600 biff.rc
-> $cwd/output
-],
-[comsatcmd $cwd/mailbox 9367
+comsatcmd $cwd/mailbox 9367
sed '1s/^Mail to .*/Mail to test user/' output
@@ -96,12 +84,5 @@ month, and doesn't tell what o'clock it is!
BIFFTEST([maildir qid],[comsatd02],
-[cwd=`pwd`
+[
MUT_MBCOPY($abs_top_srcdir/testsuite/maildir/teaparty, mailbox)
-cat > biff.rc <<EOT
-tty $cwd/output
-default
-EOT
-chmod 600 biff.rc
-> $cwd/output
-],
-[test "$MAILDIR_SUPPORT" = yes || AT_SKIP_TEST
+test "$MAILDIR_SUPPORT" = yes || AT_SKIP_TEST
comsatcmd maildir:$cwd/mailbox new/1284627340.M364969P3770Q81.Trurl
@@ -121,12 +102,5 @@ What did they draw?
BIFFTEST([MH qid],[comsatd03],
-[cwd=`pwd`
+[
MUT_MBCOPY($abs_top_srcdir/testsuite/mh/teaparty, mailbox)
-cat > biff.rc <<EOT
-tty $cwd/output
-default
-EOT
-chmod 600 biff.rc
-> $cwd/output
-],
-[test "$MH_SUPPORT" = yes || AT_SKIP_TEST
+test "$MH_SUPPORT" = yes || AT_SKIP_TEST
comsatcmd mh:$cwd/mailbox teaparty/58
@@ -146,6 +120,5 @@ I vote the young lady tells us a story.
BIFFTEST([beep command],[comsatd04],
-[cwd=`pwd`
+[
MUT_MBCOPY($abs_top_srcdir/testsuite/spool/mbox1, mailbox)
cat > biff.rc <<EOT
-tty $cwd/output
beep
@@ -153,5 +126,3 @@ EOT
chmod 600 biff.rc
-> $cwd/output
-],
-[comsatcmd $cwd/mailbox 0
+comsatcmd $cwd/mailbox 0
cat output | tr '\a' A
@@ -168,3 +139,2 @@ chmod +x notifier
cat > biff.rc <<EOT
-tty $cwd/output
exec $cwd/notifier '\$H{from}' '\$H{Subject}'
@@ -172,5 +142,3 @@ EOT
chmod 600 biff.rc
-> $cwd/output
-],
-[comsatcmd $cwd/mailbox 0
+comsatcmd $cwd/mailbox 0
cat output

Return to:

Send suggestions and report system problems to the System administrator.