Skip to content

Commit 7cf1bc0

Browse files
yuwatabluca
authored andcommitted
test-network: add one more testcase for DHCPv4 classless route
For issue #28280. (cherry picked from commit 86f6760) (cherry picked from commit f74337b)
1 parent 2ed8067 commit 7cf1bc0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

test/test-network/systemd-networkd-tests.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4673,7 +4673,7 @@ def _test_dhcp_client_ipv4_use_routes_gateway(self, use_routes, use_gateway, dns
46734673
]
46744674
if classless:
46754675
additional_options += [
4676-
'--dhcp-option=option:classless-static-route,0.0.0.0/0,192.168.5.4,8.0.0.0/8,192.168.5.5'
4676+
'--dhcp-option=option:classless-static-route,0.0.0.0/0,192.168.5.4,8.0.0.0/8,192.168.5.5,192.168.5.64/26,192.168.5.5'
46774677
]
46784678
start_dnsmasq(*additional_options)
46794679
self.wait_online(['veth99:routable', 'veth-peer:routable'])
@@ -4686,6 +4686,7 @@ def _test_dhcp_client_ipv4_use_routes_gateway(self, use_routes, use_gateway, dns
46864686
if classless:
46874687
self.assertRegex(output, r'default via 192.168.5.4 proto dhcp src 192.168.5.[0-9]* metric 1024')
46884688
self.assertRegex(output, r'8.0.0.0/8 via 192.168.5.5 proto dhcp src 192.168.5.[0-9]* metric 1024')
4689+
self.assertRegex(output, r'192.168.5.64/26 via 192.168.5.5 proto dhcp src 192.168.5.[0-9]* metric 1024')
46894690
self.assertRegex(output, r'192.168.5.4 proto dhcp scope link src 192.168.5.[0-9]* metric 1024')
46904691
self.assertRegex(output, r'192.168.5.5 proto dhcp scope link src 192.168.5.[0-9]* metric 1024')
46914692
else:

0 commit comments

Comments
 (0)