Remove deprecated ControllerParams (for now.)

This commit is contained in:
Bob Lantz
2012-03-09 13:53:13 -08:00
parent 9addfc13ce
commit e3c074b881
+4 -12
View File
@@ -7,14 +7,12 @@ import unittest
from mininet.net import init, Mininet
from mininet.node import Host, Controller, ControllerParams
# from mininet.node import KernelSwitch
from mininet.node import UserSwitch, OVSKernelSwitch
from mininet.topo import SingleSwitchTopo, LinearTopo
from mininet.log import setLogLevel
SWITCHES = { 'user': UserSwitch,
'ovsk': OVSKernelSwitch,
# 'kernel': KernelSwitch
}
@@ -25,9 +23,7 @@ class testSingleSwitch( unittest.TestCase ):
"Ping test with both datapaths on minimal topology"
init()
for switch in SWITCHES.values():
controllerParams = ControllerParams( '10.0.0.0', 8 )
mn = Mininet( SingleSwitchTopo(), switch, Host, Controller,
controllerParams )
mn = Mininet( SingleSwitchTopo(), switch, Host, Controller )
dropped = mn.run( mn.ping )
self.assertEqual( dropped, 0 )
@@ -35,9 +31,7 @@ class testSingleSwitch( unittest.TestCase ):
"Ping test with both datapaths on 5-host single-switch topology"
init()
for switch in SWITCHES.values():
controllerParams = ControllerParams( '10.0.0.0', 8 )
mn = Mininet( SingleSwitchTopo( k=5 ), switch, Host, Controller,
controllerParams )
mn = Mininet( SingleSwitchTopo( k=5 ), switch, Host, Controller )
dropped = mn.run( mn.ping )
self.assertEqual( dropped, 0 )
@@ -49,13 +43,11 @@ class testLinear( unittest.TestCase ):
"Ping test with both datapaths on a 5-switch topology"
init()
for switch in SWITCHES.values():
controllerParams = ControllerParams( '10.0.0.0', 8 )
mn = Mininet( LinearTopo( k=5 ), switch, Host, Controller,
controllerParams )
mn = Mininet( LinearTopo( k=5 ), switch, Host, Controller )
dropped = mn.run( mn.ping )
self.assertEqual( dropped, 0 )
if __name__ == '__main__':
setLogLevel('warning')
setLogLevel( 'warning' )
unittest.main()