예제 #1
0
 def test_read_content_badfile(self, text_file):
     text = read_content("FILE_NOT_EXISTS", text_file['encoding'])
     assert text == ''
예제 #2
0
 def test_read_content_bad_encoding(self, text_file):
     text = read_content(text_file['filepath'], 'utf-8')
     assert text == ''
예제 #3
0
 def test_read_content_normal(self, text_file):
     text = read_content(text_file['filepath'], text_file['encoding'])
     assert text == text_file['text']