Geneve: Re-write the creation of tunnels in python
[csit.git] / resources / libraries / robot / ip / geneve.robot
1 # Copyright (c) 2021 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.GeneveUtil
16 |
17 | Documentation | Keywords for GENEVE tunnels in VPP.
18
19 *** Keywords ***
20 | Initialize GENEVE L3 mode in circular topology
21 | | [Documentation] | Initialization of GENEVE L3 mode on DUT1.
22 | |
23 | | Set interfaces in path up
24 | |
25 | | VPP Interface Set IP Address
26 | | ... | ${dut1} | ${DUT1_${int}1}[0] | ${dut1_if1_ip4} | 24
27 | | VPP Add IP Neighbor
28 | | ... | ${dut1} | ${DUT1_${int}1}[0] | ${tg_if1_ip4} | ${TG_pf1_mac}[0]
29 | | VPP Interface Set IP Address
30 | | ... | ${dut1} | ${DUT1_${int}2}[0] | ${dut1_if2_ip4} | 24
31 | | VPP Add IP Neighbor
32 | | ... | ${dut1} | ${DUT1_${int}2}[0] | ${tg_if2_ip4} | ${TG_pf2_mac}[0]
33 | | ${next_index}= | VPP Add Graph Node Next
34 | | ... | ${dut1} | geneve4-input | ethernet-input
35 | |
36 | | VPP GENEVE Add Multiple Tunnels
37 | | ... | ${dut1} | ${gen_tunnel} | ${n_tunnels} | ${DUT1_${int}1}[0]
38 | | ... | ${DUT1_${int}2}[0] | ${tg_if1_ip4} | ${tg_if2_ip4}
39 | | ... | ${TG_pf2_mac}[0] | ${next_index}
40 | |
41 | | All VPP Interfaces Ready Wait | ${nodes} | retries=${60}