2 Documentation Test suite connecting ODL to Mininet
3 Suite Setup Create Session session http://${CONTROLLER}:${RESTCONFPORT} auth=${AUTH} headers=${HEADERS}
4 Suite Teardown Delete All Sessions
7 Library OperatingSystem
10 Library RequestsLibrary
11 Library ../../../libraries/Common.py
12 Variables ../../../variables/Variables.py
13 Resource ../../../libraries/Utils.txt
18 ${FLOWS_TABLE_20} actions=goto_table:20
19 ${FLOW_CONTROLLER} actions=CONTROLLER:65535
20 ${FLOWS_TABLE_30} actions=goto_table:30
21 ${FLOWS_TABLE_40} actions=goto_table:40
22 ${FLOWS_TABLE_50} actions=goto_table:50
23 ${FLOWS_TABLE_60} actions=goto_table:60
24 ${FLOWS_TABLE_70} actions=goto_table:70
25 ${FLOWS_TABLE_80} actions=goto_table:80
26 ${FLOWS_TABLE_90} actions=goto_table:90
27 ${FLOWS_TABLE_100} actions=goto_table:100
28 ${FLOWS_TABLE_110} actions=goto_table:110
29 ${FLOW_DROP} actions=drop
30 ${PING_NOT_CONTAIN} Destination Host Unreachable
31 @{node_list} ovsdb://uuid/
34 Make the OVS instance to listen for connection
35 [Documentation] Connect OVS to ODL
37 Run Command On Remote System ${MININET} sudo ovs-vsctl --if-exists del-port br-int
38 Run Command On Remote System ${MININET} sudo ovs-vsctl --if-exists del-br br-int
39 Run Command On Remote System ${MININET} sudo ovs-vsctl del-manager
40 Run Command On Remote System ${MININET} sudo ovs-vsctl set-manager tcp:${CONTROLLER}:${OVSDB_PORT}
41 ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
42 ${pingresult} Run Command On Remote System ${MININET} ping ${CONTROLLER} -c 4
43 Should Not Contain ${pingresult} ${PING_NOT_CONTAIN}
44 Wait Until Keyword Succeeds 8s 2s Check For Elements At URI ${OPERATIONAL_TOPO_API} ${node_list}
46 Get controller connection
47 [Documentation] This will make sure the controller is correctly set up/connected
49 ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
50 Should Contain ${output} Manager "tcp:${CONTROLLER}:${OVSDB_PORT}"
51 Should Contain ${output} is_connected: true
54 [Documentation] This request is verifying that the br-int bridge has been created
56 ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
57 Should Contain ${output} Controller "tcp:${CONTROLLER}:${OF_PORT}"
58 Should Contain ${output} Bridge br-int
61 [Documentation] This will check the port br-int has been created
63 ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
64 Should Contain ${output} Port br-int
67 [Documentation] This verify the interface br-int has been created
69 ${output} Run Command On Remote System ${MININET} sudo ovs-vsctl show
70 Should Contain ${output} Interface br-int
73 [Documentation] This request fetch the OF13 flow tables to verify the flows are correctly added
75 ${output} Run Command On Remote System ${MININET} sudo ovs-ofctl -O Openflow13 dump-flows br-int
76 Should Contain ${output} ${FLOWS_TABLE_20}
77 Should Contain ${output} ${FLOW_CONTROLLER}
78 Should Contain ${output} ${FLOWS_TABLE_30}
79 Should Contain ${output} ${FLOWS_TABLE_40}
80 Should Contain ${output} ${FLOWS_TABLE_50}
81 Should Contain ${output} ${FLOWS_TABLE_60}
82 Should Contain ${output} ${FLOWS_TABLE_70}
83 Should Contain ${output} ${FLOWS_TABLE_80}
84 Should Contain ${output} ${FLOWS_TABLE_90}
85 Should Contain ${output} ${FLOWS_TABLE_100}
86 Should Contain ${output} ${FLOWS_TABLE_110}
87 Should Contain ${output} ${FLOW_DROP}