2 Documentation Test suite for finding out max number of switches
4 Library OperatingSystem
5 Resource ../../../variables/Variables.robot
6 Resource ../../../libraries/WorkflowsOpenFlow.robot
7 Resource ../../../libraries/KarafKeywords.robot
9 Suite Setup Workflow Setup
10 Suite Teardown Workflow Teardown
17 ${SWITCHES_RESULT_FILE} switches.csv
18 ${TIME_RESULT_FILE} time.csv
23 [Documentation] Find max number of switches starting from ${MIN_SWITCHES} till reaching ${MAX_SWITCHES} in steps of ${STEP_SWITCHES}
24 ${error_message}= Set Variable Fail initializing suite
25 ${maximum_switches}= Set Variable ${0}
26 ${discover_time}= Set Variable 0
27 ${start}= Convert to Integer ${MIN_SWITCHES}
28 ${stop}= Convert to Integer ${MAX_SWITCHES}
29 ${step}= Convert to Integer ${STEP_SWITCHES}
30 FOR ${switches} IN RANGE ${start} ${stop+1} ${step}
31 ${status} ${error_message} ${topology_discover_time}= WorkflowsOpenFlow.Workflow Linear Topology
33 IF '${status}' == 'FAIL' BREAK
34 ${maximum_switches}= Set variable ${switches}
35 ${discover_time}= Set Variable ${topology_discover_time}
38 Log To Console Execution stopped because: ${error_message}
39 Log To Console Max Switches: ${maximum_switches}
40 OperatingSystem.Append To File ${SWITCHES_RESULT_FILE} Max Switches\n
41 OperatingSystem.Append To File ${SWITCHES_RESULT_FILE} ${maximum_switches}\n
42 OperatingSystem.Append To File ${TIME_RESULT_FILE} Discover Time\n
43 OperatingSystem.Append To File ${TIME_RESULT_FILE} ${discover_time}\n