def test__same_host_fail(self): c = Crawler() c.host = 'www.example.com' self.assertFalse(bool(c._same_host('http:/yourname.xyz/file.html')))
def test__same_host_pass(self): c = Crawler() c.host = 'www.example.com' self.assertTrue(bool(c._same_host('http://www.example.com/file.html')))