CSIT-1459: Migrate IP libraries from VAT to PAPI
[csit.git] / tests / vpp / func / ip6_tunnels / vxlan / eth2p-ethip6vxlan-l2bdbasemaclrn-func.robot
1 # Copyright (c) 2019 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 *** Settings ***
15 | Library  | resources.libraries.python.IPUtil
16 | Library  | resources.libraries.python.Trace
17 | ...
18 | Resource | resources/libraries/robot/l2/l2_traffic.robot
19 | Resource | resources/libraries/robot/overlay/vxlan.robot
20 | Resource | resources/libraries/robot/shared/default.robot
21 | Resource | resources/libraries/robot/shared/testing_path.robot
22 | Resource | resources/libraries/robot/vm/qemu.robot
23 | ...
24 | Force Tags | 3_NODE_SINGLE_LINK_TOPO | VM_ENV | HW_ENV
25 | ...
26 | Test Setup | Set up functional test
27 | ...
28 | Test Teardown | Tear down functional test
29 | ...
30 | Documentation | *Bridge-domain with VXLAN test cases - IPv6*
31 | ...
32 | ... | *[Top] Network topologies:* TG-DUT1-DUT2-TG 3-node circular topology
33 | ... | with single links between nodes.
34 | ... | *[Enc] Packet encapsulations:* Eth-IPv6-VXLAN-Eth-IPv6-ICMPv6 on
35 | ... | DUT1-DUT2, Eth-IPv6-ICMPv6 on TG-DUTn for L2 switching of IPv6.
36 | ... | *[Cfg] DUT configuration:* DUT1 and DUT2 are configured with L2
37 | ... | bridge-domain (L2BD) switching combined with MAC learning enabled;
38 | ... | VXLAN tunnels are configured between L2BDs on DUT1 and DUT2.
39 | ... | *[Ver] TG verification:* Test ICMPv6 Echo Request packets are sent
40 | ... | in both directions by TG on links to DUT1 and DUT2; on receive TG
41 | ... | verifies packets for correctness and their IPv6 src-addr, dst-addr
42 | ... | and MAC addresses.
43 | ... | *[Ref] Applicable standard specifications:* RFC7348.
44
45 *** Variables ***
46 | ${vni_1}= | 23
47
48 | ${bd_id1}= | 10
49
50 | ${ip6_addr1}= | 3ffe:64::1
51 | ${ip6_addr2}= | 3ffe:64::2
52 | ${ip6_prefix}= | 64
53
54 *** Test Cases ***
55 | TC01: DUT1 and DUT2 with L2BD and VXLANoIPv6 tunnels switch ICMPv6 between TG links
56 | | [Documentation]
57 | | ... | [Top] TG=DUT1=DUT2=TG.[Enc] Eth-IPv6-VXLAN-Eth-IPv6-ICMPv6 on \
58 | | ... | DUT1-DUT2, Eth-IPv6-ICMPv6 on TG-DUTn. [Cfg] On DUT1 and DUT2
59 | | ... | configure L2 bridge-domain (MAC learning enabled), each with one
60 | | ... | interface to TG and one VXLAN tunnel interface towards the other
61 | | ... | DUT. [Ver] Make TG send ICMPv6 Echo Req between two of its
62 | | ... | interfaces to be switched by DUT1 and DUT2; verify all packets
63 | | ... | are received. [Ref] RFC7348.
64 | | [Tags] | 3_NODE_DOUBLE_LINK_TOPO
65 | | Given Configure path in 3-node circular topology
66 | | ... | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['DUT2']} | ${nodes['TG']}
67 | | And Set interfaces in 3-node circular topology up
68 | | And VPP Interface Set IP Address
69 | | ... | ${dut1_node} | ${dut1_to_dut2} | ${ip6_addr1} | ${ip6_prefix}
70 | | And VPP Interface Set IP Address
71 | | ... | ${dut2_node} | ${dut2_to_dut1} | ${ip6_addr2} | ${ip6_prefix}
72 | | And VPP IP Probe | ${dut1_node} | ${dut1_to_dut2} | ${ip6_addr2}
73 | | And VPP IP Probe | ${dut2_node} | ${dut2_to_dut1} | ${ip6_addr1}
74 | | And Vpp All RA Suppress Link Layer | ${nodes}
75 | | ${dut1s_vxlan}= | When Create VXLAN interface
76 | | ... | ${dut1_node} | ${vni_1} | ${ip6_addr1} | ${ip6_addr2}
77 | | And Add interfaces to L2BD
78 | | ... | ${dut1_node} | ${bd_id1} | ${dut1_to_tg} | ${dut1s_vxlan}
79 | | ${dut2s_vxlan}= | And Create VXLAN interface
80 | | ... | ${dut2_node} | ${vni_1} | ${ip6_addr2} | ${ip6_addr1}
81 | | And Add interfaces to L2BD
82 | | ... | ${dut2_node} | ${bd_id1} | ${dut2_to_tg} | ${dut2s_vxlan}
83 | | Then Send ICMPv6 bidirectionally and verify received packets
84 | | ... | ${tg_node} | ${tg_to_dut1} | ${tg_to_dut2}
85 | | And Get VXLAN dump | ${dut1_node}
86 | | And Get VXLAN dump | ${dut1_node} | interface=vxlan_tunnel0
87 | | And Get VXLAN dump | ${dut2_node} | interface=${dut2s_vxlan}