masqmail-0.2

annotate tests/relay-to-hostname-mta/test.tpl @ 63:49ca781e1503

reworked the test cases completely they are split into four independent tests now and each one is tested to work with the current version
author meillo@marmaro.de
date Sun, 30 May 2010 16:05:49 +0200
parents
children 0379789a847b
rev   line source
meillo@63 1 #! /bin/bash
meillo@63 2
meillo@63 3 # should be run from within tests dir set if you move this:
meillo@63 4 mm_bin=../../src/masqmail
meillo@63 5
meillo@63 6 hfrom="\"Fritz Meier\" <`logname`@RECV_HOST>"
meillo@63 7 hto="$hfrom"
meillo@63 8 to=`logname`@RECV_HOST
meillo@63 9 hsubject="MasqMail stdin Test"
meillo@63 10
meillo@63 11
meillo@63 12 # Testing with rcpt on cmd line
meillo@63 13 # (dot does end)
meillo@63 14 #
meillo@63 15 # the command to be run:
meillo@63 16 cmd="$mm_bin -C ./test.conf $to"
meillo@63 17
meillo@63 18 $cmd <<EOF
meillo@63 19 From: $hfrom
meillo@63 20 To: $hto
meillo@63 21 Subject: $hsubject
meillo@63 22
meillo@63 23 Hallo Fritz!
meillo@63 24
meillo@63 25 ..
meillo@63 26 there is a dot above (Yes, one and not two).
meillo@63 27
meillo@63 28 command was: $cmd
meillo@63 29
meillo@63 30 Fritz
meillo@63 31 .
meillo@63 32
meillo@63 33 EOF
meillo@63 34
meillo@63 35 #
meillo@63 36 # Testing with rcpt on cmd line with -oi option
meillo@63 37 # (dot does not end)
meillo@63 38 #
meillo@63 39 # the command to be run:
meillo@63 40 cmd="$mm_bin -C ./test.conf -oi $to"
meillo@63 41
meillo@63 42 $cmd <<EOF
meillo@63 43 From: $hfrom
meillo@63 44 To: $hto
meillo@63 45 Subject: $hsubject
meillo@63 46
meillo@63 47 Hallo Fritz!
meillo@63 48 .
meillo@63 49 there is a dot above.
meillo@63 50
meillo@63 51 command was: $cmd
meillo@63 52
meillo@63 53 Fritz
meillo@63 54
meillo@63 55 EOF
meillo@63 56
meillo@63 57 #
meillo@63 58 # Testing with rcpt read from headers (-t option)
meillo@63 59 # (dot does end)
meillo@63 60 #
meillo@63 61 # the command to be run:
meillo@63 62 cmd="$mm_bin -C ./test.conf -t"
meillo@63 63
meillo@63 64 $cmd <<EOF
meillo@63 65 From: $hfrom
meillo@63 66 To: $hto
meillo@63 67 Subject: $hsubject
meillo@63 68
meillo@63 69 Hallo Fritz!
meillo@63 70 ..
meillo@63 71 there is a dot above.
meillo@63 72
meillo@63 73 command was: $cmd
meillo@63 74
meillo@63 75 Fritz
meillo@63 76 .
meillo@63 77
meillo@63 78 EOF