Blame testsuite/tests/bridge/vlan/show.t
|
Packit Service |
3880ab |
#!/bin/sh
|
|
Packit Service |
3880ab |
|
|
Packit Service |
3880ab |
. lib/generic.sh
|
|
Packit Service |
3880ab |
|
|
Packit Service |
3880ab |
ts_log "[Testing vlan show]"
|
|
Packit Service |
3880ab |
|
|
Packit Service |
3880ab |
BR_DEV="$(rand_dev)"
|
|
Packit Service |
3880ab |
VX0_DEV="$(rand_dev)"
|
|
Packit Service |
3880ab |
VX1_DEV="$(rand_dev)"
|
|
Packit Service |
3880ab |
|
|
Packit Service |
3880ab |
ts_ip "$0" "Add $BR_DEV bridge interface" link add $BR_DEV type bridge
|
|
Packit Service |
3880ab |
|
|
Packit Service |
3880ab |
ts_ip "$0" "Add $VX0_DEV vxlan interface" \
|
|
Packit Service |
3880ab |
link add $VX0_DEV type vxlan dstport 4789 external
|
|
Packit Service |
3880ab |
ts_ip "$0" "Enslave $VX0_DEV under $BR_DEV" \
|
|
Packit Service |
3880ab |
link set dev $VX0_DEV master $BR_DEV
|
|
Packit Service |
3880ab |
ts_bridge "$0" "Delete default vlan from $VX0_DEV" \
|
|
Packit Service |
3880ab |
vlan del dev $VX0_DEV vid 1
|
|
Packit Service |
3880ab |
ts_ip "$0" "Add $VX1_DEV vxlan interface" \
|
|
Packit Service |
3880ab |
link add $VX1_DEV type vxlan dstport 4790 external
|
|
Packit Service |
3880ab |
ts_ip "$0" "Enslave $VX1_DEV under $BR_DEV" \
|
|
Packit Service |
3880ab |
link set dev $VX1_DEV master $BR_DEV
|
|
Packit Service |
3880ab |
|
|
Packit Service |
3880ab |
# Test that bridge ports without vlans do not appear in the output
|
|
Packit Service |
3880ab |
ts_bridge "$0" "Show vlan" vlan
|
|
Packit Service |
3880ab |
test_on_not "$VX0_DEV"
|
|
Packit Service |
3880ab |
|
|
Packit Service |
3880ab |
# Test that bridge ports without tunnels do not appear in the output
|
|
Packit Service |
3880ab |
ts_bridge "$0" "Show vlan tunnel info" vlan tunnelshow
|
|
Packit Service |
3880ab |
test_lines_count 1 # header only
|