if_vlan tests: Test changing vlan ID

We can now change the vlan ID of an if_vlan interface without
disassociating it from the parent interface.

Test that this works.

Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D35847
This commit is contained in:
Kristof Provost 2022-07-19 00:49:30 +02:00
parent b82b8055ad
commit cfee1417fb

View File

@ -29,6 +29,17 @@ basic_body()
jexec singsing ifconfig ${vlan1} 10.0.0.2/24 up
atf_check -s exit:0 -o ignore jexec singsing ping -c 1 10.0.0.1
# Test changing the vlan ID
atf_check -s exit:0 \
jexec singsing ifconfig ${vlan1} vlandev ${epair_vlan}b vlan 43
atf_check -s exit:2 -o ignore jexec singsing ping -c 1 10.0.0.1
# And change back
# Test changing the vlan ID
atf_check -s exit:0 \
jexec singsing ifconfig ${vlan1} vlandev ${epair_vlan}b vlan 42
atf_check -s exit:0 -o ignore jexec singsing ping -c 1 10.0.0.1
}
basic_cleanup()