5 Resource RemoteBash.robot
6 Resource SSHKeywords.robot
10 ${REST_VIEW_CHANNEL} /restconf/operations/usc-channel:view-channel
11 ${REST_ADD_CHANNEL} /restconf/operations/usc-channel:add-channel
12 ${REST_REMOVE_CHANNEL} /restconf/operations/usc-channel:remove-channel
13 ${REST_REMOVE_SESSION} /restconf/operations/usc-channel:remove-session
14 ${REST_SEND_MESSAGE} /restconf/operations/usc-channel:send-message
15 ${NAV_USC_TOOLS} cd ~/usc-tools
17 ... [ -f ~/usc-tools/UscAgent.jar ] && echo "The usc-tools does exist, done." || git clone https://github.com/victorxu99/usc-tools.git ~/usc-tools
18 ${ECHO_SERVER_PORT} 2007
19 @{LIST_ECHO_SERVER_PORT} 2007 2008 2009
20 ${TEST_MESSAGE} This is a test message.
21 ${NUM_OF_MESSAGES} 100
22 ${AgentTcp} java -jar UscAgent.jar -t true
23 ${AgentUdp} java -jar UscAgent.jar -t false
24 ${AgentTcpCallhome} java -jar UscAgent.jar -t true -c true -h
25 ${AgentUdpCallhome} java -jar UscAgent.jar -t false -c true -h
26 ${EchoServerTcp} java -jar EchoServer.jar -t true -p 2007
27 ${EchoServerUdp} java -jar EchoServer.jar -t false -p 2007
32 [Documentation] Download UscAgent and EchoServer before any system
34 Log Download tools begin ...
35 Run Command On Remote System ${TOOLS_SYSTEM_IP} ${CLONE_USC_TOOLS} prompt_timeout=30s
36 Log Download tools ended.
39 [Documentation] Basic setup/cleanup work that can be done safely before any system
41 Log Start USC test VM for TCP
42 ${agent_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
43 Set Suite Variable ${agent_conn_id}
44 Flexible Mininet Login
45 Write ${NAV_USC_TOOLS}
48 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
49 Set Suite Variable ${echo_conn_id}
50 Flexible Mininet Login
51 Write ${NAV_USC_TOOLS}
52 Write ${EchoServerTcp}
53 Read Until initialized
56 [Documentation] Basic setup/cleanup work that can be done safely before any system
58 Log Start USC test VM for UDP
59 ${agent_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
60 Set Suite Variable ${agent_conn_id}
61 Flexible Mininet Login
62 Write ${NAV_USC_TOOLS}
65 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
66 Set Suite Variable ${echo_conn_id}
67 Flexible Mininet Login
68 Write ${NAV_USC_TOOLS}
69 Write ${EchoServerUdp}
70 Read Until initialized
73 [Documentation] Basic setup/cleanup work that can be done safely before any system
75 Log Start USC test VM for CALLHOME_TCP
76 ${agent_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
77 Set Suite Variable ${agent_conn_id}
78 ${callhomeCmd}= Catenate ${AgentTcpCallhome} ${ODL_SYSTEM_IP}
79 Flexible Mininet Login
80 Write ${NAV_USC_TOOLS}
83 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
84 Set Suite Variable ${echo_conn_id}
85 Flexible Mininet Login
86 Write ${NAV_USC_TOOLS}
87 Write ${EchoServerTcp}
88 Read Until initialized
91 [Documentation] Basic setup/cleanup work that can be done safely before any system
93 Log Start USC test VM for CALLHOME_UDP
94 ${agent_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
95 Set Suite Variable ${agent_conn_id}
96 ${callhomeCmd}= Catenate ${AgentUdpCallhome} ${ODL_SYSTEM_IP}
97 Flexible Mininet Login
98 Write ${NAV_USC_TOOLS}
101 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
102 Set Suite Variable ${echo_conn_id}
103 Flexible Mininet Login
104 Write ${NAV_USC_TOOLS}
105 Write ${EchoServerUdp}
106 Read Until initialized
109 [Documentation] Basic setup/cleanup work that can be done safely before any system
111 Log Start USC test VM for Fallback_TCP
112 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
113 Set Suite Variable ${echo_conn_id}
114 Flexible Mininet Login
115 Write ${NAV_USC_TOOLS}
116 Write ${EchoServerTcp}
117 Read Until initialized
120 [Documentation] Basic setup/cleanup work that can be done safely before any system
122 Log Start USC test VM for Fallback_TCP
123 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
124 Set Suite Variable ${echo_conn_id}
125 Flexible Mininet Login
126 Write ${NAV_USC_TOOLS}
127 Write ${EchoServerUdp}
128 Read Until initialized
130 Start Multiple_Sessions_TCP
131 [Documentation] Basic setup/cleanup work that can be done safely before any system
133 Log Start USC test VM for Multiple_Sessions_TCP
134 ${agent_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
135 Set Suite Variable ${agent_conn_id}
136 Flexible Mininet Login
137 Write ${NAV_USC_TOOLS}
141 FOR ${port_index} IN @{LIST_ECHO_SERVER_PORT}
143 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
144 Append To List ${L1} ${echo_conn_id}
145 Flexible Mininet Login
146 Write ${NAV_USC_TOOLS}
147 Write java -jar EchoServer.jar -t true -p ${port_index}
148 Read Until initialized
150 Set Suite Variable ${L1}
152 Start Multiple_Sessions_UDP
153 [Documentation] Basic setup/cleanup work that can be done safely before any system
155 Log Start USC test VM for Multiple_Sessions_UDP
156 ${agent_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
157 Set Suite Variable ${agent_conn_id}
158 Flexible Mininet Login
159 Write ${NAV_USC_TOOLS}
163 FOR ${port_index} IN @{LIST_ECHO_SERVER_PORT}
165 ${echo_conn_id}= Open Connection ${TOOLS_SYSTEM_IP} timeout=30s
166 Append To List ${L1} ${echo_conn_id}
167 Flexible Mininet Login
168 Write ${NAV_USC_TOOLS}
169 Write java -jar EchoServer.jar -t false -p ${port_index}
170 Read Until initialized
172 Set Suite Variable ${L1}
175 [Documentation] Cleanup/Shutdown work that should be done at the completion of all
177 Log Stop USC test VM for Agent_Echo
178 Switch Connection ${agent_conn_id}
183 Switch Connection ${echo_conn_id}
190 [Documentation] Cleanup/Shutdown work that should be done at the completion of all
192 Log Stop USC test VM for Echo
193 Switch Connection ${echo_conn_id}
199 Stop One_Agent_Multiple_Echo
200 [Documentation] Cleanup/Shutdown work that should be done at the completion of all
202 Log Stop USC test VM for One_Agent_Multiple_Echo
203 Switch Connection ${agent_conn_id}
208 FOR ${echo_conn_id} IN @{L1}
209 Switch Connection ${echo_conn_id}