From: Aram Sargsyan Date: Fri, 10 Nov 2023 11:33:40 +0000 (+0000) Subject: Add a check for the 'first refresh' data in rndc status X-Git-Tag: v9.19.22~60^2~2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e3557f8661e081c9a70278b2b197f29bd59ffbd8;p=thirdparty%2Fbind9.git Add a check for the 'first refresh' data in rndc status Check that 'rndc status' correctly indicates the expected number of the secondary zones which have the 'first refresh' flag set. --- diff --git a/bin/tests/system/statschannel/tests.sh b/bin/tests/system/statschannel/tests.sh index f8ba35cf367..29ff9079fae 100644 --- a/bin/tests/system/statschannel/tests.sh +++ b/bin/tests/system/statschannel/tests.sh @@ -689,6 +689,13 @@ if [ $ret != 0 ]; then echo_i "failed"; fi status=$((status + ret)) n=$((n + 1)) +echo_i "Checking that there are no 'first refresh' zones in ns3 ($n)" +ret=0 +$RNDCCMD 10.53.0.3 status | grep -E '^xfers first refresh: 0$' >/dev/null || ret=1 +if [ $ret != 0 ]; then echo_i "failed"; fi +status=$((status + ret)) +n=$((n + 1)) + echo_i "Transfering zones from ns1 to ns3 in slow mode ($n)" ret=0 i=0 @@ -739,10 +746,17 @@ if [ $ret != 0 ]; then echo_i "failed"; fi status=$((status + ret)) n=$((n + 1)) +echo_i "Checking that there is one 'first refresh' zone in ns3 ($n)" +ret=0 +$RNDCCMD 10.53.0.3 status | grep -E '^xfers first refresh: 1$' >/dev/null || ret=1 +if [ $ret != 0 ]; then echo_i "failed"; fi +status=$((status + ret)) +n=$((n + 1)) + if [ $PERL_JSON ]; then echo_i "Checking zone transfer transports ($n)" ret=0 - cp xfrins.json.j$((n - 1)) xfrins.json.j$n + cp xfrins.json.j$((n - 2)) xfrins.json.j$n $PERL xfrins-json.pl xfrins.json.j$n example >xfrins.example.format$n echo "soatransport: UDP" >xfrins.example.expect$n echo "transport: TCP" >>xfrins.example.expect$n