MCPcopy Index your code
hub / github.com/python/cpython / test_read_404

Method test_read_404

Lib/test/test_robotparser.py:503–510  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

501 self.assertTrue(self.parser.can_fetch('*', self.base_url))
502
503 def test_read_404(self):
504 parser = urllib.robotparser.RobotFileParser(self.url('i-robot.txt'))
505 parser.read()
506 self.assertTrue(parser.allow_all)
507 self.assertFalse(parser.disallow_all)
508 self.assertEqual(parser.mtime(), 0)
509 self.assertIsNone(parser.crawl_delay('*'))
510 self.assertIsNone(parser.request_rate('*'))
511
512if __name__=='__main__':
513 unittest.main()

Callers

nothing calls this directly

Calls 9

urlMethod · 0.95
readMethod · 0.95
mtimeMethod · 0.95
crawl_delayMethod · 0.95
request_rateMethod · 0.95
assertTrueMethod · 0.80
assertFalseMethod · 0.80
assertIsNoneMethod · 0.80
assertEqualMethod · 0.45

Tested by

no test coverage detected