if [ $ret != 0 ]; then echo_i "failed"; fi
status=$((status + ret))
+echo_i "Checking for 'zone has A records but is not served by IPv4 servers' warning ($n)"
+ret=0
+$CHECKZONE example zones/warn.no-a.server.db >test.out1.$n 2>&1 || ret=1
+grep "zone has A records but is not served by IPv4 servers" test.out1.$n >/dev/null || ret=1
+grep "zone has AAAA records but is not served by IPv6 servers" test.out1.$n >/dev/null && ret=1
+n=$((n + 1))
+if [ $ret != 0 ]; then echo_i "failed"; fi
+status=$((status + ret))
+
+echo_i "Checking for 'zone has AAAA records but is not served by IPv6 servers' warning ($n)"
+ret=0
+$CHECKZONE example zones/warn.no-aaaa.server.db >test.out1.$n 2>&1 || ret=1
+grep "zone has AAAA records but is not served by IPv6 servers" test.out1.$n >/dev/null || ret=1
+grep "zone has A records but is not served by IPv4 servers" test.out1.$n >/dev/null && ret=1
+n=$((n + 1))
+if [ $ret != 0 ]; then echo_i "failed"; fi
+status=$((status + ret))
+
+echo_i "Checking for 'zone has A records but is not served by IPv4 servers' warning for glue ($n)"
+ret=0
+$CHECKZONE example zones/warn.no-a.server.glue.db >test.out1.$n 2>&1 || ret=1
+grep "zone has A records but is not served by IPv4 servers" test.out1.$n >/dev/null || ret=1
+grep "zone has AAAA records but is not served by IPv6 servers" test.out1.$n >/dev/null && ret=1
+n=$((n + 1))
+if [ $ret != 0 ]; then echo_i "failed"; fi
+status=$((status + ret))
+
+echo_i "Checking for 'zone has AAAA records but is not served by IPv6 servers' warning for glue ($n)"
+ret=0
+$CHECKZONE example zones/warn.no-aaaa.server.glue.db >test.out1.$n 2>&1 || ret=1
+grep "zone has AAAA records but is not served by IPv6 servers" test.out1.$n >/dev/null || ret=1
+grep "zone has A records but is not served by IPv4 servers" test.out1.$n >/dev/null && ret=1
+n=$((n + 1))
+if [ $ret != 0 ]; then echo_i "failed"; fi
+status=$((status + ret))
+
echo_i "exit status: $status"
[ $status -eq 0 ] || exit 1
--- /dev/null
+; Copyright (C) Internet Systems Consortium, Inc. ("ISC")
+;
+; SPDX-License-Identifier: MPL-2.0
+;
+; This Source Code Form is subject to the terms of the Mozilla Public
+; License, v. 2.0. If a copy of the MPL was not distributed with this
+; file, you can obtain one at https://mozilla.org/MPL/2.0/.
+;
+; See the COPYRIGHT file distributed with this work for additional
+; information regarding copyright ownership.
+
+@ 30 IN SOA ns1 hostmaster 2017052201 3600 600 604800 30
+@ 7200 IN NS ns1
+@ 7200 IN NS ns2
+@ 7200 IN NS ns3
+@ 7200 IN NS ns4
+ns1 3600 IN AAAA fd92:7065:b8e:ffff::1
+ns2 3600 IN AAAA fd92:7065:b8e:ffff::2
+ns3 3600 IN AAAA fd92:7065:b8e:ffff::4
+ns4 3600 IN AAAA fd92:7065:b8e:ffff::4
+dualstack 300 IN AAAA 2001:db8::1
+dualstack 300 IN A 10.53.0.5
--- /dev/null
+; Copyright (C) Internet Systems Consortium, Inc. ("ISC")
+;
+; SPDX-License-Identifier: MPL-2.0
+;
+; This Source Code Form is subject to the terms of the Mozilla Public
+; License, v. 2.0. If a copy of the MPL was not distributed with this
+; file, you can obtain one at https://mozilla.org/MPL/2.0/.
+;
+; See the COPYRIGHT file distributed with this work for additional
+; information regarding copyright ownership.
+
+@ 30 IN SOA ns1 hostmaster 2017052201 3600 600 604800 30
+@ 7200 IN NS ns1
+@ 7200 IN NS ns2
+@ 7200 IN NS ns3
+@ 7200 IN NS ns4
+ns1 3600 IN AAAA fd92:7065:b8e:ffff::1
+ns2 3600 IN AAAA fd92:7065:b8e:ffff::2
+ns3 3600 IN AAAA fd92:7065:b8e:ffff::4
+ns4 3600 IN AAAA fd92:7065:b8e:ffff::4
+child 3600 IN NS ns1.child
+ns1.child 300 IN AAAA 2001:db8::1
+ns1.child 300 IN A 10.53.0.5
--- /dev/null
+; Copyright (C) Internet Systems Consortium, Inc. ("ISC")
+;
+; SPDX-License-Identifier: MPL-2.0
+;
+; This Source Code Form is subject to the terms of the Mozilla Public
+; License, v. 2.0. If a copy of the MPL was not distributed with this
+; file, you can obtain one at https://mozilla.org/MPL/2.0/.
+;
+; See the COPYRIGHT file distributed with this work for additional
+; information regarding copyright ownership.
+
+@ 30 IN SOA ns1 hostmaster 2017052201 3600 600 604800 30
+@ 7200 IN NS ns1
+@ 7200 IN NS ns2
+@ 7200 IN NS ns3
+@ 7200 IN NS ns4
+ns1 3600 IN A 10.53.0.1
+ns2 3600 IN A 10.53.0.2
+ns3 3600 IN A 10.53.0.4
+ns4 3600 IN A 10.53.0.4
+dualstack 300 IN AAAA 2001:db8::1
+dualstack 300 IN A 10.53.0.5
--- /dev/null
+; Copyright (C) Internet Systems Consortium, Inc. ("ISC")
+;
+; SPDX-License-Identifier: MPL-2.0
+;
+; This Source Code Form is subject to the terms of the Mozilla Public
+; License, v. 2.0. If a copy of the MPL was not distributed with this
+; file, you can obtain one at https://mozilla.org/MPL/2.0/.
+;
+; See the COPYRIGHT file distributed with this work for additional
+; information regarding copyright ownership.
+
+@ 30 IN SOA ns1 hostmaster 2017052201 3600 600 604800 30
+@ 7200 IN NS ns1
+@ 7200 IN NS ns2
+@ 7200 IN NS ns3
+@ 7200 IN NS ns4
+ns1 3600 IN A 10.53.0.1
+ns2 3600 IN A 10.53.0.2
+ns3 3600 IN A 10.53.0.4
+ns4 3600 IN A 10.53.0.4
+child 3600 IN NS ns1.child
+ns1.child 300 IN AAAA 2001:db8::1
+ns1.child 300 IN A 10.53.0.5