def test_docx(self): # Assert PDF to string parser. s = web.parsedoc( os.path.join(PATH, "corpora", "carroll-lookingglass.docx")) self.assertTrue("'Twas brillig, and the slithy toves" in s) self.assertTrue(isinstance(s, unicode)) print("pattern.web.parsedocx()")
def test_docx(self): # Assert PDF to string parser. s = web.parsedoc( os.path.join(PATH, "corpora", "carroll-lookingglass.docx")) self.assertTrue("'Twas brillig, and the slithy toves" in s) self.assertTrue(isinstance(s, str)) print("pattern.web.parsedocx()")
def test_pdf(self): # Assert PDF to string parser. s = web.parsedoc( os.path.join(PATH, "corpora", "carroll-wonderland.pdf")) self.assertTrue("Curiouser and curiouser!" in s) self.assertTrue(isinstance(s, unicode)) print("pattern.web.parsepdf()")
def test_pdf(self): # Assert PDF to string parser. s = web.parsedoc( os.path.join(PATH, "corpora", "carroll-wonderland.pdf")) self.assertTrue("Curiouser and curiouser!" in s) self.assertTrue(isinstance(s, str)) print("pattern.web.parsepdf()")