remove dns_client_update() and related code
the libdns client API is no longer being maintained for
external use, we can remove the code that isn't being used
internally, as well as the related tests.
(cherry picked from commit fb2a352e7c)
This commit is contained in:
@@ -1370,88 +1370,6 @@ EOF
|
||||
[ $ret = 0 ] || { echo_i "failed"; status=1; }
|
||||
|
||||
fi
|
||||
#
|
||||
# Add client library tests here
|
||||
#
|
||||
|
||||
if test unset != "${SAMPLEUPDATE:-unset}" -a -x "${SAMPLEUPDATE}"
|
||||
then
|
||||
|
||||
n=`expr $n + 1`
|
||||
ret=0
|
||||
echo_i "check that dns_client_update handles prerequisite NXDOMAIN failure ($n)"
|
||||
$SAMPLEUPDATE -P ${PORT} -a 10.53.0.1 -a 10.53.0.2 -p "nxdomain exists.sample" \
|
||||
add "nxdomain-exists.sample 0 in a 1.2.3.4" > update.out.test$n 2>&1
|
||||
$SAMPLEUPDATE -P ${PORT} -a 10.53.0.2 -p "nxdomain exists.sample" \
|
||||
add "check-nxdomain-exists.sample 0 in a 1.2.3.4" > update.out.check$n 2>&1
|
||||
$DIG $DIGOPTS +tcp @10.53.0.1 a nxdomain-exists.sample > dig.out.ns1.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a nxdomain-exists.sample > dig.out.ns2.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a check-nxdomain-exists.sample > check.out.ns2.test$n
|
||||
grep "update failed: YXDOMAIN" update.out.test$n > /dev/null || ret=1
|
||||
grep "update succeeded" update.out.check$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns1.test$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns2.test$n > /dev/null || ret=1
|
||||
grep "status: NOERROR" check.out.ns2.test$n > /dev/null || ret=1
|
||||
[ $ret = 0 ] || { echo_i "failed"; status=1; }
|
||||
|
||||
n=`expr $n + 1`
|
||||
ret=0
|
||||
echo_i "check that dns_client_update handles prerequisite YXDOMAIN failure ($n)"
|
||||
$SAMPLEUPDATE -P ${PORT} -a 10.53.0.1 -a 10.53.0.2 -p "yxdomain nxdomain.sample" \
|
||||
add "yxdomain-nxdomain.sample 0 in a 1.2.3.4" > update.out.test$n 2>&1
|
||||
$SAMPLEUPDATE -P ${PORT} -a 10.53.0.2 -p "yxdomain nxdomain.sample" \
|
||||
add "check-yxdomain-nxdomain.sample 0 in a 1.2.3.4" > update.out.check$n 2>&1
|
||||
$DIG $DIGOPTS +tcp @10.53.0.1 a nxdomain-exists.sample > dig.out.ns1.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a nxdomain-exists.sample > dig.out.ns2.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a check-nxdomain-exists.sample > check.out.ns2.test$n
|
||||
grep "update failed: NXDOMAIN" update.out.test$n > /dev/null || ret=1
|
||||
grep "update succeeded" update.out.check$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns1.test$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns2.test$n > /dev/null || ret=1
|
||||
grep "status: NOERROR" check.out.ns2.test$n > /dev/null || ret=1
|
||||
[ $ret = 0 ] || { echo_i "failed"; status=1; }
|
||||
|
||||
n=`expr $n + 1`
|
||||
ret=0
|
||||
echo_i "check that dns_client_update handles prerequisite NXRRSET failure ($n)"
|
||||
$SAMPLEUPDATE -P ${PORT} -a 10.53.0.1 -a 10.53.0.2 -p "nxrrset exists.sample TXT This RRset exists." \
|
||||
add "nxrrset-exists.sample 0 in a 1.2.3.4" > update.out.test$n 2>&1
|
||||
$SAMPLEUPDATE -P ${PORT} -a 10.53.0.2 -p "nxrrset exists.sample TXT This RRset exists." \
|
||||
add "check-nxrrset-exists.sample 0 in a 1.2.3.4" > update.out.check$n 2>&1
|
||||
$DIG $DIGOPTS +tcp @10.53.0.1 a nxrrset-exists.sample > dig.out.ns1.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a nxrrset-exists.sample > dig.out.ns2.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a check-nxrrset-exists.sample > check.out.ns2.test$n
|
||||
grep "update failed: YXRRSET" update.out.test$n > /dev/null || ret=1
|
||||
grep "update succeeded" update.out.check$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns1.test$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns2.test$n > /dev/null || ret=1
|
||||
grep "status: NOERROR" check.out.ns2.test$n > /dev/null || ret=1
|
||||
[ $ret = 0 ] || { echo_i "failed"; status=1; }
|
||||
|
||||
n=`expr $n + 1`
|
||||
ret=0
|
||||
echo_i "check that dns_client_update handles prerequisite YXRRSET failure ($n)"
|
||||
$SAMPLEUPDATE -s -P ${PORT} -a 10.53.0.1 -a 10.53.0.2 \
|
||||
-p "yxrrset no-txt.sample TXT" \
|
||||
add "yxrrset-nxrrset.sample 0 in a 1.2.3.4" > update.out.test$n 2>&1
|
||||
$SAMPLEUPDATE -P ${PORT} -a 10.53.0.2 -p "yxrrset no-txt.sample TXT" \
|
||||
add "check-yxrrset-nxrrset.sample 0 in a 1.2.3.4" > update.out.check$n 2>&1
|
||||
$DIG $DIGOPTS +tcp @10.53.0.1 a yxrrset-nxrrset.sample > dig.out.ns1.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a yxrrset-nxrrset.sample > dig.out.ns2.test$n
|
||||
$DIG $DIGOPTS +tcp @10.53.0.2 a check-yxrrset-nxrrset.sample > check.out.ns2.test$n
|
||||
grep "update failed: NXRRSET" update.out.test$n > /dev/null || ret=1
|
||||
grep "update succeeded" update.out.check$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns1.test$n > /dev/null || ret=1
|
||||
grep "status: NXDOMAIN" dig.out.ns2.test$n > /dev/null || ret=1
|
||||
grep "status: NOERROR" check.out.ns2.test$n > /dev/null || ret=1
|
||||
grep "2nd update failed: NXRRSET" update.out.test$n > /dev/null || ret=1
|
||||
[ $ret = 0 ] || { echo_i "failed"; status=1; }
|
||||
|
||||
fi
|
||||
|
||||
#
|
||||
# End client library tests here
|
||||
#
|
||||
|
||||
echo_i "exit status: $status"
|
||||
[ $status -eq 0 ] || exit 1
|
||||
|
||||
Reference in New Issue
Block a user