Commit b61c254d authored by Evan Hunt's avatar Evan Hunt

Merge branch 'each-dnssec-coverage-dots' into 'master'

dnssec-coverage was improperly ignoring some zones

See merge request !1487
parents cfdf457d a242c704
Pipeline #9708 passed with stages
in 11 minutes and 56 seconds
5159. [bug] dnssec-coverage was incorrectly ignoring
names specified on the command line without
trailing dots. [GL !1478]
5158. [protocol] Add support for ATMRELAY and ZONEMD. [GL #867]
5157. [bug] Nslookup now errors out if there are extra command
......
......@@ -188,8 +188,9 @@ def parse_args():
if args.filename and len(args.zone) > 1:
fatal("ERROR: -f can only be used with one zone.")
# strip trailing dots
args.zone = [x[:-1] for x in args.zone if len(x) > 1 and x[-1] == '.']
# strip trailing dots if any
args.zone = [x[:-1] if (len(x) > 1 and x[-1] == '.') else x
for x in args.zone]
# convert from time arguments to seconds
try:
......
args="-z -m2h"
warn=0
error=0
ok=2
retcode=0
match=
zones="one.example. two.example"
......@@ -13,4 +13,5 @@ rm -f named-compilezone
rm -f */K*.key
rm -f */K*.private
rm -rf coverage.*
rm -rf dotted-dotless
rm -f ns*/named.lock
......@@ -132,3 +132,8 @@ ksk1=`$KEYGEN -q -K $dir -a rsasha1 -3fk example.com`
dir=12-ksk-deletion
ksk1=`$KEYGEN -q -K $dir -f KSK -a 8 -b 2048 -I +40d -D +40d example.com`
ksk2=`$KEYGEN -q -K $dir -S $ksk1.key example.com`
# Test 13: check names with/without dots at the end
dir=13-dotted-dotless
zsk1=`$KEYGEN -q -K $dir -a rsasha256 one.example`
zsk2=`$KEYGEN -q -K $dir -a rsasha256 two.example`
......@@ -32,9 +32,9 @@ ret=0
for dir in [0-9][0-9]-*; do
ret=0
echo_i "$dir"
args= warn= error= ok= retcode= match=
args= warn= error= ok= retcode= match= zones=
. $dir/expect
$COVERAGE $args -K $dir example.com > coverage.$n 2>&1
$COVERAGE $args -K $dir ${zones:-example.com} > coverage.$n 2>&1
# check that return code matches expectations
found=$?
......
......@@ -482,6 +482,7 @@
./bin/tests/system/coverage/11-cutoff/README X 2014,2018,2019
./bin/tests/system/coverage/11-cutoff/expect X 2014,2018,2019
./bin/tests/system/coverage/12-ksk-deletion/expect X 2018,2019
./bin/tests/system/coverage/13-dotted-dotless/expect X 2019
./bin/tests/system/coverage/clean.sh SH 2013,2014,2016,2018,2019
./bin/tests/system/coverage/setup.sh SH 2013,2014,2016,2017,2018,2019
./bin/tests/system/coverage/tests.sh SH 2013,2014,2016,2018,2019
......
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