def test_eof(self): self.testfile.read() result = utils._read_file_chunk(self.testfile, 10) self.assertEqual(result, [])
def test_ask_for_more_lines(self): result = utils._read_file_chunk(self.testfile, 30) expected = self.lines self.assertEqual(result, expected)
def test_read_three(self): result = utils._read_file_chunk(self.testfile, 3) expected = self.lines[:3] self.assertEqual(result, expected)