#
# Copyright (C) 2014-2017 Internet Systems Consortium, Inc. ("ISC")
#
# 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 http://mozilla.org/MPL/2.0/.
# $Id: tests.sh,v 1.22 2012/02/09 23:47:18 tbox Exp $
status=0
n=0
awk '$2 == "COOKIE:" {
print $3;
}' < $1
}
awk 'BEGIN { n = 0 }
// { v[n++] = length(); }
END { print (v[1] == v[2]); }'
}
}
do
n=`expr $n + 1`
echo "I:checking that named-checkconf detects error in $bad ($n)"
ret=0
done
do
n=`expr $n + 1`
echo "I:checking that named-checkconf detects accepts $good ($n)"
ret=0
done
n=`expr $n + 1`
echo "I:checking COOKIE token returned to empty COOKIE option ($n)"
ret=0
n=`expr $n + 1`
echo "I:checking response size without COOKIE ($n)"
ret=0
n=`expr $n + 1`
echo "I:checking response size without valid COOKIE ($n)"
ret=0
n=`expr $n + 1`
echo "I:checking response size with COOKIE ($n)"
ret=0
n=`expr $n + 1`
echo "I:checking response size with COOKIE recursive ($n)"
ret=0
n=`expr $n + 1`
echo "I:checking COOKIE is learnt for TCP retry ($n)"
ret=0
linecount=`getcookie dig.out.test$n | wc -l`
n=`expr $n + 1`
echo "I:checking for COOKIE value in adb ($n)"
ret=0
sleep 1
n=`expr $n + 1`
echo "I:checking require-server-cookie default (no) ($n)"
ret=0
linecount=`getcookie dig.out.test$n | wc -l`
n=`expr $n + 1`
echo "I:checking require-server-cookie yes ($n)"
ret=0
linecount=`getcookie dig.out.test$n | wc -l`
echo "I:exit status: $status"