Skip to content
Snippets Groups Projects
Commit de549bae authored by Libor Peltan's avatar Libor Peltan Committed by Daniel Salzman
Browse files

tests: compatibility with new Bind

parent 07c0bbf5
No related branches found
No related tags found
No related merge requests found
......@@ -896,6 +896,14 @@ class Bind(Server):
zone_name = (" " + zone.name) if zone else ""
self.ctl("sync%s" % zone_name, wait=wait)
def check_option(self, option):
proc = Popen([self.daemon_bin + "-checkconf", "/dev/fd/0"],
stdout=PIPE, stderr=PIPE, stdin=PIPE,
universal_newlines=True)
conff = "options {\n %s;\n};" % option
(out, err) = proc.communicate(input=conff)
return proc.wait() == 0
def _str(self, conf, name, value):
if value and value != True:
conf.item_str(name, value)
......@@ -927,6 +935,8 @@ class Bind(Server):
s.item("notify-delay", "0")
s.item("notify-rate", "1000")
s.item("max-journal-size", "unlimited")
if self.check_option("max-ixfr-ratio unlimited"):
s.item("max-ixfr-ratio", "unlimited")
s.item("startup-notify-rate", "1000")
s.item("serial-query-rate", "1000")
s.end()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment