Sync usage with man page.
[netbsd-mini2440.git] / external / bsd / bind / dist / bin / tests / system / v6synth / tests.sh
blobbbc9b896f75f52ec01c9e7101eaf478aea7845b1
1 #!/bin/sh
3 # Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC")
4 # Copyright (C) 2001 Internet Software Consortium.
6 # Permission to use, copy, modify, and/or distribute this software for any
7 # purpose with or without fee is hereby granted, provided that the above
8 # copyright notice and this permission notice appear in all copies.
10 # THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
11 # REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
12 # AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
13 # INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
14 # LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
15 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
16 # PERFORMANCE OF THIS SOFTWARE.
18 # Id: tests.sh,v 1.4 2007/06/19 23:47:06 tbox Exp
20 SYSTEMTESTTOP=..
21 . $SYSTEMTESTTOP/conf.sh
23 # ns1 = root server
24 # ns2 = authoritative server
25 # ns3 = recursive server doing v6 synthesis
27 status=0
29 DIGOPTS="+tcp +noadd +nosea +nostat +noquest +nocomm +nocmd"
31 for name in aaaa a6 chain alias2 aaaa.dname loop loop2
33 $DIG $DIGOPTS $name.example. aaaa @10.53.0.3 -p 5300
34 echo
35 done >dig.out
37 for i in 1 2
39 $DIG $DIGOPTS f.f.$i.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.6.5.4.3.2.1.ip6.int. PTR @10.53.0.3 -p 5300
40 echo
41 done >>dig.out
43 cat <<EOF >good.out
44 aaaa.example. 0 IN AAAA 12:34:56::ff
46 a6.example. 0 IN AAAA 12:34:56::ff
48 chain.example. 0 IN AAAA 12:34:56::ff:ff
50 alias2.example. 0 IN CNAME alias.example.
51 alias.example. 0 IN CNAME chain.example.
52 chain.example. 0 IN AAAA 12:34:56::ff:ff
54 aaaa.dname.example. 0 IN CNAME aaaa.foo.example.
55 aaaa.foo.example. 0 IN AAAA 12:34:56::ff
57 loop.example. 0 IN CNAME loop.example.
59 loop2.example. 0 IN CNAME loop3.example.
60 loop3.example. 0 IN CNAME loop2.example.
62 f.f.1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.6.5.4.3.2.1.ip6.int. 0 IN PTR foo.
64 f.f.2.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.6.5.4.3.2.1.ip6.int. 0 IN PTR bar.
66 EOF
68 diff good.out dig.out || status=1
70 echo "I:exit status: $status"
71 exit $status