def test_bufcount(self): nline = 12011 data = "\n"*nline filename = "test_bufcount.txt" with open(filename, 'w') as f: f.write(data) expected = nline actual = IO.bufcount(filename) self.assertEqual(actual, expected) import os os.remove(filename)
def test_bufcount(self): nline = 12011 data = "\n" * nline filename = "test_bufcount.txt" with open(filename, 'w') as f: f.write(data) expected = nline actual = IO.bufcount(filename) self.assertEqual(actual, expected) import os os.remove(filename)