Initial pep8 compliant drivers
diff --git a/TestON/tests/ClassTest/ClassTest.topo b/TestON/tests/ClassTest/ClassTest.topo
index 4ecb7ed..1c8bc4f 100644
--- a/TestON/tests/ClassTest/ClassTest.topo
+++ b/TestON/tests/ClassTest/ClassTest.topo
@@ -1,18 +1,18 @@
<TOPOLOGY>
<COMPONENT>
<ONOSbench>
- <host>10.128.174.10</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosDriver</type>
<connect_order>1</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOSbench>
<Mininet1>
- <host>10.128.10.90</host>
+ <host>10.128.10.24</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>MininetCliDriver</type>
<connect_order>2</connect_order>
<COMPONENTS>
diff --git a/TestON/tests/PingallExample/PingallExample.py b/TestON/tests/PingallExample/PingallExample.py
index faf374f..2798a97 100644
--- a/TestON/tests/PingallExample/PingallExample.py
+++ b/TestON/tests/PingallExample/PingallExample.py
@@ -8,10 +8,10 @@
"""
class PingallExample:
- def __init__( self ) :
+ def __init__( self ):
self.default = ''
- def CASE1( self, main ) :
+ def CASE1( self, main ):
"""
CASE1 is to compile ONOS and push it to the test machines
@@ -29,73 +29,73 @@
main.case( "Setting up test environment" )
# load some vairables from the params file
- PULL_CODE = False
+ PULLCODE = False
if main.params[ 'Git' ] == 'True':
- PULL_CODE = True
- cell_name = main.params[ 'ENV' ][ 'cellName' ]
+ PULLCODE = True
+ cellName = main.params[ 'ENV' ][ 'cellName' ]
- ONOS1_ip = main.params[ 'CTRL' ][ 'ip1' ]
+ ONOS1Ip = main.params[ 'CTRL' ][ 'ip1' ]
main.step( "Applying cell variable to environment" )
- cell_result = main.ONOSbench.set_cell( cell_name )
- verify_result = main.ONOSbench.verify_cell()
+ cellResult = main.ONOSbench.setCell( cellName )
+ verifyResult = main.ONOSbench.verifyCell()
main.log.report( "Uninstalling ONOS" )
- main.ONOSbench.onos_uninstall( ONOS1_ip )
+ main.ONOSbench.onosUninstall( ONOS1Ip )
- clean_install_result = main.TRUE
- git_pull_result = main.TRUE
+ cleanInstallResult = main.TRUE
+ gitPullResult = main.TRUE
main.step( "Compiling the latest version of ONOS" )
- if PULL_CODE:
+ if PULLCODE:
main.step( "Git checkout and pull master" )
- main.ONOSbench.git_checkout( "master" )
- git_pull_result = main.ONOSbench.git_pull()
+ main.ONOSbench.gitCheckout( "master" )
+ gitPullResult = main.ONOSbench.gitPull()
main.step( "Using mvn clean & install" )
- clean_install_result = main.TRUE
- if git_pull_result == main.TRUE:
- clean_install_result = main.ONOSbench.clean_install()
+ cleanInstallResult = main.TRUE
+ if gitPullResult == main.TRUE:
+ cleanInstallResult = main.ONOSbench.cleanInstall()
else:
main.log.warn( "Did not pull new code so skipping mvn " +
"clean install" )
- main.ONOSbench.get_version( report=True )
+ main.ONOSbench.getVersion( report=True )
- cell_result = main.ONOSbench.set_cell( cell_name )
- verify_result = main.ONOSbench.verify_cell()
+ cellResult = main.ONOSbench.setCell( cellName )
+ verifyResult = main.ONOSbench.verifyCell()
main.step( "Creating ONOS package" )
- package_result = main.ONOSbench.onos_package()
+ packageResult = main.ONOSbench.onosPackage()
main.step( "Installing ONOS package" )
- onos1_install_result = main.ONOSbench.onos_install( options="-f",
- node=ONOS1_ip )
+ onos1InstallResult = main.ONOSbench.onosInstall( options="-f",
+ node=ONOS1Ip )
main.step( "Checking if ONOS is up yet" )
for i in range( 2 ):
- onos1_isup = main.ONOSbench.isup( ONOS1_ip )
- if onos1_isup:
+ onos1Isup = main.ONOSbench.isup( ONOS1Ip )
+ if onos1Isup:
break
- if not onos1_isup:
+ if not onos1Isup:
main.log.report( "ONOS1 didn't start!" )
# TODO: if it becomes an issue, we can retry this step a few times
- cli_result = main.ONOScli1.start_onos_cli( ONOS1_ip )
+ cliResult = main.ONOScli1.startOnosCli( ONOS1Ip )
- case1_result = ( clean_install_result and package_result and
- cell_result and verify_result and
- onos1_install_result and
- onos1_isup and cli_result )
+ case1Result = ( cleanInstallResult and packageResult and
+ cellResult and verifyResult and
+ onos1InstallResult and
+ onos1Isup and cliResult )
- utilities.assert_equals( expect=main.TRUE, actual=case1_result,
- onpass="Test startup successful",
- onfail="Test startup NOT successful" )
+ utilities.assert_equals( expect=main.TRUE, actual=case1Result,
+ onpass="Test startup successful",
+ onfail="Test startup NOT successful" )
- if case1_result == main.FALSE:
+ if case1Result == main.FALSE:
main.cleanup()
main.exit()
- def CASE2( self, main ) :
+ def CASE2( self, main ):
"""
Assign mastership to controller
"""
@@ -105,35 +105,35 @@
main.case( "Assigning Controller" )
main.step( "Assign switches to controller" )
- ONOS1_ip = main.params[ 'CTRL' ][ 'ip1' ]
- ONOS1_port = main.params[ 'CTRL' ][ 'port1' ]
+ ONOS1Ip = main.params[ 'CTRL' ][ 'ip1' ]
+ ONOS1Port = main.params[ 'CTRL' ][ 'port1' ]
for i in range( 1, 14 ):
- main.Mininet1.assign_sw_controller(
+ main.Mininet1.assignSwController(
sw=str( i ),
- ip1=ONOS1_ip,
- port1=ONOS1_port )
+ ip1=ONOS1Ip,
+ port1=ONOS1Port )
- mastership_check = main.TRUE
+ mastershipCheck = main.TRUE
for i in range( 1, 14 ):
- response = main.Mininet1.get_sw_controller( "s" + str( i ) )
+ response = main.Mininet1.getSwController( "s" + str( i ) )
try:
main.log.info( str( response ) )
except:
main.log.info( repr( response ) )
- if re.search( "tcp:" + ONOS1_ip, response ):
- mastership_check = mastership_check and main.TRUE
+ if re.search( "tcp:" + ONOS1Ip, response ):
+ mastershipCheck = mastershipCheck and main.TRUE
else:
- mastership_check = main.FALSE
- if mastership_check == main.TRUE:
+ mastershipCheck = main.FALSE
+ if mastershipCheck == main.TRUE:
main.log.report( "Switch mastership assigned correctly" )
utilities.assert_equals(
expect=main.TRUE,
- actual=mastership_check,
+ actual=mastershipCheck,
onpass="Switch mastership assigned correctly",
onfail="Switches not assigned correctly to controllers" )
- def CASE3( self, main ) :
+ def CASE3( self, main ):
"""
Assign intents
"""
@@ -144,19 +144,19 @@
# install onos-app-fwd
main.log.info( "Install reactive forwarding app" )
- main.ONOScli1.feature_install( "onos-app-fwd" )
+ main.ONOScli1.featureInstall( "onos-app-fwd" )
# REACTIVE FWD test
- ping_result = main.FALSE
+ pingResult = main.FALSE
time1 = time.time()
- ping_result = main.Mininet1.pingall()
+ pingResult = main.Mininet1.pingall()
time2 = time.time()
main.log.info( "Time for pingall: %2f seconds" % ( time2 - time1 ) )
# uninstall onos-app-fwd
main.log.info( "Uninstall reactive forwarding app" )
- main.ONOScli1.feature_uninstall( "onos-app-fwd" )
+ main.ONOScli1.featureUninstall( "onos-app-fwd" )
- utilities.assert_equals( expect=main.TRUE, actual=ping_result,
- onpass="All hosts are reachable",
- onfail="Some pings failed" )
+ utilities.assert_equals( expect=main.TRUE, actual=pingResult,
+ onpass="All hosts are reachable",
+ onfail="Some pings failed" )
diff --git a/TestON/tests/TopoPerfNext/TopoPerfNext.params b/TestON/tests/TopoPerfNext/TopoPerfNext.params
index 851522c..08a3158 100644
--- a/TestON/tests/TopoPerfNext/TopoPerfNext.params
+++ b/TestON/tests/TopoPerfNext/TopoPerfNext.params
@@ -2,7 +2,7 @@
<testcases>1,2,3</testcases>
<ENV>
- <cellName>topo_perf_test</cellName>
+ <cellName>kelvin2</cellName>
</ENV>
<GIT>
@@ -13,21 +13,21 @@
<CTRL>
<user>admin</user>
- <ip1>10.128.174.1</ip1>
+ <ip1>10.128.10.21</ip1>
<port1>6633</port1>
- <ip2>10.128.174.2</ip2>
+ <ip2>10.128.10.22</ip2>
<port2>6633</port2>
- <ip3>10.128.174.3</ip3>
+ <ip3>10.128.10.23</ip3>
<port3>6633</port3>
</CTRL>
<MN>
- <ip1>10.128.10.90</ip1>
- <ip2>10.128.10.91</ip2>
+ <ip1>10.128.10.24</ip1>
+ <ip2>10.128.10.24</ip2>
</MN>
<BENCH>
- <ip>10.128.174.10</ip>
+ <ip>10.128.10.20</ip>
</BENCH>
<TEST>
diff --git a/TestON/tests/TopoPerfNext/TopoPerfNext.topo b/TestON/tests/TopoPerfNext/TopoPerfNext.topo
index 4ee44e2..896e991 100644
--- a/TestON/tests/TopoPerfNext/TopoPerfNext.topo
+++ b/TestON/tests/TopoPerfNext/TopoPerfNext.topo
@@ -2,72 +2,72 @@
<COMPONENT>
<ONOSbench>
- <host>10.128.174.10</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosDriver</type>
<connect_order>1</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOSbench>
<ONOS1cli>
- <host>10.128.174.10</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosCliDriver</type>
<connect_order>2</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS1cli>
<ONOS2cli>
- <host>10.128.174.10</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosCliDriver</type>
<connect_order>2</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS2cli>
<ONOS3cli>
- <host>10.128.174.10</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosCliDriver</type>
<connect_order>2</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS3cli>
<ONOS1>
- <host>10.128.174.1</host>
+ <host>10.128.10.21</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosDriver</type>
<connect_order>3</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS1>
<ONOS2>
- <host>10.128.174.2</host>
+ <host>10.128.10.22</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosDriver</type>
<connect_order>3</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS2>
<ONOS3>
- <host>10.128.174.3</host>
+ <host>10.128.10.23</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosDriver</type>
<connect_order>3</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS3>
<Mininet1>
- <host>10.128.10.90</host>
+ <host>10.128.10.24</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>MininetCliDriver</type>
<connect_order>4</connect_order>
<COMPONENTS>
@@ -79,9 +79,9 @@
</Mininet1>
<Mininet2>
- <host>10.128.10.90</host>
+ <host>10.128.10.24</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>RemoteMininetDriver</type>
<connect_order>5</connect_order>
<COMPONENTS> </COMPONENTS>
diff --git a/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.params b/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.params
index f797706..0db0459 100644
--- a/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.params
+++ b/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.params
@@ -2,7 +2,7 @@
<testcases>1,2,3,4,5</testcases>
<ENV>
- <cellName>topo_perf_test</cellName>
+ <cellName>kelvin2</cellName>
</ENV>
<GIT>
@@ -13,21 +13,21 @@
<CTRL>
<user>admin</user>
- <ip1>10.128.174.1</ip1>
+ <ip1>10.128.10.21</ip1>
<port1>6633</port1>
- <ip2>10.128.174.2</ip2>
+ <ip2>10.128.10.22</ip2>
<port2>6633</port2>
- <ip3>10.128.174.3</ip3>
+ <ip3>10.128.10.23</ip3>
<port3>6633</port3>
</CTRL>
<MN>
- <ip1>10.128.10.90</ip1>
- <ip2>10.128.10.91</ip2>
+ <ip1>10.128.10.20</ip1>
+ <ip2>10.128.10.25</ip2>
</MN>
<BENCH>
- <ip>10.128.174.10</ip>
+ <ip>10.128.10.20</ip>
</BENCH>
<TEST>
diff --git a/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.topo b/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.topo
index 3fc7bdc..ecf46d3 100644
--- a/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.topo
+++ b/TestON/tests/TopoPerfNextSingleNode/TopoPerfNextSingleNode.topo
@@ -2,36 +2,36 @@
<COMPONENT>
<ONOSbench>
- <host>10.128.174.10</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosDriver</type>
<connect_order>1</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOSbench>
<ONOS1cli>
- <host>10.128.174.10</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosCliDriver</type>
<connect_order>2</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS1cli>
<ONOS1>
- <host>10.128.174.1</host>
+ <host>10.128.20.21</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>OnosDriver</type>
<connect_order>3</connect_order>
<COMPONENTS> </COMPONENTS>
</ONOS1>
<Mininet1>
- <host>10.128.10.90</host>
+ <host>10.128.10.20</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>MininetCliDriver</type>
<connect_order>4</connect_order>
<COMPONENTS>
@@ -43,9 +43,9 @@
</Mininet1>
<Mininet2>
- <host>10.128.10.90</host>
+ <host>10.128.10.25</host>
<user>admin</user>
- <password>onos_test</password>
+ <password></password>
<type>RemoteMininetDriver</type>
<connect_order>5</connect_order>
<COMPONENTS> </COMPONENTS>