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

Method testAbstractMethods

Lib/test/test_wsgiref.py:614–620  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

612 self.assertEqual(h.environ['wsgi.url_scheme'],'http')
613
614 def testAbstractMethods(self):
615 h = BaseHandler()
616 for name in [
617 '_flush','get_stdin','get_stderr','add_cgi_vars'
618 ]:
619 self.assertRaises(NotImplementedError, getattr(h,name))
620 self.assertRaises(NotImplementedError, h._write, "test")
621
622 def testContentLength(self):
623 # Demo one reason iteration is better than write()... ;)

Callers

nothing calls this directly

Calls 2

BaseHandlerClass · 0.90
assertRaisesMethod · 0.45

Tested by

no test coverage detected