4 A simple sanity check test for cluster edition
8 from mininet.util import pexpect
10 class clusterSanityCheck( unittest.TestCase ):
14 def testClusterPingAll( self ):
15 p = pexpect.spawn( 'python -m mininet.examples.clusterSanity' )
16 p.expect( self.prompt )
17 p.sendline( 'pingall' )
18 p.expect ( '(\d+)% dropped' )
19 percent = int( p.match.group( 1 ) ) if p.match else -1
20 self.assertEqual( percent, 0 )
21 p.expect( self.prompt )
26 if __name__ == '__main__':