]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
address timing issue in tests
authorMark Andrews <marka@isc.org>
Wed, 2 Nov 2005 04:50:55 +0000 (04:50 +0000)
committerMark Andrews <marka@isc.org>
Wed, 2 Nov 2005 04:50:55 +0000 (04:50 +0000)
bin/tests/system/xfer/tests.sh

index 11f2d97151fb8d4d6499248cd080d9050eeed2d2..d6cbc45fb2e24a5346a09638d88663d97fd1cec6 100644 (file)
@@ -15,7 +15,7 @@
 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
 # PERFORMANCE OF THIS SOFTWARE.
 
-# $Id: tests.sh,v 1.24.12.4 2004/03/08 09:04:18 marka Exp $
+# $Id: tests.sh,v 1.24.12.5 2005/11/02 04:50:55 marka Exp $
 
 SYSTEMTESTTOP=..
 . $SYSTEMTESTTOP/conf.sh
@@ -29,8 +29,20 @@ $DIG $DIGOPTS example. \
        @10.53.0.2 axfr -p 5300 > dig.out.ns2 || status=1
 grep ";" dig.out.ns2
 
+#
+# Spin to allow the zone to tranfer.
+#
+for i in 1 2 3 4 5
+do
+tmp=0
 $DIG $DIGOPTS example. \
-       @10.53.0.3 axfr -p 5300 > dig.out.ns3 || status=1
+       @10.53.0.3 axfr -p 5300 > dig.out.ns3 || tmp=1
+       grep ";" dig.out.ns3 > /dev/null
+       if test $? -ne 0 ; then break; fi
+       echo "I: plain zone re-transfer"
+       sleep 5
+done
+if test $tmp -eq 1 ; then status=1; fi
 grep ";" dig.out.ns3
 
 $PERL ../digcomp.pl dig1.good dig.out.ns2 || status=1
@@ -43,9 +55,21 @@ $DIG $DIGOPTS tsigzone. \
        > dig.out.ns2 || status=1
 grep ";" dig.out.ns2
 
+#
+# Spin to allow the zone to tranfer.
+#
+for i in 1 2 3 4 5
+do
+tmp=0
 $DIG $DIGOPTS tsigzone. \
        @10.53.0.3 axfr -y tsigzone.:1234abcd8765 -p 5300 \
-       > dig.out.ns3 || status=1
+       > dig.out.ns3 || tmp=1
+       grep ";" dig.out.ns3 > /dev/null
+       if test $? -ne 0 ; then break; fi
+       echo "I: plain zone re-transfer"
+       sleep 5
+done
+if test $tmp -eq 1 ; then status=1; fi
 grep ";" dig.out.ns3
 
 $PERL ../digcomp.pl dig.out.ns2 dig.out.ns3 || status=1