Commit 92fe6db3 authored by Evan Hunt's avatar Evan Hunt

[master] use test -r in system tests

3806.	[test]		Improved system test portability. [RT #35625]
parent ab272d22
3806. [test] Improved system test portability. [RT #35625]
3805. [contrib] Added contrib/perftcpdns, a performance testing tool
for DNS over TCP. [RT #35710]
......
......@@ -19,7 +19,7 @@ SYSTEMTESTTOP=..
. ./clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
echo "I:generating keys and preparing zones"
cd ns1 && sh keygen.sh
......@@ -17,6 +17,6 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
(cd ns1 && sh -e sign.sh)
......@@ -19,6 +19,6 @@ SYSTEMTESTTOP=..
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh sign.sh
......@@ -17,6 +17,6 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
$DDNSCONFGEN -q -r $RANDFILE -z example.nil > ns1/ddns.key
......@@ -19,6 +19,6 @@ sh clean.sh
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh sign.sh
......@@ -20,7 +20,7 @@ SYSTEMTESTTOP=..
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh sign.sh
......
......@@ -17,6 +17,6 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh sign.sh
......@@ -17,6 +17,6 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh sign.sh
......@@ -19,7 +19,7 @@ sh clean.sh
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cp ns1/named1.conf ns1/named.conf
cp ns2/named1.conf ns2/named.conf
......
......@@ -17,6 +17,6 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh sign.sh
......@@ -17,7 +17,7 @@ sh clean.sh
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cp ns1/root.db.in ns1/root.db
rm -f ns1/root.db.signed
......
......@@ -15,7 +15,7 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
rm -f named-compilezone
ln -s $CHECKZONE named-compilezone
......
......@@ -18,7 +18,7 @@ SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
sh ./clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
pzone=parent.nil
czone=child.parent.nil
......
......@@ -18,7 +18,7 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
#
# jnl and database files MUST be removed before we start
......
......@@ -17,6 +17,6 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh -e sign.sh
......@@ -20,7 +20,7 @@ SYSTEMTESTTOP=..
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cp ns2/redirect.db.in ns2/redirect.db
cp ns2/example.db.in ns2/example.db
......
......@@ -17,7 +17,7 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cp ns4/tld1.db ns4/tld.db
cp ns6/to-be-removed.tld.db.in ns6/to-be-removed.tld.db
......
......@@ -21,7 +21,7 @@ SYSTEMTESTTOP=..
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
sh ../genzone.sh 2 >ns2/nil.db
sh ../genzone.sh 2 >ns2/other.db
......
......@@ -37,7 +37,7 @@ for NM in '' -2 -given -disabled -passthru -no-op -nodata -nxdomain -cname -wild
done
# sign the root and a zone in ns2
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
# $1=directory, $2=domain name, $3=input zone file, $4=output file
signzone () {
......
......@@ -17,7 +17,7 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
if ./bigkey > /dev/null 2>&1
then
......
......@@ -19,6 +19,6 @@ sh clean.sh
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh -e sign.sh
......@@ -18,4 +18,4 @@ SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
......@@ -21,6 +21,6 @@ sed 's/SERVER_CONFIG_PLACEHOLDER/server-names { "ns.example.net"; };/' ns2/named
sed 's/EXAMPLE_ZONE_PLACEHOLDER/zone "example" { type master; file "example.db.signed"; };/' ns3/named.conf.in > ns3/named.conf
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns3 && sh -e sign.sh
......@@ -17,7 +17,7 @@
SYSTEMTESTTOP=${SYSTEMTESTTOP:=..}
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
prog=$0
......
......@@ -20,6 +20,6 @@ SYSTEMTESTTOP=..
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
cd ns1 && sh setup.sh
......@@ -19,7 +19,7 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
rm -f ns1/*.jnl ns1/K*.key ns1/K*.private ns1/_default.tsigkeys
......
......@@ -16,6 +16,6 @@ SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
(cd ns3; sh -e sign.sh)
......@@ -18,6 +18,6 @@ SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
(cd zones && sh genzones.sh)
......@@ -17,6 +17,6 @@
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
(cd ns1 && sh -e sign.sh)
......@@ -18,7 +18,7 @@ SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
sh clean.sh
test -e $RANDFILE || $GENRANDOM 400 $RANDFILE
test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
sh ../genzone.sh 1 > ns1/master.db
cd ns1
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment