From a32cf7ee5c7c46831ec0f2884d39f32752124514 Mon Sep 17 00:00:00 2001 From: Devon Mar Date: Fri, 18 Aug 2023 22:58:34 -0700 Subject: [PATCH] Add shared-networks test --- tests/files/kea_configs/kea-dhcp4.conf | 12 ++++++++++++ tests/files/kea_configs/kea-dhcp6.conf | 12 ++++++++++++ tests/test_ui.py | 4 ++-- 3 files changed, 26 insertions(+), 2 deletions(-) diff --git a/tests/files/kea_configs/kea-dhcp4.conf b/tests/files/kea_configs/kea-dhcp4.conf index 8b2a1f5..1e20f05 100644 --- a/tests/files/kea_configs/kea-dhcp4.conf +++ b/tests/files/kea_configs/kea-dhcp4.conf @@ -411,6 +411,18 @@ } ], + "shared-networks": [ + { + "name": "test-shared-network-4", + "subnet4": [ + { + "subnet": "198.51.100.0/24", + "pools": [ { "pool": "198.51.100.1 - 198.51.100.200" } ] + } + ] + } + ], + // There are many, many more parameters that DHCPv4 server is able to use. // They were not added here to not overwhelm people with too much // information at once. diff --git a/tests/files/kea_configs/kea-dhcp6.conf b/tests/files/kea_configs/kea-dhcp6.conf index 27a449b..9f64ff9 100644 --- a/tests/files/kea_configs/kea-dhcp6.conf +++ b/tests/files/kea_configs/kea-dhcp6.conf @@ -370,6 +370,18 @@ // } ], + "shared-networks": [ + { + "name": "test-shared-network-6", + "subnet6": [ + { + "subnet": "2001:db8:2::/64", + "pools": [ { "pool": "2001:db8:2::/64" } ] + } + ] + } + ], + // Client-classes can be defined here. See "client-classes" in Dhcp4 for // an example. diff --git a/tests/test_ui.py b/tests/test_ui.py index e08cde4..a35dd0a 100644 --- a/tests/test_ui.py +++ b/tests/test_ui.py @@ -498,8 +498,8 @@ def test_server_status(page: Page, kea: KeaClient) -> None: @pytest.mark.parametrize( ("family", "subnets"), ( - (4, ("192.0.2.0/24",)), - (6, ("2001:db8:1::/64",)), + (4, ("192.0.2.0/24", "198.51.100.0/24")), + (6, ("2001:db8:1::/64", "2001:db8:2::/64")), ), ) def test_dhcp_subnets(