From: Michal Nowak Date: Thu, 5 Dec 2024 10:58:12 +0000 (+0100) Subject: Wait for "all zones loaded" after rndc reload in "database" test X-Git-Tag: v9.21.4~25^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=0bdd03db6683cd30924456823f650e37235cbce8;p=thirdparty%2Fbind9.git Wait for "all zones loaded" after rndc reload in "database" test After the rndc reload command finished, we might have queried the database zone sooner than it was reloaded because rndc reloads zones asynchronously if no specific zone was provided. We should wait for "all zones loaded" in the ns1 log to be sure. --- diff --git a/bin/tests/system/database/tests_database.py b/bin/tests/system/database/tests_database.py index 6793e50b958..476b81da95c 100644 --- a/bin/tests/system/database/tests_database.py +++ b/bin/tests/system/database/tests_database.py @@ -28,7 +28,9 @@ def test_database(servers, templates): ) templates.render("ns1/named.conf", {"rname": "marka.isc.org."}) - servers["ns1"].rndc("reload") + with servers["ns1"].watch_log_from_here() as watcher: + servers["ns1"].rndc("reload") + watcher.wait_for_line("all zones loaded") # checking post reload zone res = isctest.query.tcp(msg, "10.53.0.1")