class NetTxRxTestCase(unittest.TestCase): def setUp(self): self.foo = NetTxRx() def test_net_tx_rx_(self): self.assertEquals(['0', '0'], self.foo.check()) time.sleep(2) # travis! self.assertNotEquals(['0', '0'], self.foo.check()) socket.gethostbyname("google.com") socket.create_connection(("google.com", 80), 5000) time.sleep(2) print self.foo.check() def test_net_tx_rx_cols(self): res = self.foo.columns() self.assertEquals(['Net_tx', 'Net_rx', ], res)
class NetTxRxTestCase(unittest.TestCase): def setUp(self): self.foo = NetTxRx() def test_net_tx_rx_(self): self.assertEquals(['0', '0'], self.foo.check()) time.sleep(2) # travis! self.assertNotEquals(['0', '0'], self.foo.check()) socket.gethostbyname("google.com") socket.create_connection(("google.com", 80), 5000) time.sleep(2) print self.foo.check() def test_net_tx_rx_cols(self): res = self.foo.columns() self.assertEquals([ 'Net_tx', 'Net_rx', ], res)
def setUp(self): self.foo = NetTxRx()