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

Method test_introspection2

Lib/test/test_xmlrpc.py:882–892  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

880
881
882 def test_introspection2(self):
883 try:
884 # test _methodHelp()
885 p = xmlrpclib.ServerProxy(URL)
886 divhelp = p.system.methodHelp('div')
887 self.assertEqual(divhelp, 'This is the div function')
888 except (xmlrpclib.ProtocolError, OSError) as e:
889 # ignore failures due to non-blocking socket 'unavailable' errors
890 if not is_unavailable_exception(e):
891 # protocol error; provide additional information in test output
892 self.fail("%s\n%s" % (e, getattr(e, "headers", "")))
893
894 @make_request_and_skipIf(sys.flags.optimize >= 2,
895 "Docstrings are omitted with -O2 and above")

Callers

nothing calls this directly

Calls 3

is_unavailable_exceptionFunction · 0.85
assertEqualMethod · 0.45
failMethod · 0.45

Tested by

no test coverage detected