]> git.ipfire.org Git - thirdparty/pdns.git/blame - regression-tests/cleandig
Merge pull request #7529 from rgacogne/auth-clear-metadata-on-delete
[thirdparty/pdns.git] / regression-tests / cleandig
CommitLineData
d4886eb4 1#!/bin/sh
7e47805b
AG
2
3set -e
4which drill >/dev/null 2>/dev/null || (echo "missing drill tool" >&2; exit 1)
5which unbound-host >/dev/null 2>/dev/null || (echo "missing unbound-host tool" >&2; exit 1)
6set +e
7
7b8f4fc1 8if [ ! -e ${testsdir}/${testname}/use.drill ]
b5baefaf 9then
df82962d
KM
10 if [ "$2" != "AXFR" ]
11 then
a3dc491e 12 $SDIG $nameserver $port "$1" $2 $3 $4 $5 $6 $7 $8 $9 | LC_ALL=C sort
df82962d 13 else
d9c6538e 14 $SAXFR $nameserver $port "$1" $3 $4 | LC_ALL=C sort
df82962d 15 fi
e564ae3f 16fi
d9c6538e 17$NSEC3DIG $nameserver $port "$1" $2 > ${testsdir}/${testname}/nsec3dig.out 2>&1
e564ae3f
KM
18if [ ! -e ${testsdir}/${testname}/skip-drill ]
19then
12ccb5fd
KM
20 if [ ! -s trustedkeys ]
21 then
22 drill -a -p $port -o rd -D "$1" $2 @$nameserver > ${testsdir}/${testname}/drill.out 2>&1
23 echo RETVAL: $? >> ${testsdir}/${testname}/drill.out
24 else
25 drill -a -p $port -o rd -D -S -k trustedkeys "$1" $2 @$nameserver > ${testsdir}/${testname}/drillchase.out 2>&1
26 echo RETVAL: $? >> ${testsdir}/${testname}/drillchase.out
27 drill -a -p $port -o rd -D -k trustedkeys "$1" $2 @$nameserver > ${testsdir}/${testname}/drill.out 2>&1
28 echo RETVAL: $? >> ${testsdir}/${testname}/drill.out
29 fi
b5baefaf 30fi
4a9b70ec
PD
31if [ ! -e ${testsdir}/${testname}/skip-q ]
32then
51332c0e 33 /usr/lib/go/bin/q -tcp=true -short=true -rd=false -check -dnssec -port=$port @$nameserver $2 "$1" > ${testsdir}/${testname}/q.out 2>&1
4a9b70ec
PD
34 echo RETVAL: $? >> ${testsdir}/${testname}/q.out
35fi
eb73d9ad 36if [ ! -e ${testsdir}/${testname}/skip-unboundhost ]
b9147125 37then
51332c0e 38 unbound-host -v -C unbound-host.conf -t $2 "$1" > ${testsdir}/${testname}/unbound-host.out 2>&1
eb73d9ad 39 echo RETVAL: $? >> ${testsdir}/${testname}/unbound-host.out
4f357152 40fi
7b8f4fc1 41if [ -e ${testsdir}/${testname}/use.drill ]
b5baefaf 42then
388cdf7a 43 cat ${testsdir}/${testname}/drill.out | sed 's/ ;.*//'
b5baefaf 44fi
e1867286 45grep -iw bogus ${testsdir}/${testname}/*.out