1#!/bin/sh
2
3# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
4#
5# SPDX-License-Identifier: MPL-2.0
6#
7# This Source Code Form is subject to the terms of the Mozilla Public
8# License, v. 2.0.  If a copy of the MPL was not distributed with this
9# file, you can obtain one at https://mozilla.org/MPL/2.0/.
10#
11# See the COPYRIGHT file distributed with this work for additional
12# information regarding copyright ownership.
13
14set -e
15
16. ../conf.sh
17
18#
19# Do glue tests.
20#
21
22DIGOPTS="+norec -p ${PORT}"
23
24status=0
25
26echo_i "testing that a ccTLD referral gets a full glue set from the root zone"
27$DIG $DIGOPTS @10.53.0.1 foo.bar.fi. A >dig.out || status=1
28digcomp --lc fi.good dig.out || status=1
29
30echo_i "testing that we don't find out-of-zone glue"
31$DIG $DIGOPTS @10.53.0.1 example.net. a >dig.out || status=1
32digcomp noglue.good dig.out || status=1
33
34echo_i "exit status: $status"
35[ $status -eq 0 ] || exit 1
36