diff options
Diffstat (limited to 'adns-0.6/regress/m1test')
-rwxr-xr-x | adns-0.6/regress/m1test | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/adns-0.6/regress/m1test b/adns-0.6/regress/m1test new file mode 100755 index 0000000..dbd6bc5 --- /dev/null +++ b/adns-0.6/regress/m1test @@ -0,0 +1,38 @@ +#!/bin/sh + +set -e + +if [ $# -lt 3 ] +then + echo >&2 'usage: m1test <name> <initfile> [<initflags>] <queryargs>' + exit 1 +fi + +case="case-$1"; shift +initfile="$1"; shift + +case "$1" in +-*) initflags="$1"; shift +esac + +queryargs="$*" + +initstring="`cat init-$initfile.text`" + +echo $initfile $initflags >"$case.sys" +echo "$queryargs" >>"$case.sys" + +EF_DISABLE_BANNER=1 +export EF_DISABLE_BANNER + +echo running hrecord $initflags "/... $queryargs" +set +e +ADNS_TEST_OUT_FD=3 3>>"$case.sys" >"$case.out" 2>"$case.err" </dev/null \ + ./hrecord $initflags "/$initstring" $queryargs +rc=$? +set -e + +echo "rc=$rc" >>$case.out + +egrep . -- "$case.err" "$case.out" +echo "exit status: $rc" |