Remove trailing whitespace. ;-/

This commit is contained in:
Bob Lantz
2014-12-01 15:39:44 -08:00
parent 3c9f5ad56e
commit 5a530af189
34 changed files with 85 additions and 87 deletions
+1 -1
View File
@@ -92,5 +92,5 @@ def cleanup():
killprocs( 'Tunnel=Ethernet' )
killprocs( '.ssh/mn')
sh( 'rm -f ~/.ssh/mn/*' )
info( "*** Cleanup complete.\n" )
+1 -1
View File
@@ -43,7 +43,7 @@ class Intf( object ):
self.link = link
self.mac = mac
self.ip, self.prefixLen = None, None
# if interface is lo, we know the ip is 127.0.0.1.
# This saves an ifconfig command per node
if self.name == 'lo':
+4 -4
View File
@@ -692,7 +692,7 @@ class CPULimitedHost( Host ):
retry( retries=3, delaySecs=1, fn=self.cgroupDel )
_rtGroupSched = False # internal class var: Is CONFIG_RT_GROUP_SCHED set?
@classmethod
def checkRtGroupSched( cls ):
"Check (Ubuntu,Debian) kernel config for CONFIG_RT_GROUP_SCHED for RT"
@@ -749,7 +749,7 @@ class CPULimitedHost( Host ):
"""Set overall CPU fraction for this host
f: CPU bandwidth limit (positive fraction, or -1 for cfs unlimited)
sched: 'rt' or 'cfs'
Note 'cfs' requires CONFIG_CFS_BANDWIDTH,
Note 'cfs' requires CONFIG_CFS_BANDWIDTH,
and 'rt' requires CONFIG_RT_GROUP_SCHED"""
if not sched:
sched = self.sched
@@ -1199,11 +1199,11 @@ OVSKernelSwitch = OVSSwitch
class OVSBridge( OVSSwitch ):
"OVSBridge is an OVSSwitch in standalone/bridge mode"
def __init__( self, args, **kwargs ):
kwargs.update( failMode='standalone' )
OVSSwitch.__init__( self, args, **kwargs )
def start( self, controllers ):
OVSSwitch.start( self, controllers=[] )
+1 -1
View File
@@ -32,7 +32,7 @@ class LinuxBridge( Switch ):
return 'forwarding' in self.cmd( 'brctl showstp', self )
else:
return True
def start( self, controllers ):
"Start Linux bridge"
self.cmd( 'ifconfig', self, 'down' )
+1 -1
View File
@@ -181,7 +181,7 @@ class testOptionsTopoCommon( object ):
for rttval in [rttmin, rttavg, rttmax]:
# Multiply delay by 4 to cover there & back on two links
self.assertWithinTolerance( rttval, DELAY_MS * 4.0,
self.assertWithinTolerance( rttval, DELAY_MS * 4.0,
DELAY_TOLERANCE, msg )
+6 -6
View File
@@ -27,14 +27,14 @@ class testSwitchDpidAssignmentCommon ( object ):
self.assertEqual( switch.defaultDpid(), switch.dpid )
def testActualDpidAssignment( self ):
"""Verify that Switch dpid is the actual dpid assigned if dpid is
"""Verify that Switch dpid is the actual dpid assigned if dpid is
passed in switch creation."""
switch = Mininet( Topo(), self.switchClass, Host, Controller ).addSwitch( 'A', dpid = '000000000000ABCD' )
self.assertEqual( switch.dpid, '000000000000ABCD' )
def testDefaultDpidAssignmentFailure( self ):
"""Verify that Default dpid assignment raises an Exception if the
name of the switch does not contin a digit. Also verify the
"""Verify that Default dpid assignment raises an Exception if the
name of the switch does not contin a digit. Also verify the
exception message."""
with self.assertRaises( Exception ) as raises_cm:
Mininet( Topo(), self.switchClass, Host, Controller ).addSwitch( 'A' )
@@ -58,7 +58,7 @@ class testSwitchDpidAssignmentCommon ( object ):
except TypeError:
# Switch is OVS User Switch
self.assertEqual( switch.dpid, '0' * (16 - len(dpid)) + str(dpid) )
class testSwitchOVSKernel( testSwitchDpidAssignmentCommon, unittest.TestCase ):
"""Test dpid assignnment of OVS Kernel Switch."""
@@ -67,12 +67,12 @@ class testSwitchOVSKernel( testSwitchDpidAssignmentCommon, unittest.TestCase ):
class testSwitchOVSUser( testSwitchDpidAssignmentCommon, unittest.TestCase ):
"""Test dpid assignnment of OVS User Switch."""
switchClass = partial(OVSSwitch, datapath = 'user')
@unittest.skipUnless( quietRun( 'which ovs-openflowd' ), 'OVS Legacy Kernel switch is not installed' )
class testSwitchOVSLegacyKernel( testSwitchDpidAssignmentCommon, unittest.TestCase ):
"""Test dpid assignnment of OVS Legacy Kernel Switch."""
switchClass = OVSLegacyKernelSwitch
@unittest.skipUnless( quietRun( 'which ivs-ctl' ), 'IVS switch is not installed' )
class testSwitchIVS( testSwitchDpidAssignmentCommon, unittest.TestCase ):
"""Test dpid assignment of IVS switch."""
+2 -2
View File
@@ -101,7 +101,7 @@ class Topo( object ):
"Data center network representation for structured multi-trees."
def __init__( self, *args, **params ):
"""Topo object.
"""Topo object.
Optional named parameters:
hinfo: default host options
sopts: default switch options
@@ -256,7 +256,7 @@ class Topo( object ):
if key is None:
key = min( entry )
return entry, key
def linkInfo( self, src, dst, key=None ):
"Return link metadata dict"
entry, key = self._linkEntry( src, dst, key )
+2 -2
View File
@@ -41,7 +41,7 @@ class TorusTopo( Topo ):
with the default controller or any Ethernet bridge
without STP turned on! It can be used with STP, e.g.:
# mn --topo torus,3,3 --switch lxbr,stp=1 --test pingall"""
def build( self, x, y ):
if x < 3 or y < 3:
raise Exception( 'Please use 3x3 or greater for compatibility '
@@ -65,5 +65,5 @@ class TorusTopo( Topo ):
self.addLink( sw1, sw2 )
self.addLink( sw1, sw3 )