Пример #1
0
 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))
Пример #2
0
 def test_find_line_ending_should_default_to_lf(self):
     source = 'Line without ending'
     self.assertEq(yasi.LF, yasi.find_line_ending(source))
Пример #3
0
 def test_find_line_ending_only_cr(self):
     source = 'First Line\r Second Line\r'
     self.assertEq(yasi.CR, yasi.find_line_ending(source))
Пример #4
0
 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))
Пример #5
0
 def test_find_line_ending_should_default_to_lf(self):
     source = 'Line without ending'
     self.assertEqual(yasi.LF, yasi.find_line_ending(source))
Пример #6
0
 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))
Пример #7
0
 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))
Пример #8
0
 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))
Пример #9
0
 def test_find_line_ending_only_cr(self):
     source = 'First Line\r Second Line\r'
     self.assertEqual(yasi.CR, yasi.find_line_ending(source))
Пример #10
0
 def test_find_line_ending_only_lf(self):
     source = 'First Line\n Second Line\n'
     self.assertEqual(yasi.LF, yasi.find_line_ending(source))
Пример #11
0
 def test_find_line_ending_only_lf(self):
     source = 'First Line\n Second Line\n'
     self.assertEqual(yasi.LF, yasi.find_line_ending(source))