From: Evan Hunt Date: Fri, 27 Apr 2018 06:02:40 +0000 (-0700) Subject: Fix a testing error when using python3 on certain dates X-Git-Tag: v9.13.0~41^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=30b988f09afce58070b9396ded46b3b457bff6c5;p=thirdparty%2Fbind9.git Fix a testing error when using python3 on certain dates Date conversion was broken in python3 for dates with leading zeroes in both month and day. --- diff --git a/bin/tests/system/dnssec/tests.sh b/bin/tests/system/dnssec/tests.sh index bf73aa21fd4..4f7e1623324 100644 --- a/bin/tests/system/dnssec/tests.sh +++ b/bin/tests/system/dnssec/tests.sh @@ -3004,8 +3004,8 @@ if [ -x "$PYTHON" ]; then # convert expiry date to a comma-separated list of integers python can # use as input to date(). strip leading 0s in months and days so # python3 will recognize them as integers. - soaexpire=`$DIG +dnssec +short -p ${PORT} @10.53.0.3 soa siginterval.example | awk '$1 ~ /SOA/ { print $5 }' | sed 's/\(....\)\(..\)\(..\).*/\1, \2, \3/' | sed 's/ 0/ /'` - dnskeyexpire=`$DIG +dnssec +short -p ${PORT} @10.53.0.3 dnskey siginterval.example | awk '$1 ~ /DNSKEY/ { print $5; exit 0 }' | sed 's/\(....\)\(..\)\(..\).*/\1, \2, \3/' | sed 's/ 0/ /'` + soaexpire=`$DIG +dnssec +short -p ${PORT} @10.53.0.3 soa siginterval.example | awk '$1 ~ /SOA/ { print $5 }' | sed 's/\(....\)\(..\)\(..\).*/\1, \2, \3/' | sed 's/ 0/ /g'` + dnskeyexpire=`$DIG +dnssec +short -p ${PORT} @10.53.0.3 dnskey siginterval.example | awk '$1 ~ /DNSKEY/ { print $5; exit 0 }' | sed 's/\(....\)\(..\)\(..\).*/\1, \2, \3/' | sed 's/ 0/ /g'` $PYTHON > python.out.$n <