Update Robot Framework format - step 13
[integration/test.git] / csit / suites / openstack / clustering / ha_l3.robot
1 *** Settings ***
2 Documentation       Test suite to check connectivity in L3 using routers.
3
4 Library             SSHLibrary
5 Library             OperatingSystem
6 Library             RequestsLibrary
7 Library             Collections
8 Resource            ../../../libraries/Utils.robot
9 Resource            ../../../libraries/OpenStackOperations.robot
10 Resource            ../../../libraries/DevstackUtils.robot
11 Resource            ../../../libraries/OVSDB.robot
12 Resource            ../../../libraries/ClusterOvsdb.robot
13 Resource            ../../../libraries/ClusterManagement.robot
14 Resource            ../../../libraries/SetupUtils.robot
15 Resource            ../../../variables/Variables.robot
16 Resource            ../../../variables/netvirt/Variables.robot
17
18 Suite Setup         OpenStackOperations.OpenStack Suite Setup
19 Suite Teardown      OpenStackOperations.OpenStack Suite Teardown
20 Test Setup          SetupUtils.Setup_Test_With_Logging_And_Without_Fast_Failing
21 Test Teardown       OpenStackOperations.Get Test Teardown Debugs
22
23
24 *** Variables ***
25 ${SECURITY_GROUP}       cl3_sg
26 @{NETWORKS}             cl3_net_1    cl3_net_2
27 @{SUBNETS}              cl3_sub_1    cl3_sub_2
28 @{ROUTERS}              cl3_router_1    cl3_router_2    cl3_router_3
29 @{NET_1_VMS}            cl3_net_1_vm_1    cl3_net_1_vm_2    cl3_net_1_vm_3
30 @{NET_2_VMS}            cl3_net_2_vm_1    cl3_net_2_vm_2    cl3_net_2_vm_3
31 @{SUBNET_CIDRS}         36.0.0.0/24    37.0.0.0/24
32 @{GATEWAY_IPS}          36.0.0.1    37.0.0.1
33 @{ODL_1_AND_2_DOWN}     ${1}    ${2}
34 @{ODL_2_AND_3_DOWN}     ${2}    ${3}
35 @{index_list}           1    2    3
36
37
38 *** Test Cases ***
39 Create All Controller Sessions
40     [Documentation]    Create sessions for all three controllers.
41     ClusterManagement.ClusterManagement Setup
42     BuiltIn.Run Keyword And Ignore Error
43     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
44     ...    shard_name=default
45     ...    shard_type=config
46
47 Take Down Leader Of Default Shard
48     [Documentation]    Stop the karaf on ODL cluster leader
49     BuiltIn.Run Keyword And Ignore Error
50     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
51     ...    shard_name=default
52     ...    shard_type=config
53     ${cluster_leader}    ${followers} =    ClusterManagement.Get Leader And Followers For Shard    shard_type=config
54     BuiltIn.Set Suite Variable    ${cluster_leader}
55     ${new_cluster_list} =    ClusterManagement.Stop Single Member
56     ...    ${cluster_leader}
57     ...    msg=up: ODL1, ODL2, ODL3, down=none
58     BuiltIn.Set Suite Variable    ${new_cluster_list}
59     BuiltIn.Run Keyword And Ignore Error
60     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
61     ...    shard_name=default
62     ...    shard_type=config
63
64 Create Networks
65     [Documentation]    Create Network with neutron request.
66     FOR    ${NetworkElement}    IN    @{NETWORKS}
67         OpenStackOperations.Create Network    ${NetworkElement}
68     END
69
70 Create Subnets For net_1
71     [Documentation]    Create Sub Nets for the Networks with neutron request.
72     OpenStackOperations.Create SubNet    ${NETWORKS}[0]    ${SUBNETS}[0]    ${SUBNET_CIDRS}[0]
73
74 Create Subnets For net_2
75     [Documentation]    Create Sub Nets for the Networks with neutron request.
76     OpenStackOperations.Create SubNet    ${NETWORKS}[1]    ${SUBNETS}[1]    ${SUBNET_CIDRS}[1]
77
78 Bring Up Leader Of Default Shard
79     [Documentation]    Bring up on cluster leader
80     ClusterManagement.Start Single Member    ${cluster_leader}    msg=up: ${new_cluster_list}, down: ${cluster_leader}
81     BuiltIn.Run Keyword And Ignore Error
82     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
83     ...    shard_name=default
84     ...    shard_type=config
85
86 Add Ssh Allow All Rule
87     [Documentation]    Allow all TCP/UDP/ICMP packets for this suite
88     OpenStackOperations.Create Allow All SecurityGroup    ${SECURITY_GROUP}
89
90 Take Down ODL1
91     [Documentation]    Stop the karaf in First Controller
92     BuiltIn.Run Keyword And Ignore Error
93     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
94     ...    shard_name=default
95     ...    shard_type=config
96     ClusterManagement.Stop Single Member    1    msg=up: ODL1, ODL2, ODL3, down=none
97     BuiltIn.Run Keyword And Ignore Error
98     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
99     ...    shard_name=default
100     ...    shard_type=config
101
102 Create Vm Instances For net_1
103     [Documentation]    Create Vm instances using flavor and image names for a network.
104     OpenStackOperations.Create Vm Instance On Compute Node
105     ...    ${NETWORKS}[0]
106     ...    ${NET_1_VMS}[0]
107     ...    ${OS_CMP1_HOSTNAME}
108     ...    sg=${SECURITY_GROUP}
109     OpenStackOperations.Create Vm Instance On Compute Node
110     ...    ${NETWORKS}[0]
111     ...    ${NET_1_VMS}[1]
112     ...    ${OS_CMP1_HOSTNAME}
113     ...    sg=${SECURITY_GROUP}
114     OpenStackOperations.Create Vm Instance On Compute Node
115     ...    ${NETWORKS}[0]
116     ...    ${NET_1_VMS}[2]
117     ...    ${OS_CMP2_HOSTNAME}
118     ...    sg=${SECURITY_GROUP}
119
120 Bring Up ODL1
121     [Documentation]    Bring up ODL1 again
122     BuiltIn.Run Keyword And Ignore Error
123     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
124     ...    shard_name=default
125     ...    shard_type=config
126     ClusterManagement.Start Single Member    1    msg=up: ODL2, ODL3, down: ODL1
127     BuiltIn.Run Keyword And Ignore Error
128     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
129     ...    shard_name=default
130     ...    shard_type=config
131
132 Take Down ODL2
133     [Documentation]    Stop the karaf in Second Controller
134     BuiltIn.Run Keyword And Ignore Error
135     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
136     ...    shard_name=default
137     ...    shard_type=config
138     ClusterManagement.Stop Single Member    2    msg=up: ODL1, ODL2, ODL3, down=none
139     BuiltIn.Run Keyword And Ignore Error
140     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
141     ...    shard_name=default
142     ...    shard_type=config
143
144 Create Vm Instances For net_2
145     [Documentation]    Create Vm instances using flavor and image names for a network.
146     OpenStackOperations.Create Vm Instance On Compute Node
147     ...    ${NETWORKS}[1]
148     ...    ${NET_2_VMS}[0]
149     ...    ${OS_CMP1_HOSTNAME}
150     ...    sg=${SECURITY_GROUP}
151     OpenStackOperations.Create Vm Instance On Compute Node
152     ...    ${NETWORKS}[1]
153     ...    ${NET_2_VMS}[1]
154     ...    ${OS_CMP2_HOSTNAME}
155     ...    sg=${SECURITY_GROUP}
156     OpenStackOperations.Create Vm Instance On Compute Node
157     ...    ${NETWORKS}[1]
158     ...    ${NET_2_VMS}[2]
159     ...    ${OS_CMP2_HOSTNAME}
160     ...    sg=${SECURITY_GROUP}
161
162 Check Vm Instances Have Ip Address
163     @{NET_1_L3_VM_IPS}    ${NET_1_DHCP_IP} =    OpenStackOperations.Get VM IPs    @{NET_1_VMS}
164     @{NET_2_L3_VM_IPS}    ${NET_2_DHCP_IP} =    OpenStackOperations.Get VM IPs    @{NET_2_VMS}
165     BuiltIn.Set Suite Variable    @{NET_1_L3_VM_IPS}
166     BuiltIn.Set Suite Variable    @{NET_2_L3_VM_IPS}
167     BuiltIn.Should Not Contain    ${NET_1_L3_VM_IPS}    None
168     BuiltIn.Should Not Contain    ${NET_2_L3_VM_IPS}    None
169     BuiltIn.Should Not Contain    ${NET_1_DHCP_IP}    None
170     BuiltIn.Should Not Contain    ${NET_2_DHCP_IP}    None
171     [Teardown]    BuiltIn.Run Keywords    OpenStackOperations.Show Debugs    @{NET_1_VMS}    @{NET_2_VMS}
172     ...    AND    OpenStackOperations.Get Test Teardown Debugs
173
174 Bring Up ODL2
175     [Documentation]    Bring up ODL2 again
176     BuiltIn.Run Keyword And Ignore Error
177     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
178     ...    shard_name=default
179     ...    shard_type=config
180     ClusterManagement.Start Single Member    2    msg=up: ODL1, ODL3, down: ODL2
181     BuiltIn.Run Keyword And Ignore Error
182     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
183     ...    shard_name=default
184     ...    shard_type=config
185
186 Take Down ODL3
187     [Documentation]    Stop the karaf in Third Controller
188     BuiltIn.Run Keyword And Ignore Error
189     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
190     ...    shard_name=default
191     ...    shard_type=config
192     ClusterManagement.Stop Single Member    3    msg=up: ODL1, ODL2, ODL3, down=none
193     BuiltIn.Run Keyword And Ignore Error
194     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
195     ...    shard_name=default
196     ...    shard_type=config
197
198 Create Router router_2
199     [Documentation]    Create Router and Add Interface to the subnets.
200     OpenStackOperations.Create Router    ${ROUTERS}[1]
201     [Teardown]    Report_Failure_Due_To_Bug    6117
202
203 Create Router router_3
204     [Documentation]    Create Router and Add Interface to the subnets.
205     OpenStackOperations.Create Router    ${ROUTERS}[2]
206
207 Add Interfaces To Router
208     [Documentation]    Add Interfaces
209     FOR    ${interface}    IN    @{SUBNETS}
210         OpenStackOperations.Add Router Interface    ${ROUTERS}[2]    ${interface}
211     END
212
213 Verify Created Routers
214     [Documentation]    Check created routers using northbound rest calls
215     ${data} =    Utils.Get Data From URI    1    ${NEUTRON_ROUTERS_API}
216     BuiltIn.Log    ${data}
217     Should Contain    ${data}    ${ROUTERS}[2]
218
219 Bring Up ODL3
220     [Documentation]    Bring up ODL3 again
221     BuiltIn.Run Keyword And Ignore Error
222     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
223     ...    shard_name=default
224     ...    shard_type=config
225     ClusterManagement.Start Single Member    3    msg=up: ODL1, ODL2, down: ODL3
226     BuiltIn.Run Keyword And Ignore Error
227     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
228     ...    shard_name=default
229     ...    shard_type=config
230
231 Ping Vm Instance1 In net_2 From net_1
232     [Documentation]    Check reachability of vm instances by pinging to them after creating routers.
233     OpenStackOperations.Ping Vm From DHCP Namespace    ${NETWORKS}[0]    ${NET_2_L3_VM_IPS}[0]
234
235 Ping Vm Instance2 In net_2 From net_1
236     [Documentation]    Check reachability of vm instances by pinging to them after creating routers.
237     OpenStackOperations.Ping Vm From DHCP Namespace    ${NETWORKS}[0]    ${NET_2_L3_VM_IPS}[1]
238
239 Ping Vm Instance3 In net_2 From net_1
240     [Documentation]    Check reachability of vm instances by pinging to them after creating routers.
241     OpenStackOperations.Ping Vm From DHCP Namespace    ${NETWORKS}[0]    ${NET_2_L3_VM_IPS}[2]
242
243 Ping Vm Instance1 In net_1 From net_2
244     [Documentation]    Check reachability of vm instances by pinging to them after creating routers.
245     OpenStackOperations.Ping Vm From DHCP Namespace    ${NETWORKS}[1]    ${NET_1_L3_VM_IPS}[0]
246
247 Ping Vm Instance2 In net_1 From net_2
248     [Documentation]    Check reachability of vm instances by pinging to them after creating routers.
249     OpenStackOperations.Ping Vm From DHCP Namespace    ${NETWORKS}[1]    ${NET_1_L3_VM_IPS}[1]
250
251 Ping Vm Instance3 In net_1 From net_2
252     [Documentation]    Check reachability of vm instances by pinging to them after creating routers.
253     OpenStackOperations.Ping Vm From DHCP Namespace    ${NETWORKS}[1]    ${NET_1_L3_VM_IPS}[2]
254
255 Connectivity Tests From Vm Instance1 In net_1 In Healthy Cluster
256     [Documentation]    ssh to the VM instance and test operations.
257     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
258     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[0]    ${NET_1_L3_VM_IPS}[0]    ${dst_list}
259     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
260
261 Connectivity Tests From Vm Instance2 In net_1 In Healthy Cluster
262     [Documentation]    ssh to the VM instance and test operations.
263     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
264     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[0]    ${NET_1_L3_VM_IPS}[1]    ${dst_list}
265     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
266
267 Connectivity Tests From Vm Instance3 In net_1 In Healthy Cluster
268     [Documentation]    ssh to the VM instance and test operations.
269     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
270     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[0]    ${NET_1_L3_VM_IPS}[2]    ${dst_list}
271     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
272
273 Take Down ODL1 and ODL2
274     [Documentation]    Stop the karaf in First and Second Controller
275     BuiltIn.Run Keyword And Ignore Error
276     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
277     ...    shard_name=default
278     ...    shard_type=config
279     ClusterManagement.Stop Single Member    1    msg=up: ODL1, ODL2, ODL3, down=none
280     ClusterManagement.Stop Single Member    2    msg=up: ODL2, ODL3, down=ODL1
281     BuiltIn.Run Keyword And Ignore Error
282     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
283     ...    shard_name=default
284     ...    shard_type=config
285     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
286
287 Connectivity Tests From Vm Instance1 In net_1 With Two ODLs Down
288     [Documentation]    ssh to the VM instance and test operations.
289     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
290     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[0]    ${NET_1_L3_VM_IPS}[0]    ${dst_list}
291     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
292
293 Connectivity Tests From Vm Instance2 In net_1 With Two ODLs Down
294     [Documentation]    ssh to the VM instance and test operations.
295     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
296     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[0]    ${NET_1_L3_VM_IPS}[1]    ${dst_list}
297     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
298
299 Connectivity Tests From Vm Instance3 In net_1 With Two ODLs Down
300     [Documentation]    ssh to the VM instance and test operations.
301     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
302     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[0]    ${NET_1_L3_VM_IPS}[2]    ${dst_list}
303     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
304
305 Bring Up ODL1 and ODL2
306     [Documentation]    Bring up ODL1 and ODL2 again. Do not check for cluster sync until all nodes are
307     ...    up. akka will not let nodes join until they are all back up if two were down.
308     BuiltIn.Run Keyword And Ignore Error
309     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
310     ...    shard_name=default
311     ...    shard_type=config
312     ClusterManagement.Start Single Member    1    msg=up: ODL3, down: ODL1, ODL2    wait_for_sync=False
313     BuiltIn.Run Keyword And Ignore Error
314     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
315     ...    shard_name=default
316     ...    shard_type=config
317     ClusterManagement.Start Single Member    2    msg=up: ODL1, ODL3, down: ODL2
318     BuiltIn.Run Keyword And Ignore Error
319     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
320     ...    shard_name=default
321     ...    shard_type=config
322     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
323
324 Take Down ODL2 and ODL3
325     [Documentation]    Stop the karaf in First and Second Controller
326     BuiltIn.Run Keyword And Ignore Error
327     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
328     ...    shard_name=default
329     ...    shard_type=config
330     ClusterManagement.Stop Single Member    2    msg=up: ODL1, ODL2, ODL3, down=none
331     BuiltIn.Run Keyword And Ignore Error
332     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
333     ...    shard_name=default
334     ...    shard_type=config
335     ClusterManagement.Stop Single Member    3    msg=up: ODL1, ODL3, down=ODL2
336     BuiltIn.Run Keyword And Ignore Error
337     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
338     ...    shard_name=default
339     ...    shard_type=config
340     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
341
342 Connectivity Tests From Vm Instance1 In net_2
343     [Documentation]    ssh to the VM instance and test operations.
344     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
345     BuiltIn.Wait Until Keyword Succeeds
346     ...    30s
347     ...    10s
348     ...    OpenStackOperations.Test Operations From Vm Instance
349     ...    ${NETWORKS}[1]
350     ...    ${NET_2_L3_VM_IPS}[0]
351     ...    ${dst_list}
352     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
353
354 Connectivity Tests From Vm Instance2 In net_2
355     [Documentation]    ssh to the VM instance and test operations.
356     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
357     BuiltIn.Wait Until Keyword Succeeds
358     ...    30s
359     ...    10s
360     ...    OpenStackOperations.Test Operations From Vm Instance
361     ...    ${NETWORKS}[1]
362     ...    ${NET_2_L3_VM_IPS}[1]
363     ...    ${dst_list}
364     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
365
366 Connectivity Tests From Vm Instance3 In net_2
367     [Documentation]    ssh to the VM instance and test operations.
368     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
369     BuiltIn.Wait Until Keyword Succeeds
370     ...    30s
371     ...    10s
372     ...    OpenStackOperations.Test Operations From Vm Instance
373     ...    ${NETWORKS}[1]
374     ...    ${NET_2_L3_VM_IPS}[2]
375     ...    ${dst_list}
376     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
377
378 Bring Up ODL2 and ODL3
379     [Documentation]    Bring up ODL2 and ODL3 again. Do not check for cluster sync until all nodes are
380     ...    up. akka will not let nodes join until they are all back up if two were down.
381     BuiltIn.Run Keyword And Ignore Error
382     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
383     ...    shard_name=default
384     ...    shard_type=config
385     ClusterManagement.Start Single Member    2    msg=up: ODL1, down: ODL2, ODL3    wait_for_sync=False
386     BuiltIn.Run Keyword And Ignore Error
387     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
388     ...    shard_name=default
389     ...    shard_type=config
390     ClusterManagement.Start Single Member    3    msg=up: ODL1, ODL2, down: ODL3
391     BuiltIn.Run Keyword And Ignore Error
392     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
393     ...    shard_name=default
394     ...    shard_type=config
395     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
396
397 Take Down All Instances
398     [Documentation]    Stop karaf on all controllers
399     BuiltIn.Run Keyword And Ignore Error
400     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
401     ...    shard_name=default
402     ...    shard_type=config
403     ClusterManagement.Stop_Members_From_List_Or_All
404     BuiltIn.Run Keyword And Ignore Error
405     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
406     ...    shard_name=default
407     ...    shard_type=config
408     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
409
410 Bring Up All Instances
411     [Documentation]    Bring up all controllers. Do not check for cluster sync until all nodes are
412     ...    up. akka will not let nodes join until they are all back up if two were down.
413     BuiltIn.Run Keyword And Ignore Error
414     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
415     ...    shard_name=default
416     ...    shard_type=config
417     ClusterManagement.Start Members From List Or All
418     BuiltIn.Run Keyword And Ignore Error
419     ...    ClusterManagement.Get Raft State Of Shard Of All Member Nodes
420     ...    shard_name=default
421     ...    shard_type=config
422     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
423
424 Connectivity Tests From Vm Instance2 In net_2 after recovering all nodes
425     [Documentation]    ssh to the VM instance and test operations.
426     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
427     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[1]    ${NET_2_L3_VM_IPS}[1]    ${dst_list}
428     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
429
430 Connectivity Tests From Vm Instance3 In net_2 after recovering all nodes
431     [Documentation]    ssh to the VM instance and test operations.
432     ${dst_list} =    BuiltIn.Create List    @{NET_2_L3_VM_IPS}    @{NET_1_L3_VM_IPS}
433     OpenStackOperations.Test Operations From Vm Instance    ${NETWORKS}[1]    ${NET_2_L3_VM_IPS}[2]    ${dst_list}
434     [Teardown]    OpenStackOperations.Get Test Teardown Debugs    fail=False
435
436 Delete Vm Instances In net_1
437     [Documentation]    Delete Vm instances using instance names in net_1.
438     FOR    ${vm}    IN    @{NET_1_VMS}
439         OpenStackOperations.Delete Vm Instance    ${vm}
440     END
441
442 Delete Vm Instances In net_2
443     [Documentation]    Delete Vm instances using instance names in net_2.
444     FOR    ${vm}    IN    @{NET_2_VMS}
445         OpenStackOperations.Delete Vm Instance    ${vm}
446     END
447
448 Delete Router Interfaces
449     [Documentation]    Remove Interface to the subnets.
450     FOR    ${interface}    IN    @{SUBNETS}
451         OpenStackOperations.Remove Interface    ${ROUTERS}[2]    ${interface}
452     END
453
454 Delete Routers
455     [Documentation]    Delete Router and Interface to the subnets.
456     OpenStackOperations.Delete Router    ${ROUTERS}[1]
457     OpenStackOperations.Delete Router    ${ROUTERS}[2]
458
459 Verify Deleted Routers
460     [Documentation]    Check deleted routers using northbound rest calls
461     ${data} =    Utils.Get Data From URI    1    ${NEUTRON_ROUTERS_API}
462     BuiltIn.Log    ${data}
463     BuiltIn.Should Not Contain    ${data}    ${ROUTERS}[2]
464
465 Delete Sub Network In net_1
466     [Documentation]    Delete Sub Nets for the Networks with neutron request.
467     OpenStackOperations.Delete SubNet    ${SUBNETS}[0]
468
469 Delete Sub Network In net_2
470     [Documentation]    Delete Sub Nets for the Networks with neutron request.
471     OpenStackOperations.Delete SubNet    ${SUBNETS}[1]
472
473 Delete Networks
474     [Documentation]    Delete Networks with neutron request.
475     FOR    ${network}    IN    @{NETWORKS}
476         OpenStackOperations.Delete Network    ${network}
477     END
478
479 Delete Security Group
480     [Documentation]    Delete security groups with neutron request
481     OpenStackOperations.Delete SecurityGroup    ${SECURITY_GROUP}
482
483 Verify Flows Cleanup
484     [Documentation]    Verify that flows have been cleaned up properly after removing all neutron configurations
485     DataModels.Verify Flows Are Cleaned Up On All OpenStack Nodes