4 Regression test for pty leak in Node()
9 from mininet.net import Mininet
10 from mininet.clean import cleanup
11 from mininet.topo import SingleSwitchTopo
13 class TestPtyLeak( unittest.TestCase ):
14 "Verify that there is no pty leakage"
18 "Test for pty leakage"
19 net = Mininet( SingleSwitchTopo() )
22 for _ in range( 0, 10 ):
23 oldptys = host.slave, host.master
25 host = net.addHost( 'h1' )
26 assert ( host.slave, host.master ) == oldptys
29 if __name__ == '__main__':