summaryrefslogtreecommitdiff
path: root/smoketest/scripts
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2024-01-06 20:45:46 +0100
committerChristian Breunig <christian@breunig.cc>2024-01-06 20:48:59 +0100
commit9baeafa890f7b1d3829df633322fb4288e9ea882 (patch)
treea59fa3bfd03b2901b2aa1d67585772222717ba05 /smoketest/scripts
parent199ceb1f0a820c838dea6862371a3121b3d9f3a9 (diff)
downloadvyos-1x-9baeafa890f7b1d3829df633322fb4288e9ea882.tar.gz
vyos-1x-9baeafa890f7b1d3829df633322fb4288e9ea882.zip
dns: T5900: fix smoketests for serve-stale-extension and exclude-throttle-address
This fixes commit 199ceb1f0a ("dns: T5900: add dont-throttle-netmasks and serve-stale-extensions powerdns features") where after the latest review round the Jinja2 template was inconsitently changed and smoketests were not re-run.
Diffstat (limited to 'smoketest/scripts')
-rwxr-xr-xsmoketest/scripts/cli/test_service_dns_forwarding.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/smoketest/scripts/cli/test_service_dns_forwarding.py b/smoketest/scripts/cli/test_service_dns_forwarding.py
index 4f2f182e5..85a5f1448 100755
--- a/smoketest/scripts/cli/test_service_dns_forwarding.py
+++ b/smoketest/scripts/cli/test_service_dns_forwarding.py
@@ -1,6 +1,6 @@
#!/usr/bin/env python3
#
-# Copyright (C) 2019-2022 VyOS maintainers and contributors
+# Copyright (C) 2019-2024 VyOS maintainers and contributors
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 or later as
@@ -43,7 +43,6 @@ class TestServicePowerDNS(VyOSUnitTestSHIM.TestCase):
@classmethod
def setUpClass(cls):
super(TestServicePowerDNS, cls).setUpClass()
-
# ensure we can also run this test on a live system - so lets clean
# out the current configuration :)
cls.cli_delete(cls, base_path)
@@ -259,23 +258,24 @@ class TestServicePowerDNS(VyOSUnitTestSHIM.TestCase):
self.cli_commit()
# verify dont-throttle-netmasks configuration
- tmp = get_config_value('exclude-throttle-address')
+ tmp = get_config_value('dont-throttle-netmasks')
self.assertEqual(tmp, ','.join(exclude_throttle_adress_examples))
def test_serve_stale_extension(self):
+ server_stale = '20'
for network in allow_from:
self.cli_set(base_path + ['allow-from', network])
for address in listen_adress:
self.cli_set(base_path + ['listen-address', address])
- self.cli_set(base_path + ['serve-stale-extension', '20'])
+ self.cli_set(base_path + ['serve-stale-extension', server_stale])
# commit changes
self.cli_commit()
# verify configuration
- tmp = get_config_value('serve-stale-extension')
- self.assertEqual(tmp, '20')
+ tmp = get_config_value('serve-stale-extensions')
+ self.assertEqual(tmp, server_stale)
def test_listening_port(self):
# We can listen on a different port compared to '53' but only one at a time