diff tests/test.templ @ 0:08114f7dcc23 0.2.21

this is masqmail-0.2.21 from oliver kurth
author meillo@marmaro.de
date Fri, 26 Sep 2008 17:05:23 +0200
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test.templ	Fri Sep 26 17:05:23 2008 +0200
@@ -0,0 +1,81 @@
+#! /bin/bash
+
+# should be run from within tests dir
+# set if you move this:
+mm_src_dir=../src
+mm_bin=$mm_src_dir/masqmail
+
+#
+hfrom="\"Fritz Meier\" <`logname`@RECV_HOST>"
+hto=$hfrom
+to=`logname`@RECV_HOST
+hsubject="MasqMail stdin Test"
+
+#
+# Testing with rcpt on cmd line
+# (dot does end)
+#
+# the command to be run:
+cmd="$mm_bin -C ./test.conf $to"
+
+$cmd <<EOF
+From: $hfrom
+To: $hto
+Subject: $hsubject
+
+Hallo Fritz!
+
+..
+there is a dot above (Yes, one and not two).
+
+command was: $cmd
+
+Fritz
+.
+
+EOF
+
+#
+# Testing with rcpt on cmd line with -oi option
+# (dot does not end)
+#
+# the command to be run:
+cmd="$mm_bin -C ./test.conf -oi $to"
+
+$cmd <<EOF
+From: $hfrom
+To: $hto
+Subject: $hsubject
+
+Hallo Fritz!
+.
+there is a dot above.
+
+command was: $cmd
+
+Fritz
+
+EOF
+
+#
+# Testing with rcpt read from headers (-t option)
+# (dot does end)
+#
+# the command to be run:
+cmd="$mm_bin -C ./test.conf -t"
+
+$cmd <<EOF
+From: $hfrom
+To: $hto
+Subject: $hsubject
+
+Hallo Fritz!
+..
+there is a dot above.
+
+command was: $cmd
+
+Fritz
+.
+
+EOF