示例#1
0
 def probably_binary(self):
     p = not identify.is_text(self.open_file)
     self.open_file.seek(0)
     return p
示例#2
0
def test_is_text(data, expected):
    assert identify.is_text(io.BytesIO(data)) is expected
示例#3
0
文件: models.py 项目: dst1213/fluffy
 def probably_binary(self):
     p = not identify.is_text(self.open_file)
     self.open_file.seek(0)
     return p