Remove building with NOCRYPTO option
[minix.git] / external / bsd / bind / dist / bin / tests / system / additional / tests.sh
blob7dd79fcfcec10d5868c97d88b3d4701f80a557b1
1 #!/bin/sh
3 # Copyright (C) 2013 Internet Systems Consortium, Inc. ("ISC")
5 # Permission to use, copy, modify, and/or distribute this software for any
6 # purpose with or without fee is hereby granted, provided that the above
7 # copyright notice and this permission notice appear in all copies.
9 # THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
10 # REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
11 # AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
12 # INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
13 # LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
14 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
15 # PERFORMANCE OF THIS SOFTWARE.
17 # Id: tests.sh,v 1.7 2011/11/06 23:46:40 tbox Exp
19 SYSTEMTESTTOP=..
20 . $SYSTEMTESTTOP/conf.sh
22 status=0
23 n=0
25 dotests() {
26 n=`expr $n + 1`
27 echo "I:test with RT, single zone ($n)"
28 ret=0
29 $DIG -t RT rt.rt.example @10.53.0.1 -p 5300 > dig.out.$n || ret=1
30 if [ $ret -eq 1 ] ; then
31 echo "I: failed"; status=1
34 n=`expr $n + 1`
35 echo "I:test with RT, two zones ($n)"
36 ret=0
37 $DIG -t RT rt.rt2.example @10.53.0.1 -p 5300 > dig.out.$n || ret=1
38 if [ $ret -eq 1 ] ; then
39 echo "I: failed"; status=1
42 n=`expr $n + 1`
43 echo "I:test with NAPTR, single zone ($n)"
44 ret=0
45 $DIG -t NAPTR nap.naptr.example @10.53.0.1 -p 5300 > dig.out.$n || ret=1
46 if [ $ret -eq 1 ] ; then
47 echo "I: failed"; status=1
50 n=`expr $n + 1`
51 echo "I:test with NAPTR, two zones ($n)"
52 ret=0
53 $DIG -t NAPTR nap.hang3b.example @10.53.0.1 -p 5300 > dig.out.$n || ret=1
54 if [ $ret -eq 1 ] ; then
55 echo "I: failed"; status=1
58 n=`expr $n + 1`
59 echo "I:test with LP ($n)"
60 ret=0
61 $DIG -t LP nid2.nid.example @10.53.0.1 -p 5300 > dig.out.$n || ret=1
62 if [ $minimal = no ] ; then
63 grep "L64" dig.out.$n > /dev/null || ret=1
64 grep "L32" dig.out.$n > /dev/null || ret=1
65 else
66 grep "L64" dig.out.$n > /dev/null && ret=1
67 grep "L32" dig.out.$n > /dev/null && ret=1
69 if [ $ret -eq 1 ] ; then
70 echo "I: failed"; status=1
73 n=`expr $n + 1`
74 echo "I:test with NID ($n)"
75 ret=0
76 $DIG -t NID ns1.nid.example @10.53.0.1 -p 5300 > dig.out.$n || ret=1
77 if [ $minimal = no ] ; then
78 # change && to || when we support NID additional processing
79 grep "L64" dig.out.$n > /dev/null && ret=1
80 grep "L32" dig.out.$n > /dev/null && ret=1
81 else
82 grep "L64" dig.out.$n > /dev/null && ret=1
83 grep "L32" dig.out.$n > /dev/null && ret=1
85 if [ $ret -eq 1 ] ; then
86 echo "I: failed"; status=1
89 n=`expr $n + 1`
90 echo "I:test with NID + LP ($n)"
91 ret=0
92 $DIG -t NID nid2.nid.example @10.53.0.1 -p 5300 > dig.out.$n || ret=1
93 if [ $minimal = no ] ; then
94 # change && to || when we support NID additional processing
95 grep "LP" dig.out.$n > /dev/null && ret=1
96 grep "L64" dig.out.$n > /dev/null && ret=1
97 grep "L32" dig.out.$n > /dev/null && ret=1
98 else
99 grep "LP" dig.out.$n > /dev/null && ret=1
100 grep "L64" dig.out.$n > /dev/null && ret=1
101 grep "L32" dig.out.$n > /dev/null && ret=1
103 if [ $ret -eq 1 ] ; then
104 echo "I: failed"; status=1
108 echo "I:testing with 'minimal-responses yes;'"
109 minimal=yes
110 dotests
112 echo "I:reconfiguring server"
113 cp ns1/named2.conf ns1/named.conf
114 $RNDC -c ../common/rndc.conf -s 10.53.0.1 -p 9953 reconfig 2>&1 | sed 's/^/I:ns1 /'
115 sleep 2
117 echo "I:testing with 'minimal-responses no;'"
118 minimal=no
119 dotests
121 exit $status