From: Matthijs Mekking Date: Thu, 29 Feb 2024 10:12:50 +0000 (+0100) Subject: Fix xferquota system test X-Git-Tag: v9.19.22~10^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=618c963cb75b3677d5d2e4ff9059a965f09fcb13;p=thirdparty%2Fbind9.git Fix xferquota system test The change from RBT to QP has changed the contents of generated zone files slightly: node names are now always absolute, so instead of using $ORIGIN and relative names, generated zone files use full names for all records. This caused a failure in the xferquota system test, which was looking for a relative name in secondary zone files. Replace the string matching with a regular expression to fix the test. --- diff --git a/bin/tests/system/xferquota/tests_xferquota.py b/bin/tests/system/xferquota/tests_xferquota.py index dbc29b937dc..ee71ec8488a 100644 --- a/bin/tests/system/xferquota/tests_xferquota.py +++ b/bin/tests/system/xferquota/tests_xferquota.py @@ -36,7 +36,7 @@ def test_xferquota(named_port, servers): with open(file_path, "r", encoding="utf-8") as zonefile: # Count the number of lines containing the search string for line in zonefile: - if "xyzzy A 10.0.0.2" in line: + if re.search(r"xyzzy.zone[0-9]+.example.*A\s+10\.0\.0\.2", line): matching_line_count += 1 return matching_line_count == 300