def test_find_line_ending_cr_with_lf(self): source = 'First Line\r Second Line\n Third Line\n Fourth Line \n\r' self.assertEq(yasi.CR, yasi.find_line_ending(source))
def test_find_line_ending_should_default_to_lf(self): source = 'Line without ending' self.assertEq(yasi.LF, yasi.find_line_ending(source))
def test_find_line_ending_only_cr(self): source = 'First Line\r Second Line\r' self.assertEq(yasi.CR, yasi.find_line_ending(source))
def test_find_line_ending_lf_with_crlf(self): source = 'First Line\n Second Line\r\n Third Line\n Fourth Line \r\n' self.assertEq(yasi.CRLF, yasi.find_line_ending(source))
def test_find_line_ending_should_default_to_lf(self): source = 'Line without ending' self.assertEqual(yasi.LF, yasi.find_line_ending(source))
def test_find_line_ending_only_crlf(self): source = 'First Line\r\n Second Line\r\n' self.assertEq(yasi.CRLF, yasi.find_line_ending(source))
def test_find_line_ending_cr_with_lf(self): source = 'First Line\r Second Line\n Third Line\n Fourth Line \n\r' self.assertEqual(yasi.CR, yasi.find_line_ending(source))
def test_find_line_ending_lf_with_crlf(self): source = 'First Line\n Second Line\r\n Third Line\n Fourth Line \r\n' self.assertEqual(yasi.CRLF, yasi.find_line_ending(source))
def test_find_line_ending_only_cr(self): source = 'First Line\r Second Line\r' self.assertEqual(yasi.CR, yasi.find_line_ending(source))
def test_find_line_ending_only_lf(self): source = 'First Line\n Second Line\n' self.assertEqual(yasi.LF, yasi.find_line_ending(source))