CSIT-562 HC Test: Persistence suite rework, part1
[csit.git] / tests / func / honeycomb / mgmt-cfg-lisp-apihc-apivat-func.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 *** Variables***
15 | ${ip_address}= | 192.168.0.4
16 | @{ip_addresses}= | 192.168.0.4 | 192.168.0.5 | 192.168.0.6 | 192.168.0.7
17 | ${state}= | enabled
18 | ${interface}= | ${node['interfaces']['port1']['name']}
19 | ${bd_name}= | bd_lisp
20 | ${bd2_name}= | bd2_lisp
21 | &{bd_settings}= | flood=${True} | forward=${True} | learn=${True}
22 | ... | unknown-unicast-flood=${True} | arp-termination=${True}
23
24 *** Settings ***
25 | Resource | resources/libraries/robot/default.robot
26 | Resource | resources/libraries/robot/honeycomb/honeycomb.robot
27 | Resource | resources/libraries/robot/honeycomb/lisp.robot
28 | Resource | resources/libraries/robot/honeycomb/bridge_domain.robot
29 | Variables | resources/test_data/honeycomb/lisp.py
30 | Documentation | *Honeycomb Lisp test suite.*
31 | Suite Teardown | Run Keyword If Any Tests Failed
32 | ... | Restart Honeycomb and VPP | ${node}
33 | Force Tags | HC_FUNC
34
35 *** Test Cases ***
36 | TC01: Honeycomb enables Lisp feature
37 | | [Documentation] | Check if Honeycomb can enable the Lisp feature.
38 | | Given Lisp Should Not Be Configured | ${node}
39 | | When Honeycomb Enables Lisp | ${node}
40 | | Then Lisp state From Honeycomb Should Be | ${node} | ${state}
41 | | And Lisp state From VAT Should Be | ${node} | ${state}
42
43 | TC02: Honeycomb adds locator set and locator
44 | | [Documentation] | Check if Honeycomb can configure a locator set.
45 | | Given Lisp state From Honeycomb Should Be | ${node} | ${state}
46 | | When Honeycomb adds locator set | ${node} | ${interface} | ${locator_set}
47 | | Then Locator Set From Honeycomb Should Be
48 | | ... | ${node} | ${interface} | ${locator_set}
49
50 | TC03: Honeycomb configures Lisp - remote mapping - Bridge Domain
51 | | [Documentation] | Check if Honeycomb can configure a remote Lisp mapping\
52 | | ... | with a bridge domain.
53 | | Given Lisp state From Honeycomb Should Be | ${node} | ${state}
54 | | And Honeycomb creates first l2 bridge domain
55 | | ... | ${node} | ${bd_name} | ${bd_settings}
56 | | When Honeycomb adds Lisp mapping | ${node} | ${lisp_settings_remote_bd}
57 | | Then Lisp mapping From Honeycomb Should Be
58 | | ... | ${node} | ${remote_bd_subtable}
59 | | And Lisp mapping From VAT Should Be
60 | | ... | ${node} | ${vat_remote_bd}
61
62 | TC04: Honeycomb can remove Lisp mapping
63 | | [Documentation] | Check if Honeycomb can remove a configured Lisp mapping.
64 | | Given Lisp mapping From Honeycomb Should Be
65 | | ... | ${node} | ${remote_bd_subtable}
66 | | And Lisp mapping From VAT Should Be
67 | | ... | ${node} | ${vat_remote_bd}
68 | | When Honeycomb removes all lisp mappings | ${node}
69 | | Then Lisp mappings from Honeycomb should not exist
70 | | ... | ${node}
71 | | And Lisp mappings from VAT should not exist
72 | | ... | ${node}
73
74 | TC05: Honeycomb configures Lisp - remote mapping - VRF
75 | | [Documentation] | Check if Honeycomb can configure a remote Lisp mapping\
76 | | ... | with VRF.
77 | | [Teardown] | Honeycomb removes all lisp mappings | ${node}
78 | | Given Lisp mappings from Honeycomb should not exist
79 | | ... | ${node}
80 | | And Lisp mappings from VAT should not exist
81 | | ... | ${node}
82 | | When Honeycomb adds Lisp mapping | ${node} | ${lisp_settings_remote_vrf}
83 | | Then Lisp mapping From Honeycomb Should Be
84 | | ... | ${node} | ${remote_vrf_subtable}
85 | | And Lisp mapping From VAT Should Be | ${node} | ${vat_remote_vrf}
86
87 | TC06: Honeycomb configures Lisp - local mapping - Bridge Domain
88 | | [Documentation] | Check if Honeycomb can configure a local Lisp mapping\
89 | | ... | with a bridge domain.
90 | | [Teardown] | Honeycomb removes all lisp mappings | ${node}
91 | | Given Locator Set From Honeycomb Should Be
92 | | ... | ${node} | ${interface} | ${locator_set}
93 | | And Lisp mappings from Honeycomb should not exist
94 | | ... | ${node}
95 | | And Lisp mappings from VAT should not exist
96 | | ... | ${node}
97 | | And Honeycomb creates first l2 bridge domain
98 | | ... | ${node} | ${bd2_name} | ${bd_settings}
99 | | When Honeycomb adds Lisp mapping | ${node} | ${lisp_settings_local_bd}
100 | | Then Lisp mapping From Honeycomb Should Be | ${node} | ${local_bd_subtable}
101 | | And Lisp mapping From VAT Should Be | ${node} | ${vat_local_bd}
102
103 | TC07: Honeycomb configures Lisp - local mapping - VRF
104 | | [Documentation] | Check if Honeycomb can configure a local Lisp mapping\
105 | | ... | with VRF.
106 | | [Teardown] | Honeycomb removes all lisp mappings | ${node}
107 | | Given Locator Set From Honeycomb Should Be
108 | | ... | ${node} | ${interface} | ${locator_set}
109 | | And Lisp mappings from Honeycomb should not exist
110 | | ... | ${node}
111 | | And Lisp mappings from VAT should not exist
112 | | ... | ${node}
113 | | When Honeycomb adds Lisp mapping | ${node} | ${lisp_settings_local_vrf}
114 | | Then Lisp mapping From Honeycomb Should Be | ${node} | ${local_vrf_subtable}
115 | | And Lisp mapping From VAT Should Be | ${node} | ${vat_local_vrf}
116
117 | TC08: Honeycomb configures Lisp mapping with adjacency
118 | | [Documentation] | Check if Honeycomb can configure local and remote Lisp\
119 | | ... | mappings with VRF, and configure adjacency.
120 | | [Teardown] | Honeycomb removes all lisp mappings | ${node}
121 | | Given Locator Set From Honeycomb Should Be
122 | | ... | ${node} | ${interface} | ${locator_set}
123 | | And Honeycomb creates first l2 bridge domain
124 | | ... | ${node} | ${bd2_name} | ${bd_settings}
125 | | And Lisp mappings from Honeycomb should not exist
126 | | ... | ${node}
127 | | And Lisp mappings from VAT should not exist
128 | | ... | ${node}
129 | | And Honeycomb adds Lisp mapping | ${node} | ${lisp_settings_both_vrf}
130 | | When Honeycomb adds Lisp adjacency | ${node} | ${7} | remote_map_vrf
131 | | ... | adj01 | ${vrf_adjacency}
132 | | Then Lisp mapping from Honeycomb should be
133 | | ... | ${node} | ${adj_subtable}
134
135 | TC09: Honeycomb configures Lisp Map Resolver
136 | | [Documentation] | Check if Honeycomb can configure a Lisp Map Resolver.
137 | | Given Lisp state From Honeycomb Should Be | ${node} | ${state}
138 | | And Lisp state From VAT Should Be | ${node} | ${state}
139 | | When Honeycomb adds Lisp Map Resolver | ${node} | ${ip_address}
140 | | Then Map Resolver from Honeycomb should be | ${node} | ${ip_address}
141 | | And Map Resolver from VAT should be | ${node} | ${ip_address}
142
143 | TC10: Honeycomb configures Lisp Map Server
144 | | [Documentation] | Check if Honeycomb can configure a Lisp Map Server.
145 | | Given Lisp state From Honeycomb Should Be | ${node} | ${state}
146 | | And Lisp state From VAT Should Be | ${node} | ${state}
147 | | When Honeycomb adds Lisp Map Server | ${node} | @{ip_addresses}
148 | | Then Map Server from Honeycomb should be | ${node} | @{ip_addresses}
149 | | And Map Server from VAT should be | ${node} | @{ip_addresses}
150
151 | TC11: Honeycomb configures Lisp PETR configuration
152 | | [Documentation] | Check if Honeycomb can configure Lisp
153 | | ... | PETR configuration.
154 | | Given Lisp state From Honeycomb Should Be | ${node} | ${state}
155 | | And Lisp state From VAT Should Be | ${node} | ${state}
156 | | When Honeycomb enables Lisp PETR feature | ${node} | ${ip_address}
157 | | Then PETR configuration from Honeycomb should be | ${node} | ${ip_address}
158 | | And PETR configuration from VAT should be | ${node} | enabled
159
160 | TC12: Honeycomb configures Lisp RLOC Probing
161 | | [Documentation] | Check if Honeycomb can configure Lisp RLOC Probing.
162 | | Given Lisp state From Honeycomb Should Be | ${node} | ${state}
163 | | And Lisp state From VAT Should Be | ${node} | ${state}
164 | | When Honeycomb enables Lisp RLOC feature | ${node}
165 | | Then RLOC Probing from Honeycomb should be | ${node} | ${True}
166 | | And RLOC Probing from VAT should be | ${node} | enabled
167
168 | TC13: Honeycomb configures Lisp Map Register
169 | | [Documentation] | Check if Honeycomb can configure a Lisp Map Register.
170 | | Given Lisp state From Honeycomb Should Be | ${node} | ${state}
171 | | And Lisp state From VAT Should Be | ${node} | ${state}
172 | | When Honeycomb adds Lisp Map Register | ${node} | ${True}
173 | | Then Map Register from Honeycomb should be | ${node} | ${True}
174 | | And Map Register from VAT should be | ${node} | enabled
175
176 | TC14: Honeycomb enabled Lisp PITR feature
177 | | [Documentation] | Check if Honeycomb can configure the Lisp PITR feature.
178 | | Given Locator Set From Honeycomb Should Be
179 | | ... | ${node} | ${interface} | ${locator_set}
180 | | When Honeycomb enables Lisp PITR feature | ${node} | ${locator_set}
181 | | Then PITR config from Honeycomb should be | ${node} | ${locator_set}
182 | | And PITR config from VAT should be | ${node} | ${locator_set}
183
184 | TC15: Honeycomb can remove configuration of Lisp features
185 | | [Documentation] | Check if Honeycomb can disable all Lisp features.
186 | | Given Map resolver from Honeycomb should be | ${node} | ${ip_address}
187 | | And PITR config from Honeycomb should be | ${node} | ${locator_set}
188 | | When Honeycomb disables all Lisp features | ${node}
189 | | Then Lisp Should Not Be Configured | ${node}
190
191 | TC16: Honeycomb configures Lisp Map Request Mode
192 | | [Documentation] | Check if Honeycomb can configure Lisp Map Request mode.
193 | | ... | Note: Map Request Mode cannot be removed once configured.
194 | | [Teardown] | Honeycomb disables Lisp | ${node}
195 | | Given Honeycomb Enables Lisp | ${node}
196 | | When Honeycomb sets Lisp Map Request Mode | ${node} | ${True}
197 | | Then Map Request Mode from Honeycomb should be
198 | | ... | ${node} | source-destination
199 | | And Map Request Mode from VAT should be | ${node} | src-dst