mirror of
https://github.com/systemd/systemd
synced 2024-07-21 10:17:21 +00:00
test-network: add test for small MTU for vcan
Prompted by https://github.com/systemd/systemd/issues/30140#issuecomment-1837973580.
This commit is contained in:
parent
941f8e1399
commit
470a329d98
|
@ -2,3 +2,4 @@
|
|||
[NetDev]
|
||||
Name=vcan99
|
||||
Kind=vcan
|
||||
MTUBytes=16
|
||||
|
|
4
test/test-network/conf/25-vcan98.netdev
Normal file
4
test/test-network/conf/25-vcan98.netdev
Normal file
|
@ -0,0 +1,4 @@
|
|||
# SPDX-License-Identifier: LGPL-2.1-or-later
|
||||
[NetDev]
|
||||
Name=vcan98
|
||||
Kind=vcan
|
6
test/test-network/conf/25-vcan98.network
Normal file
6
test/test-network/conf/25-vcan98.network
Normal file
|
@ -0,0 +1,6 @@
|
|||
# SPDX-License-Identifier: LGPL-2.1-or-later
|
||||
[Match]
|
||||
Name=vcan98
|
||||
|
||||
[Link]
|
||||
MTUBytes=16
|
|
@ -1725,10 +1725,20 @@ class NetworkdNetDevTests(unittest.TestCase, Utilities):
|
|||
|
||||
@expectedFailureIfModuleIsNotAvailable('vcan')
|
||||
def test_vcan(self):
|
||||
copy_network_unit('25-vcan.netdev', '26-netdev-link-local-addressing-yes.network')
|
||||
copy_network_unit('25-vcan.netdev', '26-netdev-link-local-addressing-yes.network',
|
||||
'25-vcan98.netdev', '25-vcan98.network')
|
||||
start_networkd()
|
||||
|
||||
self.wait_online(['vcan99:carrier'])
|
||||
self.wait_online(['vcan99:carrier', 'vcan98:carrier'])
|
||||
|
||||
# https://github.com/systemd/systemd/issues/30140
|
||||
output = check_output('ip -d link show vcan99')
|
||||
print(output)
|
||||
self.assertIn('mtu 16 ', output)
|
||||
|
||||
output = check_output('ip -d link show vcan98')
|
||||
print(output)
|
||||
self.assertIn('mtu 16 ', output)
|
||||
|
||||
@expectedFailureIfModuleIsNotAvailable('vxcan')
|
||||
def test_vxcan(self):
|
||||
|
|
Loading…
Reference in a new issue