From: Mark Andrews Date: Thu, 13 Aug 2026 02:36:56 +0000 (+1000) Subject: Test that 'rndc-confgen -q' works as documented X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f85b229537ac43fd5c5eae320cdbfde2485ac6e1;p=thirdparty%2Fbind9.git Test that 'rndc-confgen -q' works as documented --- diff --git a/bin/tests/system/rndc_confgen/tests_rndc_confgen.py b/bin/tests/system/rndc_confgen/tests_rndc_confgen.py index fc9e9ca097d..3abafd3f8fe 100644 --- a/bin/tests/system/rndc_confgen/tests_rndc_confgen.py +++ b/bin/tests/system/rndc_confgen/tests_rndc_confgen.py @@ -34,6 +34,16 @@ def test_rndc_confgen_default(): assert b'key "rndc-key" {' in cmd.proc.stdout +def test_rndc_confgen_keyonly(): + cmd = isctest.run.cmd([os.environ["RNDCCONFGEN"], "-a", "-c", "rndc.key"]) + assert b'wrote key file "rndc.key"' in cmd.proc.stdout + + +def test_rndc_confgen_keyonlyquiet(): + cmd = isctest.run.cmd([os.environ["RNDCCONFGEN"], "-a", "-c", "rndc.key", "-q"]) + assert b'wrote key file "rndc.key"' not in cmd.proc.stdout + + def test_rndc_confgen_keyname_with_dots(): cmd = isctest.run.cmd([os.environ["RNDCCONFGEN"], "-k", "key.example.com"]) assert b'key "key.example.com" {' in cmd.proc.stdout