def test_integrated_link_archive_status_NO(self): url = 'http://www.toto.org' line = 'A nice line with [[http://www.toto.org|link]] Another info' result = link_archive_status(url, line) self.assertFalse(result)
def test_link_in_parenthesis_archive_status_NO(self): url = 'http://www.toto.org' line = 'A nice line with (http://www.toto.org) Another info' result = link_archive_status(url, line) self.assertFalse(result)
def test_integrated_link_archive_status_OK(self): url = 'http://www.to-to.org/article?=123' line = 'A nice line with [[http://www.to-to.org/article?=123|link]] [[/a/great/path/file.html|(Archive)]]' result = link_archive_status(url, line) self.assertTrue(result)