CSIT-195: Update LISP test
[csit.git] / tests / suites / lisp / lisp_api_untagged.robot
1 # Copyright (c) 2016 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.topology.Topology
16 | Library | resources.libraries.python.NodePath
17 | Library | resources.libraries.python.Trace
18 | Library | resources.libraries.python.LispUtil
19 | Resource | resources/libraries/robot/default.robot
20 | Resource | resources/libraries/robot/interfaces.robot
21 | Resource | resources/libraries/robot/lisp/lisp_api.robot
22 # import additional Lisp settings from resource file
23 | Variables | resources/test_data/lisp/api/lisp_api_resources.py
24 | Force Tags | 3_NODE_SINGLE_LINK_TOPO | 3_NODE_DOUBLE_LINK_TOPO
25 | ... | VM_ENV | HW_ENV
26 | Test Setup | Run Keywords | Setup all DUTs before test
27 | ...        | AND          | Setup all TGs before traffic script
28 | ...        | AND          | Update All Interface Data On All Nodes | ${nodes}
29 | Test Teardown | Run Keywords | Show Packet Trace on All DUTs | ${nodes}
30 | ...           | AND          | Show vpp trace dump on all DUTs
31 | Documentation | *LISP API test cases*
32 | ...
33 | ... | *[Top] Network Topologies:* DUT1 1-node topology.
34 | ... | *[Enc] Packet Encapsulations:* None.
35 | ... | *[Cfg] DUT configuration:* DUT1 gets configured with all LISP
36 | ... | parameters.
37 | ... | *[Ver] Verification:* DUT1 operational data gets verified following
38 | ... | configuration.
39 | ... | *[Ref] Applicable standard specifications:* RFC6830.
40
41 *** Variables ***
42 | ${locator_set_num}= | 3
43
44 *** Test Cases ***
45
46 | TC01: DUT can enable and disable LISP
47 | | [Documentation]
48 | | ... | [Top] DUT1. [Enc] None. [Cfg1] Test LISP enable/disable API; On \
49 | | ... | DUT1 enable LISP. [Ver1] Check DUT1 if LISP is enabled. [Cfg2]
50 | | ... | Then disable LISP. [Ver2] Check DUT1 if LISP is disabled. [Ref]
51 | | ... | RFC6830.
52 | | [Tags] | EXPECTED_FAILING
53 | | When Enable lisp | ${nodes['DUT1']}
54 | | Then Check if lisp is enabled | ${nodes['DUT1']} | ${lisp_status}
55 | | When Disable lisp | ${nodes['DUT1']}
56 | | Then Check if lisp is disabled | ${nodes['DUT1']} | ${lisp_status}
57
58 | TC02: DUT can add and delete locator_set
59 | | [Documentation]
60 | | ... | [Top] DUT1. [Enc] None. [Cfg1] Test LISP locator_set API; on \
61 | | ... | DUT1 configure locator_set and locator. [Ver1] Check DUT1
62 | | ... | configured locator_set and locator are correct. [Cfg2] Then
63 | | ... | remove locator_set and locator. [Ver2] check DUT1 locator_set
64 | | ... | and locator are removed. [Ref] RFC6830.
65 | | [Tags] | EXPECTED_FAILING
66 | | Given Lisp locator_set data is prepared
67 | | ... | ${nodes['DUT1']} | ${locator_set_num}
68 | | And   Enable lisp | ${nodes['DUT1']}
69 | | When Lisp locator_set data is set | ${nodes['DUT1']}
70 | | Then Lisp locator_set is set correctly | ${nodes['DUT1']}
71 | | When Delete all lisp locator_set from VPP | ${nodes['DUT1']}
72 | | Then Lisp locator_set should be unset | ${nodes['DUT1']}
73
74 | TC03: DUT can add, reset and delete locator_set
75 | | [Documentation]
76 | | ... | [Top] DUT1. [Enc] None. [Cfg1] Test LISP locator_set API; on \
77 | | ... | DUT1 configure locator_set and locator. [Ver1] Check DUT1
78 | | ... | locator_set and locator are correct. [Cfg2] Then reset
79 | | ... | locator_set and set it again. [Ver2] Check DUT1 locator_set and
80 | | ... | locator are correct. [Cfg3] Then remove locator_set and locator.
81 | | ... | [Ver3] Check DUT1 all locator_set and locators are removed.
82 | | ... | [Ref] RFC6830.
83 | | [Tags] | EXPECTED_FAILING
84 | | Given Lisp locator_set data use for test reset locator_set are prepared
85 | | ... | ${nodes['DUT1']} | ${locator_set_num}
86 | | And   Enable lisp | ${nodes['DUT1']}
87 | | When Lisp locator_set data is set | ${nodes['DUT1']}
88 | | Then Lisp locator_set is set correctly | ${nodes['DUT1']}
89 | | When Delete all lisp locator_set from VPP | ${nodes['DUT1']}
90 | | Then Lisp locator_set should be unset | ${nodes['DUT1']}
91
92 | TC04: DUT can add and delete eid address
93 | | [Documentation]
94 | | ... | [Top] DUT1. [Enc] None. [Cfg1] Test LISP eid API; on DUT1 \
95 | | ... | configure LISP eid IP address. [Ver1] Check DUT1 configured data
96 | | ... | is correct. [Cfg2] Remove configured data. [Ver2] Check DUT1 all
97 | | ... | eid IP addresses are removed. [Ref] RFC6830.
98 | | [Tags] | EXPECTED_FAILING
99 | | Given Enable lisp | ${nodes['DUT1']}
100 | | When Lisp eid address is set | ${nodes['DUT1']} | ${eid_table}
101 | | Then Lisp eid address is set correctly to eid table | ${nodes['DUT1']}
102 | | ...                                                 | ${eid_table}
103 | | When Delete all lisp eid address from VPP | ${nodes['DUT1']} | ${eid_table}
104 | | Then Lisp eid table should be empty | ${nodes['DUT1']}
105
106 | TC05: DUT can add and delete LISP map resolver address
107 | | [Documentation]
108 | | ... | [Top] DUT1. [Enc] None. [Cfg1] Test LISP map resolver address \
109 | | ... | API; on DUT1 configure LISP map resolver address. [Ver1] Check
110 | | ... | DUT1 configured data is correct. [Cfg2] Remove configured data.
111 | | ... | [Ver2] Check DUT1 all map resolver addresses are removed. [Ref]
112 | | ... | RFC6830.
113 | | Given Enable lisp | ${nodes['DUT1']}
114 | | When Lisp map resolver address is set | ${nodes['DUT1']} | ${map_resolver}
115 | | Then Lisp map resolver address is set correctly | ${nodes['DUT1']}
116 | | ...                                             | ${map_resolver}
117 | | When Delete all lisp map resolver address from VPP | ${nodes['DUT1']}
118 | | ...                                                | ${map_resolver}
119 | | Then Lip map resolver address should be empty | ${nodes['DUT1']}